HomeFreeBSD

ipfilter: Reliably print the interface name

Description

ipfilter: Reliably print the interface name

When printing the interface name from the ipstate_t struct the interface
name in is_ifp may not always be avaiable when reading it from kmem
(tested on FreeBSD and NetBSD). However the is_ifname (the interface
name character string) is almost always available -- it is not available
when the source of the packet is a process running on the firewall
itself. Rather than print both interface name strings, print only the
one.

MFC after: 1 week

Details

Provenance
cyAuthored on Mar 3 2022, 6:43 AM
Parents
rGec793543feff: ipfilter: Obtain the interface name more efficiently
Branches
Unknown
Tags
Unknown