Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

AOL Mail Error 421 SERVICE NOT AVAILABLE


shopnix

Recommended Posts

Posted

AOL-Users didn't receive mails from the shop.

 

After some investigations I found not only the solution for this special problem, but some more conflicts with usual spam filters. Here are my results for sendmail:

 

1. MX record in DNS

There was no MX record for the domain part of the Return Path of the mail header. This can be checked with the unix tool dig.

 

dig example.com mx

 

2. Return Path in header:

  1. PHP safe_mode = Off
    It is possible to change the last parameter in the mail function. Search for "EMAIL_TRANSPORT" in includes/classes/email.php. The else for this if contains the mail function for sendmail.
    Change this line to:
    	 return mail($to, $subject, $this->output, 'From: '.$from.$this->lf.implode($this->lf, $this->headers).$this->lf.implode($this->lf, $xtra_headers) , '-f' . $from_addr);


    This has to be done twice, once for the shop and once for the admin.
     

  2. PHP safe_mode = On or Off
    If you have access to the apache configuration, you can insert the following statement (per virtual host):
    php_admin_value sendmail_path "/usr/sbin/sendmail -t -i -f [email protected]"


3. There is no message ID generated by the shop's email routine, and so usually the MTA (i.e. Postfix) generates one. SpamAssassin said MSGID_FROM_MTA_SHORT. To avoid that, I generated my own message ID like this:

return mail($to, $subject, $this->output, 'From: '.$from.$this->lf.implode($this->lf, $this->headers).$this->lf.implode($this->lf, $xtra_headers) . 'Message-ID: <' . date('dmYHis'). session_id() . '@ShopNix.de>' .$this->lf , '-f' . EMAIL_RETURN_PATH);

 

Hope that helps, and it would be nice to get some response!

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...