From owner-svn-src-all@freebsd.org Tue Aug 9 03:39:22 2016 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 770A5BB37DC; Tue, 9 Aug 2016 03:39:22 +0000 (UTC) (envelope-from loos@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3C0DB15BF; Tue, 9 Aug 2016 03:39:22 +0000 (UTC) (envelope-from loos@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u793dLu1007572; Tue, 9 Aug 2016 03:39:21 GMT (envelope-from loos@FreeBSD.org) Received: (from loos@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u793dLcM007571; Tue, 9 Aug 2016 03:39:21 GMT (envelope-from loos@FreeBSD.org) Message-Id: <201608090339.u793dLcM007571@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: loos set sender to loos@FreeBSD.org using -f From: Luiz Otavio O Souza Date: Tue, 9 Aug 2016 03:39:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r303864 - stable/11/sbin/pfctl X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Aug 2016 03:39:22 -0000 Author: loos Date: Tue Aug 9 03:39:21 2016 New Revision: 303864 URL: https://svnweb.freebsd.org/changeset/base/303864 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) Pointy hat to: loos Approved by: re (gjb) Modified: stable/11/sbin/pfctl/parse.y Directory Properties: stable/11/ (props changed) Modified: stable/11/sbin/pfctl/parse.y ============================================================================== --- stable/11/sbin/pfctl/parse.y Tue Aug 9 02:16:21 2016 (r303863) +++ stable/11/sbin/pfctl/parse.y Tue Aug 9 03:39:21 2016 (r303864) @@ -4460,6 +4460,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