News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Ran into problems sending Mail. Error: 535 Authentication failed

Started by Don Peters, July 22, 2010, 09:36:06 PM

Previous topic - Next topic

Don Peters

A few weeks ago I started to see the following message in my log file (which I review daily):
    Ran into problems sending Mail. Error: 535 Authentication failed
I assumed some new code there was checking to see if a spambot had a valid e-mail address, and that I got this messge because the address was not valid. Now I'm seeing this message more frequently.

The surprise was when I posted a topic and SMF tried to notify my e-mail account of this posting, and my log file reported the same error message about me! It never did this before. Exactly what does this message mean and how can I fix it?

Don

xenovanis

For as far as I know it means there is an autentication problem. This could either be caused by an invalid mailaddress (eg misspelled) or, if you have smtp settings, a wrong server, username, password, name it.

What are the settings you're using?
"Insanity: doing the same thing over and over again and expecting different results."

Don Peters

I'm using the settings I've used over the past 2 years, and they've never been a problem. Specifically, from Configuration|Server Settings|Feature Configuration:

Mail type is SMTP
SMTP server is mail.whitecanker.net
SMTP port is 25

Is that the "settings" you were referring to?

xenovanis

Maybe there are some problems with the mailserver then? It's hard to determine since the problem is not consistent  :(

How about the php mailfunction? Does that work?
"Insanity: doing the same thing over and over again and expecting different results."

Don Peters

I thought about the mailserver. But I sent that account a regular e-mail, and it got thru fine.  In fact, I was notified of your posting just now, so that's more evidence of it working.

However, I just posted a test note to my forum. I think I should have gotten notification of it, and I didn't. On the other hand, I didn't even get an error in the log file this time. If I post to my own forum, shouldn't I still get an e-mail advising me that a posting has taken place?  And now that I think of it, the message "A new member has joined" also seems sporadic, only coming in for about 70% of the new members.

Oh, I don't know anything about the "php mailfunction".

xenovanis

Phpl is the default setting. Since it uses your server settings, it doesn't need to connect to an external mailserver which could reduce the number of glitches. If it works, I'd use that.
"Insanity: doing the same thing over and over again and expecting different results."

Don Peters

Sigh... unfortunately it didn't seem to work, unless I've done something wrong. I changed the default from SMTP to phpl, but when a user tried to register, the log file now reported:

2: mail() [<a href='function.mail'>function.mail</a>]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set()
File: D:\inetpub\vhosts\whitecanker.net\httpdocs\SMFforum\Sources\Subs-Post.php
Line: 661

So I've returned to SMTP, which always used to work. I'm wondering if I should use a port other than 25.

xenovanis

When using php mail, leave the smtp info out  ;)

I'm just wondering why it won't sent out mails though. I tested this on my local testinstall and from there I was able to send emails with the smtp settings. Are you by any change using a gmail account?
"Insanity: doing the same thing over and over again and expecting different results."

Don Peters

Found the problem and fixed it. It was at my end. Here's what happened...

Several months ago I switched over to Norton antivirus, since my ISP provided it for free. They had a feature whereby when you went to a web page and it contained login prompts, Norton would detect it and automatically fill in the username and password. Nice feature, so I started using it. Then one day about two weeks ago I thought I'd play with a little configuration of SMF, and went to Configuration|Server Settings|Feature Configuration and changed a parameter near the bottom of the page, then clicked on Save to do the update. What I didn't notice was the mail configuration at the top of the page. Norton saw it though, and changed it to my SMF login information! When I quickly browsed over it later while debugging, I missed that since the username password combo was correct - I didn't notice the context was wrong.

Never had this sort of thing happen to me before.  :-[

A suggestion: the error message might have been a little more informative here, saying something like "invalid e-mail address" rather than "authentication failed", since that led me down a false path. Or, just before username and password is put into the database, it should be checked for validity, and an error issued then. In that case I probably would have caught it right away.

Anyway, thank you very much for responding on this issue xenovanis!

Don



xenovanis

Glad you solved it :)

FYI, the errormessage you received is not SMF's, but it's a default one bounced by the mailserver. So there's no way SMF could have determined what part of the authentication failed  ;)
"Insanity: doing the same thing over and over again and expecting different results."

Advertisement: