Symptom
Email authentication fails in an Embedded Event Manager (EEM) applet when passing a username that contains an "@".
Users may see logs similar to the following, indicating that the establishment of a session to the SMTP server failed:
%HA_EM-3-FMPD_SMTP: Error occurred when sending mail to SMTP server: : error in reply from SMTP server
%HA_EM-3-FMPD_ERROR: Error executing applet statement x.x
Conditions
- Using the "action mail" EEM action to automate the sending of an email to an email server
- The username for authentication contains an "@" symbol
Workaround
Do not use usernames that contain an "@" symbol.
Utilizing a TCL script instead of EEM may be a viable alternative; however, there is no TLS support for secure email within TCL.
Further Problem Description
According to the "action mail" section of the Cisco IOS Embedded Event Manager Command Reference, the server field can be any one of the following formats:
- username:password@host
- username@host
- host
Reference: https://www.cisco.com/c/en/us/td/docs/ios-xml/ios/eem/command/eem-cr-book/eem-cr-a1.html
EEM does not currently support usernames that include an "@" symbol.
This is a feature enhancement request to add the ability to escape an @ sign or a colon in the username or password fields.