Page MenuHomeFreeBSD

ifconf(): Always zero the whole struct ifreq.
ClosedPublic

Authored by brooks on Mar 30 2018, 10:09 PM.
Tags
None
Referenced Files
F137774079: D14912.id41156.diff
Tue, Nov 25, 5:24 PM
Unknown Object (File)
Thu, Nov 20, 3:35 PM
Unknown Object (File)
Thu, Nov 20, 3:24 PM
Unknown Object (File)
Thu, Nov 20, 3:22 PM
Unknown Object (File)
Thu, Nov 20, 3:12 PM
Unknown Object (File)
Tue, Nov 18, 3:13 PM
Unknown Object (File)
Sun, Nov 16, 11:38 PM
Unknown Object (File)
Thu, Nov 6, 2:00 PM
Subscribers

Details

Summary

The previous split of zeroing ifr_name and ifr_addr seperately is safe
on current architectures, but would be unsafe if pointers were larger
than 8 bytes. Combining the zeroing adds no real cost (a few
instructions) and makes the security property easier to verify.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable