SYSTEM WARNING: 'date_default_timezone_get(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone.' in '/usr/share/mantis/www/core.php' line 264

0003059: spam admin wrong syntax - MantisBT
MantisBT - Endian Firewall
View Issue Details
0003059Endian FirewallProxy - SMTPpublic2010-07-12 10:212011-03-30 14:36
luca-endian 
peter-endian 
normalminorsometimes
confirmedopen 
2.3.1 
 
0003059: spam admin wrong syntax
Jul 12 00:06:19 efw-xx-xx amavis[26286]: (26286-06) (!)SEND via SMTP: postmaster@efw-xx-xx.localdomain -> <luca@xx.com>,ENVID=AM..201007
11T220619Z@efw-xx-xx.localdomain 501 5.1.7 Failed, id=26286-06, from MTA([127.0.0.1]:10025): 501 5.1.7 Bad sender address syntax
Jul 12 00:06:19 efw-xx-xx amavis[26286]: (26286-06) (!)FAILED to notify admin: 501 5.1.7 Failed, id=26286-06, from MTA([127.0.0.1]:10025): 501 5.1.7 B
ad sender address syntax
purple
Issue History
2010-07-12 10:21luca-endianNew Issue
2010-07-12 10:21luca-endianTag Attached: purple
2010-09-21 20:25peter-endianStatusnew => acknowledged
2010-12-22 10:59luca-endianNote Added: 0005405
2010-12-22 11:00luca-endianNote Edited: 0005405
2011-02-09 13:26diwodaNote Added: 0005648
2011-02-09 14:39luca-endianCustomer Occurencies => 2-3
2011-02-09 14:39luca-endianCustomer Occurencies2-3 => 4-6
2011-02-09 14:40luca-endianNote Added: 0005650
2011-03-04 15:46simon-endianNote Added: 0005825
2011-03-04 16:05diwodaNote Added: 0005828
2011-03-04 16:10simon-endianNote Added: 0005829
2011-03-04 16:11simon-endianNote Edited: 0005829
2011-03-04 16:26diwodaNote Added: 0005830
2011-03-04 16:36simon-endianStatusacknowledged => new
2011-03-04 16:36simon-endianAssigned To => lorenzo-endian
2011-03-04 16:36diwodaNote Edited: 0005830
2011-03-04 16:37simon-endianNote Added: 0005831
2011-03-07 15:45christian-endianAssigned Tolorenzo-endian => simon-endian
2011-03-07 15:45christian-endianStatusnew => feedback
2011-03-07 15:45christian-endianStatusfeedback => new
2011-03-07 15:45christian-endianAssigned Tosimon-endian => lorenzo-endian
2011-03-07 15:45christian-endianStatusnew => feedback
2011-03-30 14:36lorenzo-endianNote Added: 0006042
2011-03-30 14:36lorenzo-endianAssigned Tolorenzo-endian => peter-endian
2011-03-30 14:36lorenzo-endianStatusfeedback => confirmed

Notes
(0005405)
luca-endian   
2010-12-22 10:59   
(edited on: 2010-12-22 11:00)
we should fix it because so far is the only way to know when a mail is refused as spam..
and of course to check false positive emails

(0005648)
diwoda   
2011-02-09 13:26   
The solution which worked for me for all 2.3 community and commercial appliances...

greetings,
Johann

Connect via SSH and navigate to /usr/sbin and open the file amavisd with an editor (such as Notepad++ or MacVim/Textmate)

At about line 12488 search for the following and replace the lines marked with "-" with that marked with "+" (copy&paste will do ;-) )

                         $msginfo->sender_smtp);
      $hdrfrom_admin = expand_variables($hdrfrom_admin);
      my($mailfrom_admin_q);
 - if (defined $mailfrom_admin) {
 - $mailfrom_admin_q = qquote_rfc2821_local($mailfrom_admin);
 - } else { # defaults to email address in hdrfrom_notify_admin
 + if (!defined($mailfrom_admin)) {
 + # defaults to email address in hdrfrom_notify_admin
        $mailfrom_admin_q = (parse_address_list($hdrfrom_admin))[0];
        $mailfrom_admin = unquote_rfc2821_local($mailfrom_admin_q);
      }
 + $mailfrom_admin_q = qquote_rfc2821_local($mailfrom_admin);
      my($notification) = Amavis::In::Message->new;
      $notification->rx_time($msginfo->rx_time); # copy the reception time
      $notification->log_id($msginfo->log_id); # copy log id


and at about line 12566


          $r->setting_by_contents_category(cr('hdrfrom_notify_recip_by_ccat'));
        $hdrfrom_recip = expand_variables($hdrfrom_recip);
        my($mailfrom_recip_q);
 - if (defined $mailfrom_recip) {
 - $mailfrom_recip_q = qquote_rfc2821_local($mailfrom_recip);
 - } else { # defaults to email address in hdrfrom_notify_recip
 + if (!defined($mailfrom_recip)) {
 + # defaults to email address in hdrfrom_notify_recip
          $mailfrom_recip_q = (parse_address_list($hdrfrom_recip))[0];
          $mailfrom_recip = unquote_rfc2821_local($mailfrom_recip_q);
        }
 + $mailfrom_recip_q = qquote_rfc2821_local($mailfrom_recip);
        my($notification) = Amavis::In::Message->new;
        $notification->rx_time($msginfo->rx_time); # copy the reception time
        $notification->log_id($msginfo->log_id); # copy log id
(0005650)
luca-endian   
2011-02-09 14:40   
hey diwoda, thanks for the hint!
(0005825)
simon-endian   
2011-03-04 15:46   
looks like the patch above is inverted

the lines with + are already present in /usr/sbin/amavisd
the lines with - not

do i assume correctly that it is inverted and i need to replace the + with the - lines?
(0005828)
diwoda   
2011-03-04 16:05   
the lines marked with + are now present in 2.4 but not in 2.3 ...

this modification only works (as far as I've tested it) for 2.3!
(0005829)
simon-endian   
2011-03-04 16:10   
(edited on: 2011-03-04 16:11)
thx for the info!

so it is fixed with the 2.4 package of the amavisd but not on 2.3?

looks like it is fixed in amavisd-new 2.6.4 which is available on 2.4.

on 2.3 amavisd-new 2.6.2 is used. can you confirm that?

Regards,
Simon

(0005830)
diwoda   
2011-03-04 16:26   
(edited on: 2011-03-04 16:36)
jup, I can confirm this, but I can not confirm the correct spam notification function in 2.4 because I've not tried it out in 2.4 till today

but perhaps you can confirm this?

greets,
Johann

(0005831)
simon-endian   
2011-03-04 16:37   
we will run some additional test with 2.4 to be sure.

Thx for your help!

Regards,
Simon
(0006042)
lorenzo-endian   
2011-03-30 14:36   
Hi all,

I can confirm that the problem exists on 2.3 and does not exists on 2.4 .

As suggested by Simon, this could be related to the fact that EFW 2.4 runs Amavis 2.6.4 and EFW 2.3 runs Amavis 2.6.2.

Thanks to all for the info provided!

Lo