ont / slacker

Simple smtp email server which redirects emails to slack.
MIT License
34 stars 12 forks source link

Doesn't support ending emails with <cf>.<cf> #2

Closed Joshfindit closed 5 years ago

Joshfindit commented 5 years ago

Attempted to send email via telnet as a test

telnet localhost:8025
Type: EHLO <mail server internet name>
Type: mail from: <your_name@yourdomain.com> and press Enter.
Type: rcpt to: <recipient@recipientdomain.com> and press Enter.
Type: data and press Enter.
Type: Subject: <a subject here> and press Enter.
Type: This is a test message sent from telnet. and press Enter.
Type: . and press Enter

Server responded as expected up until attempting to confirm the contents of the email. It seemed to take <cr/lf>.<cr/lf> as part of the email body and never continued.

ont commented 5 years ago

Telnet on linux by default may send <lf> instead of <cr><lf>. Please see answer: https://stackoverflow.com/a/22974813/434255

Also do this steps:

  1. download latest tag 0.0.4 via docker pull ontrif/slacker (it has fix for None fields)
  2. rerun container
  3. run ncat -x /tmp/out.hex --crlf localhost 8025
  4. enter all your commands and data
  5. check that <cr><lf>.<cr><lf> present in /tmp/out.hex
  6. check that email was sent or error occurs via docker logs slacker

Also check that you fill From and To email fields. Currently values from mail from and rcpt to are not used for comparision with rules.

Fill free to reopen this issue.

Joshfindit commented 5 years ago

Aha. Found the problem: https://github.com/ont/slacker/issues/3

Joshfindit commented 5 years ago

(For reference, the old version did not respond to <cr><lf>.<cr><lf>. Did confirm it was present in the hex file)