Tuesday, June 6, 2017

avast VS my Programm

Leave a Comment

I have problem with my program. I make a simple mail-messenger, and in this code :

        var mail = new MailMessage();         var smtpServer = new SmtpClient("smtp.mail.ru");         smtpServer.Port = 25;         smtpServer.Credentials = new          NetworkCredential("@mail.ru", "pass");         smtpServer.EnableSsl = true;                        mail.Body = text;         mail.From = new MailAddress("@mail.ru");         mail.To.Add("@mail.ru");         smtpServer.Send(mail);           // in this moment 

Avast find the idp generic in moment of mail send. The other antiviruses (eset32, Kaspersky,cureit) do not see problems and danger in code. I also was try to send mail with mailkit.dll. how can I fix it?

1 Answers

Answers 1

Your best bet is probably using the standard SMTP client-to-server email submission port: 587.

smtpServer.Port = 587; 

If you, for whatever reason, can't use the standard email submission port, use the Avast GUI to make exceptions. Doing it through the antivirus directly should allow your program to run on your machine, and that's all you want, right? ;)

You can try:

  • Excluding your build directory from live scans
  • Authorizing your process to use port 25
  • Avast help pages for further reading
If You Enjoyed This, Take 5 Seconds To Share It

0 comments:

Post a Comment