7.9 SMTP Connector

  • The SMTP Connector has two purposes:

    • An SMTP Listener (Server) that receives SMTP emails and saves the emails into the file system. You can then confirm that an email has been received.

    • Send an SMTP email to any SMTP server. You can use this to send an email at the conclusion of a long running test, or send an email to an external system that kicks off a process when an email is received.

  • A typical use case for the listener would be when you need to check if a target system, such as a workflow, is sending emails.

    For example, you configure the workflow to send emails to the SMTP Listener in Identity Validator. In a test, you would start the SMTP server then launch a workflow that sends an email to the approver. You then assert that the email is received before approving the workflow. Finally, the SMTP server is stopped at the end of the test.

  • The SMTP Server starts on port 25 by default. This port is configurable in the connector properties for cases where your platform does not allow port 25 to be used by a non-root process. If you need to change the port but still need to allow access from clients that require port 25, you can configure port forwarding on your platform.

    For example, you start the Identity Validator SMTP Server on port 1079, then on SuSE you could use iptables as follows to forward port 25 traffic to port 1079:

    IMPORTANT:At present they are not working.

    iptables -t nat -A PREROUTING -p tcp --dport 25 -j REDIRECT --to-port 1079
    iptables -t nat -I OUTPUT -p tcp -d 127.0.0.1 --dport 25 -j REDIRECT --to-ports 1079

    To list entries in the table:

    iptables -t nat --line-numbers -n -L