Page MenuHomeFreeBSD

netlink: underscore snl_get_genl_family_info() to discourage its use
ClosedPublic

Authored by glebius on Jan 16 2025, 7:48 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Apr 19, 11:28 AM
Unknown Object (File)
Fri, Apr 18, 3:53 AM
Unknown Object (File)
Wed, Apr 16, 1:37 PM
Unknown Object (File)
Mon, Apr 14, 10:15 AM
Unknown Object (File)
Mar 6 2025, 3:27 AM
Unknown Object (File)
Feb 27 2025, 8:06 AM
Unknown Object (File)
Feb 16 2025, 3:48 PM
Unknown Object (File)
Feb 1 2025, 6:54 PM
Subscribers

Details

Summary

This function uses already supposedly opaque struct _getfamily_attrs as
the argument and it fills it with pointers to volatile memory, which makes
it is unsafe for general use. While here also underscore structures that
hang off the struct _getfamily_attrs.

Small programs like powerd(8) and RPC daemons are converted to use
snl_get_genl_mcast_group() and/or snl_get_genl_family(). The genl(1)
utility was fixed not to mix its own parsers with parsers declared in
netlink_snl_generic.h.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 61754
Build 58638: arc lint + arc unit