Page MenuHomeFreeBSD

netlink: cope with growing requests
ClosedPublic

Authored by kp on Oct 16 2023, 12:07 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, May 24, 12:39 PM
Unknown Object (File)
Sat, May 17, 1:24 PM
Unknown Object (File)
Apr 26 2025, 9:09 AM
Unknown Object (File)
Apr 25 2025, 12:41 AM
Unknown Object (File)
Apr 24 2025, 11:11 AM
Unknown Object (File)
Feb 26 2025, 4:19 PM
Unknown Object (File)
Feb 21 2025, 8:51 AM
Unknown Object (File)
Feb 11 2025, 10:27 PM
Subscribers

Details

Summary

If a request ends up growing beyong the initially allocated space the
netlink functions (such as snl_add_msg_attr_u32()) will allocate a
new buffer. This invalidates the header pointer we can have received
from snl_create_msg_request(). Always use the hdr returned by
snl_finalize_msg().

MFC after: 1 week
Sponsored by: Rubicon Communications, LLC ("Netgate")

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable