svn commit: r303865 - stable/10/sbin/pfctl

Luiz Otavio O Souza loos at FreeBSD.org
Tue Aug 9 03:47:39 UTC 2016


Author: loos
Date: Tue Aug  9 03:47:38 2016
New Revision: 303865
URL: https://svnweb.freebsd.org/changeset/base/303865

Log:
  MFC r303760:
  
  Fix a regression in pf.conf while parsing the 'interval' keyword.
  
  The bug was introduced by r287009.
  
  PR:		210924
  Submitted by:	kp@
  Sponsored by:	Rubicon Communications (Netgate)

Modified:
  stable/10/sbin/pfctl/parse.y
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sbin/pfctl/parse.y
==============================================================================
--- stable/10/sbin/pfctl/parse.y	Tue Aug  9 03:39:21 2016	(r303864)
+++ stable/10/sbin/pfctl/parse.y	Tue Aug  9 03:47:38 2016	(r303865)
@@ -4384,6 +4384,16 @@ timeout_spec	: STRING NUMBER
 			}
 			free($1);
 		}
+		| INTERVAL NUMBER		{
+			if (check_rulestate(PFCTL_STATE_OPTION))
+				YYERROR;
+			if ($2 < 0 || $2 > UINT_MAX) {
+				yyerror("only positive values permitted");
+				YYERROR;
+			}
+			if (pfctl_set_timeout(pf, "interval", $2, 0) != 0)
+				YYERROR;
+		}
 		;
 
 timeout_list	: timeout_list comma timeout_spec optnl


More information about the svn-src-stable-10 mailing list