POP3 Library for .NET

时光总嘲笑我的痴心妄想 提交于 2019-12-11 00:51:35

问题


I am creating a windows service which should download mails from a pop3 account and save the attachment if they are CSV files. The mails in the pop3 account can come from any mail client or mailing service or any operating system.

Which is the best pop3 library that i can use?


回答1:


I have used OpenPop.NET quite successfully in the past.




回答2:


http://www.codeproject.com/KB/IP/Pop3MailClient.aspx is a free option that works well for retrieving POP3 email. Using it with SharpMimeTools to access attachments and such like.




回答3:


Or go to this thread: Reading Email using Pop3 in C#




回答4:


MailKit is an Open Source project which is even endorsed as a suitable replacement for Microsoft's own .Net SmtpClient implementation.

From DE0005: SmtpClient shouldn't be used in dotnet/platform-compat

DE0005: SmtpClient shouldn't be used

Motivation

SmtpClient doesn't support many modern protocols. It is compat-only. It's great for one off emails from tools, but doesn't scale to modern requirements of the protocol.

Recommendation

Use MailKit or other libraries.

It is a cross-platform mail client library built on top of MimeKit.




回答5:


Try this library: http://www.codeproject.com/Articles/719490/vmime-NET-Smtp-Pop3-Imap-Library-for-Cplusplus-and

Features:

  • This is a high quality library that can be used in production.
  • SMTP, POP3, IMAP protocols implemented.
  • TLS and SSL encrpyption (using openssl library) with 185 built-in X.509 root certificates.
  • SASL authentication (Simple Authentication and Security Layer).
  • Email builder builds RFC-2822 and multipart messages.
  • HTML email generation with embedded objects.
  • Full support for attachments with automatic mime-type detection of 1010 built-in mime types.
  • Email parser allows to extract attachments or text.
  • You will learn in 15 minutes how to use the library. It follows the KISS principle ("Keep it simple, stupid").
  • This project is mainly written in pure C++ and has a manged C++ wrapper that exposes the functionality to .NET (C# and Visual Basic .NET).
  • The project is written on Visual Studio 2005 and can be imported to any higher Visual Studio version.
  • Fully RFC-compliant implementation.
  • 8-bit MIME and encoded word extensions.
  • Pipelining and chunked message transfer (If the server supports it).
  • Trace output showing the entire communication with the server.
  • Full Unicode support for CJK (Chinese, Japanese, Korean).
  • 32 Bit and 64 Bit version.
  • Very clean code written by very experienced programmers.
  • Demo application in C++.
  • Demo application in C#.
  • All required dependencies (e.g. openssl) are included in the download RAR file. You don't have to download other sources to compile the project.
  • The download contains the VS2005 compiled vmime.NET.dll (32+64 Bit), so if you are a pure C# programmer and don't have Visual Studio C++ installed you can compile the C# demo.
  • The DLL is strong named (signed).
  • GNU GPL license. (Commercial licenses available)


来源:https://stackoverflow.com/questions/4426388/pop3-library-for-net

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!