Erlang + SMTP + TLS/SSL

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Erlang + SMTP + TLS/SSL

Dmitrii Dimandt
Does anyone know of an erlang library that can send mail through smtp  
with TLS/SSL enabled (like through gmail).

I'm currently using http://www.lshift.net/~tonyg/erlang-smtp/ (http://www.lshift.net/blog/2007/12/28/erlang-smtp-code-updated 
), and it's super easy to use and works :) I'd like to have some TLS  
as well, though

Thank you
_______________________________________________
erlang-questions mailing list
[hidden email]
http://www.erlang.org/mailman/listinfo/erlang-questions
Reply | Threaded
Open this post in threaded view
|

Re: Erlang + SMTP + TLS/SSL

Tony Garnock-Jones-2
Hi Dmitrii,

Do you want a TLS-enabled SMTP *server* or do you want a *client*?

If you're after a server:

 - you could use stunnel4 to use boring old SSL-tunnelled plain SMTP

 - you could write a generic_ssl_server.erl module, by analogy with
   generic_tcp_server.erl, which you could use in smtp_server:start/2
   to get an stunnel4-like effect without requiring a separate wrapper

or

 - you could implement STARTTLS in smtp_server_session.erl. This is
   by far the trickiest of the options :-)

Regards,
  Tony

Dmitrii Dimandt wrote:

> Does anyone know of an erlang library that can send mail through smtp  
> with TLS/SSL enabled (like through gmail).
>
> I'm currently using http://www.lshift.net/~tonyg/erlang-smtp/ (http://www.lshift.net/blog/2007/12/28/erlang-smtp-code-updated 
> ), and it's super easy to use and works :) I'd like to have some TLS  
> as well, though
>
> Thank you
> _______________________________________________
> erlang-questions mailing list
> [hidden email]
> http://www.erlang.org/mailman/listinfo/erlang-questions
>


--
 [][][] Tony Garnock-Jones     | Mob: +44 (0)7905 974 211
   [][] LShift Ltd             | Tel: +44 (0)20 7729 7060
 []  [] http://www.lshift.net/ | Email: [hidden email]
_______________________________________________
erlang-questions mailing list
[hidden email]
http://www.erlang.org/mailman/listinfo/erlang-questions