Changeset View
Changeset View
Standalone View
Standalone View
sys/netpfil/pf/pf.c
Context not available. | |||||
M_ASSERTPKTHDR(m); | M_ASSERTPKTHDR(m); | ||||
/* Detect packet forwarding. | |||||
* If the input interface is different from the output interface we're | |||||
* forwarding. | |||||
* We do need to be careful about bridges. If the | |||||
* net.link.bridge.pfil_bridge sysctl is set we can be filtering on a | |||||
* bridge, so if the input interface is a bridge member and the output | |||||
* interface is its bridge or a member of the same bridge we're not | |||||
* actually forwarding but bridging. | |||||
*/ | |||||
if (dir == PF_OUT && m->m_pkthdr.rcvif && ifp != m->m_pkthdr.rcvif && | |||||
(m->m_pkthdr.rcvif->if_bridge == NULL || | |||||
(m->m_pkthdr.rcvif->if_bridge != ifp->if_softc && | |||||
m->m_pkthdr.rcvif->if_bridge != ifp->if_bridge))) | |||||
fwdir = PF_FWD; | |||||
if (dir == PF_FWD) | if (dir == PF_FWD) | ||||
dir = PF_OUT; | dir = PF_OUT; | ||||
Context not available. |