Page 1 of 1

Has anyone written an SMTP relay?

Posted: Sat Nov 03, 2018 3:04 pm
by pthien
I'm interested in deploying an SMTP relay. So a little app that accepts E-Mail from machines at certain IP addresses, and forwards this through another SMTP server.

The reason I'd like this is, I have some utilities that cannot send via a server that requires authentication.

I've used PureBasic to send E-Mail and it works great (obviously).

But I'm wonder about writing the code to ACCEPT E-mail that will be forwarded.

Has anyone written anything like this and wish to share code?

Re: Has anyone written an SMTP relay?

Posted: Sat Nov 03, 2018 5:38 pm
by HeX0R
Yes, but only unencrypted (no SSL / STARTTLS) and it is running as a web service.

Re: Has anyone written an SMTP relay?

Posted: Sat Nov 03, 2018 8:32 pm
by infratec
Why reinveting the wheel?

If you search in the web for smtp proxy you will find many ready solutions.

Examples:

https://linux.die.net/man/8/smtpp
https://docs.nginx.com/nginx/admin-guid ... ail-proxy/

A complete server solution (we run it as VM)
https://www.proxmox.com/en/proxmox-mail-gateway