Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 30 Jan 2020 09:56:57 +0000 (UTC)
From:      Kristof Provost <kp@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject:   svn commit: r357290 - stable/11/etc/periodic/security
Message-ID:  <202001300956.00U9uvTW045246@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kp
Date: Thu Jan 30 09:56:57 2020
New Revision: 357290
URL: https://svnweb.freebsd.org/changeset/base/357290

Log:
  MFC r356816:
  
  Fix pfdenied not returning any results
  
  When _a is empty we end up with an invalid invocation of pfctl, and no output.
  We must add quotes to make it clear to pfctl that we're passing an empty anchor
  name.
  
  PR:		224415
  Submitted by:	sigsys AT gmail.com

Modified:
  stable/11/etc/periodic/security/520.pfdenied
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/etc/periodic/security/520.pfdenied
==============================================================================
--- stable/11/etc/periodic/security/520.pfdenied	Thu Jan 30 09:56:56 2020	(r357289)
+++ stable/11/etc/periodic/security/520.pfdenied	Thu Jan 30 09:56:57 2020	(r357290)
@@ -46,7 +46,7 @@ then
 	TMP=`mktemp -t security`
 	for _a in "" $(pfctl -a "blacklistd" -sA 2>/dev/null)
 	do
-		pfctl -a ${_a} -sr -v -z 2>/dev/null | \
+		pfctl -a "${_a}" -sr -v -z 2>/dev/null | \
 		nawk '{if (/^block/) {buf=$0; getline; gsub(" +"," ",$0); if ($5 > 0) print buf$0;} }' >> ${TMP}
 	done
 	if [ -s ${TMP} ]; then



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202001300956.00U9uvTW045246>