many hosts, like yahoo or other mail hosts do not return a 250 code.
yahoo:
Could not verify email address at host yahoo.com: 421 Message from (my ip address) temporarily deferred - 4.16.50. Please refer to http://help.yahoo.com/help/us/mail/defer/defer-06.html
other:
Could not verify email address at host somehost: 421 Too much load; please try again later.
therefore many users cant registrate, as their mail isnt listed as valid. in my opinion, if a host returns 421 the mail should be listed as valid
therefore, please change
(line 115)
if (!ereg ("^250", $from)) {
to
if (!ereg ("^250", $from) && !ereg ("^421", $from)) {
and (line 129)
if (!ereg ("^250", $to )) {
to
if (!ereg ("^250", $to ) && !ereg ("^421", $to )) {
thanks!
Comments
Comment #1
Gábor Mayer CreditAttribution: Gábor Mayer commentedComment #2
escoles CreditAttribution: escoles commentedCouldn't get this fix to work for gmail.com or mac.com.
Unfortunately, in my case, only the non-critical failures are being logged in Watchdog. Critical failures (email address can't be accepted) are not being recorded. So I can't contribute anything to the reasons for failure -- this fix might work perfectly well for others.
Comment #3
dbr CreditAttribution: dbr commentedSorry for the long delay. I guess you were at least able to fix the code locally for yourself.
I don't think change to the FIRST comparison to 250 (in $from) is needed, since at this stage, 421 would lead to assuming we cannot test it, and accept it. Actually your watchlog message shows this is what happened, and the email must have been accepted. Am I missing something there?
However you are right about the test of $to, where we might actually reject the email. I changed the code so that doesn't happen with any 4xx code except 450 (mailbox unavailable).
The code is commited to the drupal 6 branch (port to drupal 5 should be straightforward if you need it), and the 6.x-1.x-dev release with it will appear in the next 12 hours. I actually cannot test it, not having access at the moment to a host allowing outbound port 25 connections (more and more common for home users). So review and testing are welcome.
Comment #4
dbr CreditAttribution: dbr commentedThis change is now present in the 6.x-1.1 release.
Comment #5
dbr CreditAttribution: dbr commentedComment #6
dgsiegel CreditAttribution: dgsiegel commentedhow about 5.x?