I cannot seem to figure out how to get the system.net.mail class to work with an smtp server which utilises base64 logon credentials.
I have successfully sent an email from the smtp server over telnet by manually encoding the username and password to a base64 string - which resulted in a successfully transmitted email over the remote smtp server.
My problem now is getting my web.config to send those credentials to that remote smtp server encoded as base64. I have tried placing the "already" encoded logon details in my web.config but that did not seem to do the trick. I have tested on our local exchange
which worked great and the mail message was relayed.
The only problem I have is getting the encoded credentials over to the remote host. Am I missing a parameter which declares that the username and password is already encoded and does not try to re-encrypt the details on transmission (if this is what it does)?
Below is a line from my web.config.
As suggested everything works fine doing it manually through telnet and my web.config works fine through our local exchange. So it appears as though I have a incorrectly configured web.config for base64 conversion.
Any help would be appreciated. Oh and I must utilise this host as they are the webhost for my domain.
dvine
Member
78 Points
85 Posts
system.net.mail and auth login base64 encoding
Aug 11, 2008 11:43 PM|LINK
Howdy,
I cannot seem to figure out how to get the system.net.mail class to work with an smtp server which utilises base64 logon credentials.
I have successfully sent an email from the smtp server over telnet by manually encoding the username and password to a base64 string - which resulted in a successfully transmitted email over the remote smtp server.
My problem now is getting my web.config to send those credentials to that remote smtp server encoded as base64. I have tried placing the "already" encoded logon details in my web.config but that did not seem to do the trick. I have tested on our local exchange which worked great and the mail message was relayed.
The only problem I have is getting the encoded credentials over to the remote host. Am I missing a parameter which declares that the username and password is already encoded and does not try to re-encrypt the details on transmission (if this is what it does)? Below is a line from my web.config.
As suggested everything works fine doing it manually through telnet and my web.config works fine through our local exchange. So it appears as though I have a incorrectly configured web.config for base64 conversion.Any help would be appreciated. Oh and I must utilise this host as they are the webhost for my domain.
Thank you,
Eldin