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
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "[email protected]"

Reply via email to