简体   繁体   中英

Python SMTP Server protocol

I want to build a simple SMTP-Server by using Python which has the ability to authenticate users through default authentication method. No SSL/TLS is needed.

I was able to start a listener on port 25 and connect to different SMTP-Clients like Outlook to log the requests but it seems like it is too complicated to build it by myself.

Is there any library for Python which allows me to create a SMTP-Server and handle the messages by myself? For example, do not send it, but only save a ".eml" file or something.

Thanks for your help!

You should try smtplib

This is the native SMTP library used in Python. Probably is the best to start here and, if you miss something, find a library more robust.

Edit:

For server, you should try SMTPD

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM