防止反病毒阻止使用C#发送电子邮件 [英] Prevent Anti-Virus to block outgoing email with C#
问题描述
但是我的问题是McAfee正在阻止请求,就像是一种病毒一样。我的机器上没有权限编辑McAfee设置,是否可以通过C#代码修复?
谢谢
可能McAfee阻止端口25(SMTP)上的传出连接,只允许应用程序的白名单发送电子邮件。
您可以做的是:
- 将邮件放在mailto:// url中。执行mailto://,就像它是一个普通的命令行一样。这将要求用户的输入,但您可以为用户创建一个不错的模板。 (语法)
- 发送通过您的普通电子邮件客户端(Outlook,Notes)发送电子邮件,如果他们有一个API。
- 使用具有API的基于Http / Web的提供商。公共的可能也被McAfee阻止。但是你可以创建&自己主持一项服务
- 也许你们有一个放置文件夹,您可以在其中放置电子邮件服务器接收的电子邮件。
I have an application with a static class that is capturing all errors that happens during the runtime (if its the case) and when process is done, it sends out an email with the list of errors so I or any other developers can address those errors.
However my problem is that McAfee is blocking the request, as if it was a kind of virus. I do not have rights on my machine to edit McAfee settings, is it possible to fix it through C# code?
Thank you
Probably McAfee is blocking outgoing connections on port 25 (SMTP), only allowing a white list of applications to send email.
What you can do is:
- Put the email in a mailto:// url. Execute the mailto:// as if it is a normal command line. This will ask for input from the user, but you can create a nice template for the user. (syntax)
- Send the email through your normal email client (Outlook, Notes), if they have an API for that.
- Use a Http/Web based provider that has an API. Public ones are probably also blocked by McAfee. But you could create & host a service yourself. Be very carefull to only allow traffic from within your company.
- Maybe you company has a "drop folder", where you can drop emails that are picked up by the email server.
这篇关于防止反病毒阻止使用C#发送电子邮件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!