![]() |
| trouble with mailserver authentication from cfmail form |
|
scottmac
|
We have a client site on our CF VPS. The client handles their email through their own network mailserver so we've pointed MX records to their mailservers.
We have a CFMail form on their website - simple form. We've setup SMTP Authentication bypass on the SmarterMail server (our primary server on the VPS) we use to process the mail for the IP of the website and the others we have setup. One of the "to" addresses in the CFMail form is "anemail@thisclientsdomain.com" - which is causing the form to throw a "550 Authentication required for relay" error on the CF Mail.log and CF is dumping the email to an undelivered directory. I think the reason we're getting the relay error is that even with the SMTP Authentication bypass for the IP of the website, since the actual mailserver resides at a different IP, we're getting the relay error?? But I'm not keen on setting the remote mailserver IPs in my SMTP Authentication Bypass list in SmarterMail as I don't want to open some relay hole. Any suggestions? Or am I missing something in this whole setup. Thanks. S |
||||||||||||
|
|
|||||||||||||
| Try This.. |
|
Jason101
Forum Regular
|
You don't necessarily need to disable SMTP authentication.
You can just include the server, user name and password in the CFMail tag. like below:
If you don't want to embed the user name and password in your code, you can store it in the database and call it as a request variable. That way if someone gets a hold of your code, they don't have the email smtp login. |
||||||||||||||
|
|
|||||||||||||||
|
Jason101
Forum Regular
|
I will also add this..
If you are only hosting this website on the VPS, you can set the email server in the ColdFusion administrator under "Mail" Example: user@example.com:password@mail.domain.com That will send the login info for SMTP authentication on every CFmail attempt and you don't have to embed the username/password in your code either. But keep in mind EVERY site using ColdFusion will use this info unless otherwise specified. Hope both of these Help |
||||||||||||
|
|
|||||||||||||
|
scottmac
|
Thanks Jason -
Viable options - but here's my problem. The emails from the form need to go "To" two addresses; one is an account on a mailserver on our VPS - no problem -- the other "To" is an email address on a mailserver not on my VPS - that's the problem. So setting SMTP Authentication for the remote email account doesn't do anything for me since that user isn't on any mailserver on our VPS. I thought just allowing authentication bypass for everything coming out of the IP for the site would take care of it - no dice. I was trying to think if there was some way to alias the user we need to send to remotely?? The relay stuff has always stumped me. S |
||||||||||||
|
|
|||||||||||||
|
Jason101
Forum Regular
|
Can you use 2 CFMail tags? Both with different servers? It will then physically send the email twice. (If I'm not understanding I apologize ) |
||||||||||||||
|
|
|||||||||||||||
|
scottmac
|
That's definitely a thought - I just can't shake the nagging feeling that I'm looking at this backwards - it seems to me that if the email from the form is originating from an IP (the website) that I've disabled the SMTP Authentication requirement for - then the mailserver shouldn't care what email address it's sending the form contents to?? Can't figure out why it's not allowing the relay. I'll keep messing with it. Thanks for you help.
|
||||||||||||
|
|
|||||||||||||
|
jamie
HostMySite Sales Rep
![]()
|
You're right - something is missing here. If you're sending a message via the CFmail tag on a VPS server and Smartermail is setup on the same server then you should be able to exempt your own tag. If you've got more than one IP address the VPS try adding ALL of them to the Smartermail's SMTP AUTH BYPASS list and that should allow a send without auth'ing.
If that doesn't work make a ticket with support and give them a test script they can use so you don't have to send messages to your client. |
||||||||||||
|
|
|||||||||||||
|
scottmac
|
Thanks Jamie - I think we've figured out that it's the remote mailserver kicking a 550 error on submitted forms - we just need to rethink the form a bit. I'll contact support if that doesn't wind up being the issue. S
|
||||||||||||
|
|
|||||||||||||
| trouble with mailserver authentication from cfmail form |
|
||
|



