Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TLS connection to smtp server with password #2

Open
samueleaton opened this issue Oct 27, 2016 · 8 comments
Open

TLS connection to smtp server with password #2

samueleaton opened this issue Oct 27, 2016 · 8 comments

Comments

@samueleaton
Copy link

I'm trying to get something like you would see here.

For reference, I've used a node.js module, Nodemailer, that is able to implement that as seen in this example. It looks like the bulk of the work happens in this module.

I would like to add some more secure functionality to smtp. Let me know if there is anything I can do to help.

@ray-delossantos
Copy link
Owner

Hi @samueleaton:

@sdogruyol asked for the same functionality for gmail smtp. There's 2 main features to implement, TLS connections (OpenSSL::SSL::Context::Client, https://crystal-lang.org/api/master/OpenSSL/SSL/Context/Client.html ) and Plain Auth (Super simple to implement). if you know the RFC's related to this features, you could help us with a Pull Request. I have a rough estimate to implement all the features in the first week of November, but i'm very bad with release dates :), so if you can help i'll appreciate it a lot.

@samueleaton
Copy link
Author

Yeah looking at how some other libs do it it didn't seem like too much work. We should think of a good api and then get crackin'.

Even though there is more demand for gmail, I think most would agree that it should work for many services and let the user be able to "plug 'n play". The nodemailer team did some work for us and has gathered a list of common services with domain alias, ports and security types.

@ray-delossantos
Copy link
Owner

Maybe take in consideration this api:

http://ruby-doc.org/stdlib-2.0.0/libdoc/net/smtp/rdoc/Net/SMTP.html

@samueleaton
Copy link
Author

yeah i was reading the source code earlier today and saw that ruby was using the openssl lib like you suggested.

@ray-delossantos
Copy link
Owner

@crisward
Copy link

I'm using https://github.com/arcage/crystal-email to auth with tls. Seems to work. Perhaps bringing the libs together somehow could help?

@ray-delossantos
Copy link
Owner

Hello @crisward

Nice to know about this lib, i'll put a message in the readme file. Is there something in smtp.cr that you'll like to see in the crystal-email code base to cover in a PR?.

@crisward
Copy link

Crystal email doesn't support HTML emails, and smtp.cr doesn't support attachments or tls.
It'd be nice if we had one library with all the features.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants