1 diff -Nur old/AMAVIS/MTA/Courier.pm new/AMAVIS/MTA/Courier.pm
2 --- old/AMAVIS/MTA/Courier.pm 2003-03-17 23:04:11.000000000 +0000
3 +++ new/AMAVIS/MTA/Courier.pm 2004-07-14 20:24:55.000000000 +0000
6 writelog($args,LOG_INFO, __PACKAGE__.": Accepting message");
8 - #TODO Courier filters cannot rewrite MIME messages, we'd like
9 - #to be able to add a header or something to this message but
10 - #we can't.(yet). Sorry
12 ##Rewrite the message in the queue if we need to add a header
13 - #if ($cfg_x_header) {
14 - # my $queuefile = IO::File->new("+>$$args{'messagefile'}");
15 - # print $queuefile "$cfg_x_header_tag: $cfg_x_header_line\n";
16 - # while (my $line=$$args{'filehandle'}->getline()) {
17 - # print $queuefile $line;
19 - # close($queuefile);
21 + if ($cfg_x_header) {
22 + my $queuefile = IO::File->new("+>$$args{'messagefile'}");
23 + print $queuefile "$cfg_x_header_tag: $cfg_x_header_line\n";
24 + while (my $line=$$args{'filehandle'}->getline()) {
25 + print $queuefile $line;
27 + print STDOUT $queuefile;
31 $$args{'status'} = 'accept';
33 diff -Nur old/etc/amavis.conf new/etc/amavis.conf
34 --- old/etc/amavis.conf 2003-04-08 14:09:56.000000000 +0000
35 +++ new/etc/amavis.conf 2004-07-14 20:26:45.000000000 +0000
37 ; notifiers=Sender, Recipients, Admin
39 ;; What should be inserted into the message's headers if it is let
40 -;; through? This does not work for the Milter or Courier interfaces.
41 +;; through? This does not work for the Milter interfaces.
44 ; x-header-tag = X-Scanned-By