diff options
author | pav <pav@FreeBSD.org> | 2004-08-21 10:15:49 +0000 |
---|---|---|
committer | pav <pav@FreeBSD.org> | 2004-08-21 10:15:49 +0000 |
commit | 503617f0a030ff5c463dcf9f9a2a2c2de58e5eb9 (patch) | |
tree | 46690e5ea75f695092b79b4e7c03248d73d1c0cb /mail/mailscanner | |
parent | 670b7f0b8e932e9db60f0217db98c08034005920 (diff) | |
download | FreeBSD-ports-503617f0a030ff5c463dcf9f9a2a2c2de58e5eb9.zip FreeBSD-ports-503617f0a030ff5c463dcf9f9a2a2c2de58e5eb9.tar.gz |
Add vendor patch:
- better support for RAR scanning
- Support for latest AntiVir
PR: ports/70550
Submitted by: Jan-Peter Koopmann <j.koopmann@seceidos.de> (maintainer)
Diffstat (limited to 'mail/mailscanner')
-rw-r--r-- | mail/mailscanner/Makefile | 1 | ||||
-rw-r--r-- | mail/mailscanner/files/patch-lib:MailScanner:SweepViruses.pm | 44 |
2 files changed, 45 insertions, 0 deletions
diff --git a/mail/mailscanner/Makefile b/mail/mailscanner/Makefile index f5e8ff7..3d1fcd7 100644 --- a/mail/mailscanner/Makefile +++ b/mail/mailscanner/Makefile @@ -7,6 +7,7 @@ PORTNAME= MailScanner PORTVERSION= 4.32.5 +PORTREVISION= 1 CATEGORIES= mail MASTER_SITES= http://www.sng.ecs.soton.ac.uk/mailscanner/files/4/tar/ DISTNAME= ${PORTNAME}-install-${PORTVERSION}-${PATCHLEVEL} diff --git a/mail/mailscanner/files/patch-lib:MailScanner:SweepViruses.pm b/mail/mailscanner/files/patch-lib:MailScanner:SweepViruses.pm new file mode 100644 index 0000000..405562c --- /dev/null +++ b/mail/mailscanner/files/patch-lib:MailScanner:SweepViruses.pm @@ -0,0 +1,44 @@ +--- ../MailScanner-install-4.32.5.orig/lib/MailScanner/SweepViruses.pm Mon Aug 16 18:57:47 2004 ++++ lib/MailScanner/SweepViruses.pm Mon Aug 16 18:58:17 2004 +@@ -2195,7 +2195,7 @@ + MailScanner::Log::InfoLog("ProcessClamAVOutput: %s", $1); + return 0; + } +- return 0 if /^ /; # " inflating", " deflating.." from --unzip ++ return 0 if /^ |^Extracting|module failure$/; # " inflating", " deflating.." from --unzip + if ($clamav_archive && /^$clamav_archive:/) + { + $clamav_archive = ""; +@@ -2206,6 +2206,22 @@ + + MailScanner::Log::InfoLog("%s", $line); + ++ #(Real infected archive: /var/spool/MailScanner/incoming/19746/./i75EFmSZ014248/eicar.rar) ++ if (/^\(Real infected archive: (.*)\)$/) ++ { ++ my ($file, $ReportStart); ++ $file = $1; ++ $file =~ s/^(.\/)?$BaseDir\/?//; ++ $file =~ s/^\.\///; ++ my ($id,$part) = split /\//, $file, 2; ++ ++ $ReportStart = $part; ++ $ReportStart = $Name . ': ' . $ReportStart if $Name; ++ $infections->{"$id"}{"$part"} .= "$ReportStart contains a virus\n"; ++ $types->{"$id"}{"$part"} .= "v"; ++ return 1; ++ } ++ + if (/^(\(raw\) )?(.*?): (.*) FOUND$/) + { + my ($file, $subfile, $virus, $report, $ReportStart); +@@ -2457,6 +2473,9 @@ + # Sample output: + #./1B978O-0000g2-Iq/eicar.com Virus identified EICAR_Test (+2) + #./1B978O-0000g2-Iq/eicar.zip:\eicar.com Virus identified EICAR_Test (+2) ++ ++ # Remove all the duff carriage-returns from the line ++ $line =~ s/[\r\n]//g; + + #print STDERR "Line: $line\n"; + return 0 unless $line =~ /Virus identified (.+)$/; |