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

Create plugin to send messages via XCLIENT #73

Open
4 tasks
alexkiro opened this issue Mar 8, 2017 · 0 comments
Open
4 tasks

Create plugin to send messages via XCLIENT #73

alexkiro opened this issue Mar 8, 2017 · 0 comments

Comments

@alexkiro
Copy link
Contributor

alexkiro commented Mar 8, 2017

We should create a plugin that gets a message and sends it via to a third-party SMTP via XCLIENT

Acceptance criteria

  • The plugin must expose an eval rule for this
  • The eval rule must accept a recipient as an argument
  • The eval rule must accept a server as an argument
  • The plugin must accept options that specify TLS certificate

Workflow:

  • Resolve the MX record of the server
  • Resolve the A/AAAA records of the MX servers
  • Attempt to connect to the A/AAAA records in turn, until one is successful
  • Send the EHLO command
  • Send the STARTTLS command
  • Send the EHLO command again
  • Send the XCLIENT command with the arguments extracted from the message (NAME | ADDR | HELO)
  • Send the EHLO command again
  • Send the sender (extracted from the message)
  • Send the recipient (set in the eval rule argument)
  • Send the message (set in the eval rule argument)
  • If the results (after DATA) is 5XX return True, otherwise return False
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant