the built in localhost SMTP server on the webserver itself. That might
"Patrick Santry" <super> wrote in message
news:a0cefb5a-b968-4b48-b2f6-0a63d7b0c982@webslinger...
> I think the issue may be there is a mail server on another machine, and
the
> web server needs to be able to send mail using this SMTP gateway.
>
> Yes you will need to enable relaying on the SMTP gateway in order for your
> application to send mail to it, but most mail servers support restricting
> relaying for an IP subnet, address or FQDN. IIS allows you to restrict
relaying
> for these criteria, by going to the properties of the Web server, then
> SMTP.Your admin should know this, or you can most likely look through the
> help files to figure it out.
>
>
> "Thomas R" <TRabsolutetlynospam@thomas-regin.com> wrote in message
> news microsoft.public.dotnet.framework.aspnet:<TRuvb.7630$Y%
> 1.5218@news.get2net.dk>...
>
> >Mark,
> >
> >Although I'm no expert on this subject I don't see how using the built in
> >System.Web.Mail class could ever "open up for relaying spam". The mail
> class
> >and your SMTP server has absolutely nothing to do with eachother other
> than
> >an occasional handshake whenever you are trying to send a mail.
> >
> >MailMessage m = new MailMessage();
> >m.Subject = "Hello world";
> >m.From= "myemail@email.com";
> >m.To = "youremail@email.com";
> >m.Body = "This is just a test";
> >SmtpMail.SmtpServer = "localhost"; //or whatever SMTP server that
> normally
> >allows you to relay (could be your ISPs)
> >SmtpMail.Send(m);
> >
> >What happens here is simply that the Send method of SmtpMail class
> connects
> >to the specified SMTP server and sends the mail!
> >
> >This is a transcript of what's going on when sending a mail:
> >
> >>HELO localhost //Function handshakes with SMTP-server
> >>250 locahost Hello localhost // Server responds
> >>mail from: myemail@email.com //function sends sender email
> >>250 Sender OK //Server accepts
> >>rcpt to: youremail@email.com //function sends recipients email
> >>250 Recipient OK. Will forward //Server accepts (OR denies!!)
> >>data //Starting actual body and subject
> >>subject: "Hello world"
> >>
> >>This is just a test
> >>. //the dot tells the smtp server that message is completed
> >>250 Message accepted for delivery //Server accepts and sends!
> >
> >I don't see any reasons why all of a sudden your SMTP server should be
> open
> >for spammers. This can only be changed by a setting inside your
Mailserver,
> >and not by .Net itself unless you are able to code directly to your mail
> >server!
> >
> >If anyone else has another (or better) explanation, please disregard this
> >one! ;)
> >
> >Hope that it helps,
> >
> >Thomas Regin.
> >
> >
> >"mark" <mark@barkerspecialty.com> wrote in message
> >news:f3435d59.0311210957.74e3e67a@posting.google.com...
> >> I need to send order confirmation emails through my asp.net
> >> storefront. With my Asp 3.0 sites I use cdonts with no issues. I've
> >> researched the system.web.mail asp.net way and haven't got it to work.
> >> It boils down to the online smtp server declaration. I say a
> >> solution to active relay on the mail server but in the next sentence
> >> it said doing this may open your server up to spam relays. Not what I
> >> want to do. I've tried using cdonts with asp.net and actually was
> >> surprised to see it work offline while I was testing on my machine.
> >> When I tried it online I got an exception. Any thoughts on this? I
> >> even tried to use server.transfer("old asp3.0 email script") to
> >> trigger the email but also received an exception.
> >
> >
>
> --------------------------------------------------------------------------
----------
> Posted from WWWCoder.com
> The .Net Portal Developer's Resource Directory;
http://www.wwwcoder.com > Extensive collection of original articles and resources on .Net
development.
> http://www.wwwcoder.com; for downloads visit: http://www.4aspx.net