Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F177561837
D48824.1794731522.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Authored By
Unknown
Size
994 B
Referenced Files
None
Subscribers
None
D48824.1794731522.diff
View Options
diff --git a/sys/netinet/ip_fastfwd.c b/sys/netinet/ip_fastfwd.c
--- a/sys/netinet/ip_fastfwd.c
+++ b/sys/netinet/ip_fastfwd.c
@@ -401,7 +401,7 @@
if (!PFIL_HOOKED_OUT(V_inet_pfil_head))
goto passout;
- if (pfil_mbuf_out(V_inet_pfil_head, &m, nh->nh_ifp,
+ if (pfil_mbuf_fwd(V_inet_pfil_head, &m, nh->nh_ifp,
NULL) != PFIL_PASS)
goto drop;
diff --git a/sys/netinet/ip_output.c b/sys/netinet/ip_output.c
--- a/sys/netinet/ip_output.c
+++ b/sys/netinet/ip_output.c
@@ -112,13 +112,19 @@
struct mbuf *m;
struct in_addr odst;
struct ip *ip;
+ int ret;
m = *mp;
ip = mtod(m, struct ip *);
/* Run through list of hooks for output packets. */
odst.s_addr = ip->ip_dst.s_addr;
- switch (pfil_mbuf_out(V_inet_pfil_head, mp, ifp, inp)) {
+ if (flags & IP_FORWARDING)
+ ret = pfil_mbuf_fwd(V_inet_pfil_head, mp, ifp, inp);
+ else
+ ret = pfil_mbuf_out(V_inet_pfil_head, mp, ifp, inp);
+
+ switch (ret) {
case PFIL_DROPPED:
*error = EACCES;
/* FALLTHROUGH */
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Nov 15, 8:32 AM (5 m, 15 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
41740593
Default Alt Text
D48824.1794731522.diff (994 B)
Attached To
Mode
D48824: pfil: set PFIL_FWD for IPv4 forwarding
Attached
Detach File
Event Timeline