FreeBSD Bugzilla – Attachment 199506 Details for
Bug 233461
security/clamav-unofficial-sigs: patch out GNU extended regex
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
svn(1) diff against security/clamav-unofficial-sigs.sh
clamav-unofficial-sigs.diff (text/plain), 3.50 KB, created by
Kyle Evans
on 2018-11-24 02:35:32 UTC
(
hide
)
Description:
svn(1) diff against security/clamav-unofficial-sigs.sh
Filename:
MIME Type:
Creator:
Kyle Evans
Created:
2018-11-24 02:35:32 UTC
Size:
3.50 KB
patch
obsolete
>Index: files/patch-clamav-unofficial-sigs.sh >=================================================================== >--- files/patch-clamav-unofficial-sigs.sh (revision 485095) >+++ files/patch-clamav-unofficial-sigs.sh (working copy) >@@ -1,4 +1,4 @@ >---- clamav-unofficial-sigs.sh.orig 2018-03-27 15:43:43 UTC >+--- clamav-unofficial-sigs.sh.orig 2018-11-24 02:28:28 UTC > +++ clamav-unofficial-sigs.sh > @@ -1290,7 +1290,7 @@ minimum_required_config_version="72" > minimum_yara_clamav_version="0.99" >@@ -5,7 +5,7 @@ > > # Default config files > -config_dir="/etc/clamav-unofficial-sigs" >-+config_dir="%%PREFIX%%/etc/clamav-unofficial-sigs" >++config_dir="/usr/local/etc/clamav-unofficial-sigs" > config_files=( "$config_dir/master.conf" "$config_dir/os.conf" "$config_dir/user.conf" ) > > # Initialise >@@ -18,7 +18,43 @@ > > # Solaris which function returns garbage when the program is not found > # only define the new which function if running under Solaris >-@@ -2131,20 +2133,11 @@ if [ "$sanesecurity_enabled" == "yes" ] >+@@ -1437,7 +1439,7 @@ for config_file in "${config_files[@]}" ; do >+ clean_config="$(echo "$clean_config" | sed -e '/^[[:blank:]]*#/d;s/#.*//')" # Comments at end of line >+ #clean_config="$(echo "$clean_config" | sed -e 's/^[ \t]*//;s/[ \t]*$//')" # trailing and leading whitespace >+ clean_config="$(echo "$clean_config" | xargs)" >+- clean_config="$(echo "$clean_config" | sed -e '/^\s*$/d')" # Blank lines >++ clean_config="$(echo "$clean_config" | sed -e '/^[[:space:]]*$/d')" # Blank lines >+ >+ elif [ "$(uname -s)" == "Darwin" ] ; then >+ # MacOS / OS X fixes, had issues with running with a single command and with SunOS work around.. >+@@ -1446,7 +1448,7 @@ for config_file in "${config_files[@]}" ; do >+ clean_config="$(echo "$clean_config" | sed -e '/^[[:blank:]]*#/d;s/#.*//')" # Comments at end of line >+ #clean_config="$(echo "$clean_config" | sed -e 's/^[ \t]*//;s/[ \t]*$//')" # trailing and leading whitespace >+ #clean_config="$(echo "$clean_config" | xargs)" >+- clean_config="$(echo "$clean_config" | sed -e '/^\s*$/d')" # Blank lines >++ clean_config="$(echo "$clean_config" | sed -e '/^[[:space:]]*$/d')" # Blank lines >+ >+ else >+ # Delete lines beginning with # >+@@ -1455,7 +1457,7 @@ for config_file in "${config_files[@]}" ; do >+ # Delete both trailing and leading whitespace >+ # Delete all trailing whitespace >+ # Delete all empty lines >+- clean_config="$(command sed -e '/^#.*/d' -e 's/[[:space:]]#.*//' -e 's/#[[:space:]].*//' -e 's/^[ \t]*//;s/[ \t]*$//' -e '/^\s*$/d' "$config_file")" >++ clean_config="$(command sed -e '/^#.*/d' -e 's/[[:space:]]#.*//' -e 's/#[[:space:]].*//' -e 's/^[ \t]*//;s/[ \t]*$//' -e '/^[[:space:]]*$/d' "$config_file")" >+ fi >+ >+ #fix eval of | >+@@ -1470,7 +1472,7 @@ for config_file in "${config_files[@]}" ; do >+ fi >+ >+ # Check there is an = for every set of "" optional whitespace \s* between = and " >+- config_check_vars="$(echo "$clean_config" | $grep_bin -c '=\s*\"' )" >++ config_check_vars="$(echo "$clean_config" | $grep_bin -c '=[[:space:]]*\"' )" >+ >+ if [ $(( ${#config_check} / 2 )) -ne "$config_check_vars" ] ; then >+ xshok_pretty_echo_and_log "ERROR: Your configuration has errors, every = requires a pair of \"\"" "=" >+@@ -2131,20 +2133,11 @@ if [ "$sanesecurity_enabled" == "yes" ] ; then > xshok_pretty_echo_and_log "Sanesecurity Database & GPG Signature File Updates" "=" > xshok_pretty_echo_and_log "Checking for Sanesecurity updates..." >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 233461
:
199506
|
199516
|
199563