mirror of
https://git.freebsd.org/ports.git
synced 2025-07-18 17:59:20 -04:00
Fix clamscan 0.90 fallback and remove the --mbox option
Add another fallback case for clamd 0.90 Bump portrevision Approved by: wes
This commit is contained in:
parent
d6d3565738
commit
60ce6b9fde
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=185351
2 changed files with 45 additions and 0 deletions
|
@ -7,6 +7,7 @@
|
|||
|
||||
PORTNAME= mimedefang
|
||||
PORTVERSION= 2.61
|
||||
PORTREVISION= 1
|
||||
CATEGORIES= mail
|
||||
MASTER_SITES= http://www.mimedefang.org/static/
|
||||
|
||||
|
|
|
@ -9,3 +9,47 @@
|
|||
$TrophieSock = "@SPOOLDIR@/trophie";
|
||||
|
||||
package MIME::Parser::ParanoidFiler;
|
||||
@@ -3669,7 +3669,7 @@
|
||||
|
||||
# Run clamscan
|
||||
my($code, $category, $action) =
|
||||
- run_virus_scanner($Features{'Virus:CLAMAV'} . " --mbox --stdout --disable-summary --infected $path 2>&1");
|
||||
+ run_virus_scanner($Features{'Virus:CLAMAV'} . " --stdout --disable-summary --infected $path 2>&1");
|
||||
if ($action ne 'proceed') {
|
||||
return (wantarray ? ($code, $category, $action) : $code);
|
||||
}
|
||||
@@ -3693,7 +3693,7 @@
|
||||
|
||||
# Run clamscan
|
||||
my($code, $category, $action) =
|
||||
- run_virus_scanner($Features{'Virus:CLAMAV'} . " -r --mbox --stdout --disable-summary --infected ./Work 2>&1");
|
||||
+ run_virus_scanner($Features{'Virus:CLAMAV'} . " -r --stdout --disable-summary --infected ./Work 2>&1");
|
||||
if ($action ne 'proceed') {
|
||||
return (wantarray ? ($code, $category, $action) : $code);
|
||||
}
|
||||
@@ -4506,10 +4506,10 @@
|
||||
md_syslog('err', "$MsgID: Clamd returned error: $err_detail");
|
||||
# If it's a zip module failure, try falling back on clamscan.
|
||||
# This is despicable, but it might work
|
||||
- if ($err_detail =~ /zip module failure/i &&
|
||||
+ if ($err_detail =~ /(?:zip module failure|Not supported data format)/i &&
|
||||
$Features{'Virus:CLAMAV'}) {
|
||||
my ($code, $category, $action) =
|
||||
- run_virus_scanner($Features{'Virus:CLAMAV'} . " -r --unzip --mbox --stdout --disable-summary --infected $CWD/Work 2>&1");
|
||||
+ run_virus_scanner($Features{'Virus:CLAMAV'} . " -r --unzip --stdout --disable-summary --infected $CWD/Work 2>&1");
|
||||
if ($action ne 'proceed') {
|
||||
return (wantarray ? ($code, $category, $action) : $code);
|
||||
}
|
||||
@@ -4603,10 +4603,10 @@
|
||||
md_syslog('err', "$MsgID: Clamd returned error: $err_detail");
|
||||
# If it's a zip module failure, try falling back on clamscan.
|
||||
# This is despicable, but it might work
|
||||
- if ($err_detail =~ /zip module failure/i &&
|
||||
+ if ($err_detail =~ /(?:zip module failure|Not supported data format)/i &&
|
||||
$Features{'Virus:CLAMAV'}) {
|
||||
my ($code, $category, $action) =
|
||||
- run_virus_scanner($Features{'Virus:CLAMAV'} . " -r --unzip --mbox --stdout --disable-summary --infected $CWD/Work 2>&1");
|
||||
+ run_virus_scanner($Features{'Virus:CLAMAV'} . " -r --unzip --stdout --disable-summary --infected $CWD/Work 2>&1");
|
||||
if ($action ne 'proceed') {
|
||||
return (wantarray ? ($code, $category, $action) : $code);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue