HardenedBSD/usr.sbin/uhsoctl
Konrad Witaszczyk c74a4cea0d usr.sbin/uhsoctl: correct SIOCDIFADDR calls to use ifreq
The SIOCDIFADDR ioctl takes an ifreq structure object, not an ifaliasreq
structure object, as its argument.

The ifreq structure does not include a separate mask field and the
SIOCDIFADDR ioctl handler does not require a network mask as opposed to
the ifaliasreq structure and the SIOCAIFADDR ioctl. Given that
SIOCAIFADDR and SIOCDIFADDR ioctls significantly differ and use
different structures for ioctl arguments, remove ifaddr_add() and move
its logic handling these ioctls to ifaddr_add()'s callers.

Reviewed by:	brooks, jhb, oshogbo
Accepted by:	oshogbo (mentor)
Obtained from:	CheriBSD
Differential Revision: https://reviews.freebsd.org/D46019
2024-07-22 14:58:19 +00:00
..
Makefile
Makefile.depend
uhsoctl.1
uhsoctl.c