I found a serious bug in the va_mail() function of current 4.0.5:
base64_decode("QVVUSCBMT0dJTlxyXG4=") decodes into “AUTH LOGIN\r\n” with the “\” quoted as “\\” = “AUTH LOGIN\\r\\n”
and some other wrong “\r\n” at the end after “RCPT TO".
These values are rejected by the SMTP server so that the emails can’t be send.
There is no easy workaround for this. As va_functions.php is scrambled, you would need to change multiple things.
Perhaps Viart could do a bugfix?
scendix
22 Nov 2010 11:27 PM
here is a fix (try at your own risk):
- open includes/va_functions.php
- replace all occurrences of "fputs(" with "fputs_new("
- add this code BEFORE the closing ?>:
Then your 4.0.5 should be able to send emails via SMTP.
-Christoph
TOCDCO
23 Nov 2010 6:03 PM
scendix:
can you email me?
daniel[dot]risch[at]tocdco[dot]com
scendix
23 Nov 2010 9:38 PM
email what?
the hotfix is described above...
-Christoph
TOCDCO
24 Nov 2010 4:21 PM
I was going to ask you a question, but that's okay if you cannot
Vera
25 Nov 2010 3:31 PM
Yes, you have identified the bug correctly BUT changing only this one file with the error can break other scripts as there exists a tie-in algorithm between encoded scripts. That's why if you experience similar problem please download the WHOLE patch from here: http://www.viart.com/fix_for_va_mail_function_causing_SMTP_problems.html
scendix
25 Nov 2010 3:37 PM
Yes, that's why I did not post any file, but only described on how to apply the hotfix to your own php file.
This will not break any other scripts or integration.
Good that you have made a fix available.
BTW, no need to say thank you. I loved to invest hours of debugging and searching for this bug in your product and then sharing the solution with you and the other users here...