Ubuntu/Linux or Node.js based method of sending emails
I have an internal network smtp server that I need to go through to send emails. I've gotten it to work with Nodemailer but it appears to fail after the greeting, with the "error" message below. It's respond开发者_StackOverflow中文版ing with 250, so I'm not sure why it's not sending, but I was wondering if anyone knows of a Linux/Ubuntu based library I can use to accomplish this task via the CLI.
Server responded with 250-hostname Hello [ip]
250-TURN
250-SIZE
250-ETRN
250-PIPELINING
250-DSN
250-ENHANCEDSTATUSCODES
250-8bitmime
250-BINARYMIME
250-CHUNKING
250-VRFY
250-X-EXPS GSSAPI NTLM LOGIN
250-X-EXPS=LOGIN
250-AUTH GSSAPI NTLM LOGIN
250-AUTH=LOGIN
250-X-LINK2STATE
250-XEXCH50
250 OK
Um, that's not an error. 250
is a status code that means ok. What you have listed is the server's response to your EHLO
command. Each line that start with 250
lists an extended SMTP feature that your server supports.
Next step? If authorization is required, send an AUTH
command. If not, start a mail transaction using MAIL
, FROM
, and DATA
.
I think before proceeding you should take some time to read up on the basics of SMTP. Then this would make more sense to you.
I can't answer this, but make sure to stop into #node.js and ask questions! Make sure to report back with your findings.
JimBastard on IRC (aka Marak), is the creator of node_mailer, an alternative, so he'd be the guy to message, though other people might be able to help you too.
精彩评论