System.Net.Mail SmtpClient SMTP Quit Command

G

Guest

I am using System.Net.Mail for sending mail.

How do I force a SMTP Quit command (SMTP session termination) with the
SmtpClient class ?

Even when the SmtpClient object goes out of scope and I reinstantiate the
SmtpClient class the SMTP session appears to not be terminated. What causes
SMTP session start-up and shutdown with the System.Net.Mail SMTPClient class ?

Thanks
 
H

Henning Krause [MVP - Exchange]

Hello,

IMHO, this is major implementation flaw in the current SMTPClient. The
SMTPClient uses the ServicePointManager internally to cache connections, so
it doesn't send a QUIT command. I don't know if one can gracefully close
such servicepoint instance.

Kind regards,
Henning Krause
 
G

Guest

I need to be able to close the SMTP session and force a
reestablishment.....can you suggest an alternative ?.... another class
?....anything ?
 
E

Eugene Mayevski

Hello!
You wrote on Mon, 17 Sep 2007 07:00:02 -0700:

P> I need to be able to close the SMTP session and force a
P> reestablishment.....can you suggest an alternative ?.... another class
P> ?....anything ?

Check the SMTP client class in SecureBlackbox (see http://www.eldos.com/sbb/net-mime.php
for details)

With best regards,
Eugene Mayevski
http://www.SecureBlackbox.com - the comprehensive component suite for
network security
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top