Date: Tue, 28 Sep 2010 23:23:23 +0000 (UTC) From: Luigi Rizzo <luigi@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r213254 - head/sys/netinet/ipfw Message-ID: <201009282323.o8SNNNtH088921@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: luigi Date: Tue Sep 28 23:23:23 2010 New Revision: 213254 URL: http://svn.freebsd.org/changeset/base/213254 Log: fix breakage in in-kernel NAT: the code did not honor net.inet.ip.fw.one_pass and always moved to the next rule in case of a successful nat. This should fix several related PR (waiting for feedback before closing them) PR: 145167 149572 150141 MFC after: 3 days Modified: head/sys/netinet/ipfw/ip_fw_pfil.c Modified: head/sys/netinet/ipfw/ip_fw_pfil.c ============================================================================== --- head/sys/netinet/ipfw/ip_fw_pfil.c Tue Sep 28 22:46:13 2010 (r213253) +++ head/sys/netinet/ipfw/ip_fw_pfil.c Tue Sep 28 23:23:23 2010 (r213254) @@ -231,6 +231,11 @@ again: break; case IP_FW_NAT: + /* honor one-pass in case of successful nat */ + if (V_fw_one_pass) + break; /* ret is already 0 */ + goto again; + case IP_FW_REASS: goto again; /* continue with packet */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201009282323.o8SNNNtH088921>