| Courier::Filter::Module::ClamAVd(3pm) | User Contributed Perl Documentation | Courier::Filter::Module::ClamAVd(3pm) |
Courier::Filter::Module::ClamAVd - ClamAV clamd filter module for the Courier::Filter framework
use Courier::Filter::Module::ClamAVd;
my $module = Courier::Filter::Module::ClamAVd->new(
# See the socket options description for details.
socket_name => '/var/run/clamav/clamd.ctl',
socket_host => 'clamav.example.com',
socket_port => '3310',
max_message_size
=> $max_message_size,
max_part_size => $max_part_size,
response => $response_text,
logger => $logger,
inverse => 0,
trusting => 0,
testing => 0,
debugging => 0
);
my $filter = Courier::Filter->new(
...
modules => [ $module ],
...
);
This class is a filter module class for use with Courier::Filter. It matches a message if the configured ClamAV "clamd" daemon detects malware in it.
The following constructor is provided:
%options is a list of key/value pairs representing any of the following options:
As MIME multipart processing can be quite CPU- and memory-intensive, you should definitely restrict the message size to some sensible value that easily fits in your server's memory. 1024**2 (1MB) should be appropriate for most uses of this filter module.
Defaults to the value of the "max_message_size" option, so you don't really need to specify a part size limit if you are comfortable with using the same value for both. See the "max_message_size" option for its default.
All options of the Courier::Filter::Module constructor are also supported by the constructor of the ClamAVd filter module. Please see "new" in Courier::Filter::Module for their descriptions.
See "Instance methods" in Courier::Filter::Module for a description of the provided instance methods.
Courier::Filter::Module, Courier::Filter::Overview.
For AVAILABILITY, SUPPORT, and LICENSE information, see Courier::Filter::Overview.
Julian Mehnle <julian@mehnle.net>
| 2022-10-21 | perl v5.34.0 |