/usr/lib/perl5/site_perl/5.8.0/Courier/Config.pm:
use constant COURIER_CONFIG_DIR => '/usr/local/courier/etc';
use constant COURIER_RUNTIME_DIR => '/usr/local/courier/var';
use constant COURIER_FILTER_CONF => COURIER_CONFIG_DIR . '/filters/pureperlfilter.conf';
Julian Mehnle wrote:
Bernard Robbins <[EMAIL PROTECTED]> wrote:
Ok, I think I'm finally squared away after I downloaded the archive and was able to read the example setup files. I've got a error in /var/log/courier-filter.log: Courier::Filter::Module::MIMEParts: IO::Handle: bad open mode: <:bytes at /usr/lib/perl5/site_perl/5.8.0/Courier/Message.pm line 218
That's weird. What is your Perl version (`perl -v`)? What is your operating system?
perl 5.8.0 RedHat 9 Kernel 2.6.1
This is the setup I've got now: pureperlfilter: [...]
There's no need to modify the "pureperlfilter" executable in any case.
Ok.
pureperlfilter.conf: use utf8;
use Courier::Filter::Logger::File; use Courier::Filter::Module::MIMEParts;
$options = ( # Logger Declaration:
logger => Courier::Filter::Logger::File->new( file_name => '/var/log/courier-filter.log', timestamp => TRUE ),
# Module Declarations:
modules => [ Courier::Filter::Module::MIMEParts->new( max_size => $max_size, signatures => [ { file_name => 'file_name.ext' || qr/\.(exe|com|pif|lnk)$/, size => 106496, response => '500 Executable content rejected' } ] ) ] };
That looks generally ok. You need to replace "$max_size" with a concrete number (or remove the "max_size" option), and the one signature in your MIMEParts signatures list needs to be tuned a bit further, though, I guess. But let's take care of that after we solved the "bad open mode" problem.
Removed the $max_size line. I was trying not to modify it much until it was working well and then start tweeking it.
------------------------------------------------------- SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media 100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33 Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift. http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285 _______________________________________________ courier-users mailing list [EMAIL PROTECTED] Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-users
------------------------------------------------------- SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media 100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33 Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift. http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285 _______________________________________________ courier-users mailing list [EMAIL PROTECTED] Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-users