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)
Fri, Jun 5, 1:02 AM
Unknown Object (File)
Thu, Jun 4, 8:30 PM
Unknown Object (File)
Wed, Jun 3, 10:19 PM
Unknown Object (File)
Sun, May 31, 11:06 AM
Unknown Object (File)
Thu, May 14, 10:39 AM
Unknown Object (File)
May 13 2026, 8:24 PM
Unknown Object (File)
May 13 2026, 5:28 PM
Unknown Object (File)
May 10 2026, 10:55 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