Problem with a SMTP server in ASP.NET application

  • Thread starter Thread starter Hrvoje Vrbanc
  • Start date Start date
H

Hrvoje Vrbanc

Hello all,

I have a simple ASP.NET application that should send an e-mail on submit
using Mail object. I have configured the application to use a SMTP server
located on the same machine. However, when executed, the script returns an
error:

"The server rejected one or more recipient addresses. The server response
was: 550 5.7.1 Unable to relay for (e-mail address removed)"

What makes this error strange to me is the fact that the very same SMTP
server works fine and sends mails from old ASP pages (that use CDONTS
object) that are also located on the same machine. What could be a problem
with my ASP.NET pages? DNS server is also located on the same machine.

Thank you,
Hrvoje
 
No, I've been using some generic one word name, not a real e-mail address.
But such approach worked in ASP....

Hrvoje
 
Hrvoje Vrbanc said:
I have a simple ASP.NET application that should send an e-mail on submit
using Mail object. I have configured the application to use a SMTP server
located on the same machine. However, when executed, the script returns an
error:

"The server rejected one or more recipient addresses. The server response
was: 550 5.7.1 Unable to relay for (e-mail address removed)"

This is normal and for SPAM protection. SMTP servers now days typically ONLY
accept mail for local accounts. To get them to relay you have to authenticate
against the SMTP server, or be in a list of approved IPs. However most admins
dont set up list of approved IPs as they can be spoofed.

So you need to authenticate.



--
Chad Z. Hower (a.k.a. Kudzu) - http://www.hower.org/Kudzu/
"Programming is an art form that fights back"


ELKNews - Get your free copy at http://www.atozedsoftware.com
 
Back
Top