after setting custom timeout values in pf.conf and reloading the config and then commenting out/deleting the lines with timeout settings, the setting remain set. How-To-Repeat: 1. set timeout value. e.g. by using following pf.conf line: set timeout tcp.closed 60 2. display timeout setting via 'pfctl -s timeout | grep tcp.closed' 3. reload pf configuration via 'pfctl -f /etc/pf.conf' 4. remove or comment out the line set in step 1 5. reload pf configuration 6. display tcp.closed timeout (as in step 2) expected behavior: after step 6, tcp.closed timeout should be set to default value (as seen in step 2)
This problem can be fixed by applying following patch: http://techie.devnull.cz/public/patches/pfctl-timeout.patch which makes behavior of options consistent with behavior of rules (within pf.conf). This means that global timeout settings will be applied only when ruleset is parsed successfully (which is not happening in current pf implementation) and also when lines with global timeout settings (or optimization lines) are removed, default timeout settings are restored. (also not happening in current pf implem.)
Responsible Changed From-To: freebsd-bugs->freebsd-pf Over to pf Mailinglist
This problem has been addressed in OpenBSD by the following commit in a clean fashion: http://www.openbsd.org/cgi-bin/cvsweb/src/sbin/pfctl/pfctl.c#rev1.231 I will look at bringing this back into RELENG_6 after importing OpenBSD 3.8 to HEAD. Meanwhile, as this is not a critical problem, I'd like to avoid creating large diffs against the vendor branch. Thanks for the report. -- Max
State Changed From-To: open->analyzed Import OpenBSD's solution later.
Responsible Changed From-To: freebsd-pf->mlaier Over to my TODO stack.
State Changed From-To: analyzed->analyzed commit bit has been taken in for safekeeping.
Responsible Changed From-To: mlaier->freebsd-pf
This was fixed some time ago, should be closed. Starting at default timeouts (none specified in pf.conf). # pfctl -s timeout|grep tcp.closed tcp.closed 90s Add "set timeout tcp.closed 60" to pf.conf and reload it. # pfctl -s timeout|grep tcp.closed tcp.closed 60s Then remove that line from pf.conf and 'pfctl -f /etc/pf.conf' and you're back to the default. # pfctl -s timeout|grep tcp.closed tcp.closed 90s
Closing based on the report in comment #8. mlaier@ imported the openbsd fix back in r145840.