Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error on validate a specific email address #7

Closed
byman64 opened this issue Jun 27, 2014 · 9 comments
Closed

error on validate a specific email address #7

byman64 opened this issue Jun 27, 2014 · 9 comments
Labels

Comments

@byman64
Copy link

byman64 commented Jun 27, 2014

I can send you the email address. Please send me an email and I will reply.

thanks

[Fri Jun 27 10:20:06 2014] [warn] [client xxx.xxx.xxx.xxx] mod_fcgid: stderr: PHP Fatal error: Uncaught exception 'SMTP_Validate_Email_Exception_Timeout' with message 'Timed out in recv' in /var/www/clients/client6/web12/web/tools/mailcheck/smtp_validateEmail.class.php:627, referer: http://www.mysite.com/mytools/mycheck/
[Fri Jun 27 10:20:06 2014] [warn] [client xxx.xxx.xxx.xxx] mod_fcgid: stderr: Stack trace:, referer: http://www.mysite.com/mytools/mycheck/
[Fri Jun 27 10:20:06 2014] [warn] [client xxx.xxx.xxx.xxx] mod_fcgid: stderr: #0 /var/www/clients/client6/web12/web/tools/mailcheck/smtp_validateEmail.class.php(651): SMTP_Validate_Email->recv(3), referer: http://www.mysite.com/mytools/mycheck/
[Fri Jun 27 10:20:06 2014] [warn] [client xxx.xxx.xxx.xxx] mod_fcgid: stderr: #1 /var/www/clients/client6/web12/web/tools/mailcheck/smtp_validateEmail.class.php(555): SMTP_Validate_Email->expect(Array, 3), referer: http://www.mysite.com/mytools/mycheck/
[Fri Jun 27 10:20:06 2014] [warn] [client xxx.xxx.xxx.xxx] mod_fcgid: stderr: #2 /var/www/clients/client6/web12/web/tools/mailcheck/smtp_validateEmail.class.php(312): SMTP_Validate_Email->rset(), referer: http://www.mysite.com/mytools/mycheck/
[Fri Jun 27 10:20:06 2014] [warn] [client xxx.xxx.xxx.xxx] mod_fcgid: stderr: #3 /var/www/clients/client6/web12/web/tools/mailcheck/validateajax.php(43): SMTP_Validate_Email->validate(Array, 'admin@xxxx...'), referer: http://www.mysite.com/mytools/mycheck/
[Fri Jun 27 10:20:06 2014] [warn] [client xxx.xxx.xxx.xxx] mod_fcgid: stderr: #4 {main}, referer: http://www.mysite.com/mytools/mycheck/
[Fri Jun 27 10:20:06 2014] [warn] [client xxx.xxx.xxx.xxx] mod_fcgid: stderr: thrown in /var/www/clients/client6/web12/web/tools/mailcheck/smtp_validateEmail.class.php on line 627, referer: http://www.mysite.com/mytools/mycheck/

@zytzagoo
Copy link
Owner

Turn on debug, see what's happening (which SMTP command is timing out)...
Maybe try increasing timeout for that command, or it could be an issue with some specific SMTP server even... Hard to tell without more info.

@byman64
Copy link
Author

byman64 commented Jun 27, 2014

I would like give you the email address....how we can exchange it in private?

I switched on the public var debug but I am trying to understand how/where see the debug info...

@byman64
Copy link
Author

byman64 commented Jun 27, 2014

CLI enviroment only?

@byman64
Copy link
Author

byman64 commented Jun 27, 2014

public $debug = true;

Here what I see from cli

php validateajax.php

PHP Fatal error: Uncaught exception 'SMTP_Validate_Email_Exception_Timeout' with message 'Timed out in recv' in /var/www/clients/client6/web12/web/tools/mailcheck/smtp_validateEmail.class.php:627
Stack trace:
#0 /var/www/clients/client6/web12/web/tools/mailcheck/smtp_validateEmail.class.php(651): SMTP_Validate_Email->recv(3)
#1 /var/www/clients/client6/web12/web/tools/mailcheck/smtp_validateEmail.class.php(555): SMTP_Validate_Email->expect(Array, 3)
#2 /var/www/clients/client6/web12/web/tools/mailcheck/smtp_validateEmail.class.php(312): SMTP_Validate_Email->rset()
#3 /var/www/clients/client6/web12/web/tools/mailcheck/validateajax.php(47): SMTP_Validate_Email->validate(Array, 'admin@xxxx...')
#4 {main}
thrown in /var/www/clients/client6/web12/web/tools/mailcheck/smtp_validateEmail.class.php on line 627

@zytzagoo
Copy link
Owner

If $debug is true, there should be echos all over the place (not ideal, but hey...). Unless you're buffering output or something to that effect. You also appear to be using it in an ajax context, so that might complicate things further.

So, please, reduce your problem/context to a simple .php file that includes the class and uses it to validate the address you're having problems with. Run that simple test file and see what the output (and debug output) is.

@byman64
Copy link
Author

byman64 commented Jun 27, 2014

I onlyoverwritten domain, mail and path

root:php test.php

MX records (mymaildomain.it): Array
(
[mail.mymaildomain.it] => 10
[mymaildomain.it] => 0
)

Connecting to mail.mymaildomain.it:25
Connected to mail.mymaildomain.it:25 successfully
<<<recv: 220 SPAMfighter ESMTP service ready

send>>>: EHLO mydomain.com
<<<recv: 250-SPAMfighter SMTP says Hello

<<<recv: 250-SIZE 209715200

<<<recv: 250 OK

send>>>: MAIL FROM:[email protected]
<<<recv: 250 OK

send>>>: NOOP
<<<recv: 250 OK

send>>>: RCPT TO:[email protected]
<<<recv: 250 OK

send>>>: NOOP
<<<recv: 250 OK

send>>>: RCPT TO:[email protected]
<<<recv: 250 OK

send>>>: NOOP
<<<recv: 250 OK

send>>>: RSET
<<<recv: PHP Fatal error: Uncaught exception 'SMTP_Validate_Email_Exception_Timeout' with message 'Timed out in recv' in /mypath/smtp_validateEmail.class.php:627
Stack trace:
#0 /mypath/smtp_validateEmail.class.php(651): SMTP_Validate_Email->recv(3)
#1 /mypath/smtp_validateEmail.class.php(555): SMTP_Validate_Email->expect(Array, 3)
#2 /mypath/smtp_validateEmail.class.php(312): SMTP_Validate_Email->rset()
#3 /mypath/test.php(9): SMTP_Validate_Email->validate()
#4 {main}
thrown in /mypath/smtp_validateEmail.class.php on line 627

@zytzagoo
Copy link
Owner

Hm, at first it looks like it's not receiving a response to a RSET command within 3 seconds?

However, there should've been some additional debug output there (potentially empty) due to code on line 623? Has there been but you maybe removed it?

Can you try changing line 124 (https://github.com/zytzagoo/smtp-validate-email/blob/master/smtp-validate-email.php#L124 and modify the rset timeout from 3 to, hmm, let's say 180? And then try running the script again to see if it makes any difference.

@byman64
Copy link
Author

byman64 commented Jun 27, 2014

Your suggest was right. I changed the "rset" value from 3 to 30 and now it works fine.
That email addressed required around 10 seconds.

May be you have to increase the default value.

thanks
ciao

@byman64
Copy link
Author

byman64 commented Jun 27, 2014

Last info, as you noted, the smtp server is "SPAMfighter" ... so, maybe, the 10 seconds of delay are wanted.

ciao and thanks again

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants