|
|
@ -2,7 +2,7 @@ |
|
|
|
my $clam = $clamd{'status'} || 'disabled'; |
|
|
|
my $clam = $clamd{'status'} || 'disabled'; |
|
|
|
return '' unless ($clam eq 'enabled'); |
|
|
|
return '' unless ($clam eq 'enabled'); |
|
|
|
my $max = $clamav{StreamMaxLength} || '25M'; |
|
|
|
my $max = $clamav{StreamMaxLength} || '25M'; |
|
|
|
my $limit = $max |
|
|
|
my $limit = $max; |
|
|
|
$limit =~ s/[KMG]$//; |
|
|
|
$limit =~ s/[KMG]$//; |
|
|
|
if ($max =~ m/G$/){ |
|
|
|
if ($max =~ m/G$/){ |
|
|
|
$limit = $limit * 1024 * 1024 * 1024; |
|
|
|
$limit = $limit * 1024 * 1024 * 1024; |
|
|
@ -18,4 +18,5 @@ $limit -= 1024 * 1024; |
|
|
|
$OUT .=<<"EOF"; |
|
|
|
$OUT .=<<"EOF"; |
|
|
|
\$clamdScan = 'unix:///var/clamav/clamd.socket'; |
|
|
|
\$clamdScan = 'unix:///var/clamav/clamd.socket'; |
|
|
|
\$scanMax = $limit; |
|
|
|
\$scanMax = $limit; |
|
|
|
|
|
|
|
EOF |
|
|
|
} |
|
|
|
} |
|
|
|