Bummer, I see the $domain variable is not available. RTFM and I see the following note:
15. Data for message ACLs In the case of RCPT (but not MAIL or DATA), $domain and $local_part are set from the argument address. The entire SMTP command is available in $smtp_command. That sucks, as I don't know who the recipient is the virus-infected message is. Yesterday tried to do my scan in the ACL, which works, and then log when a message contains a virus in a router but there seems to be no way to write to the log in a router. In the router, I actually do the scan of the virus scan result and write the message to disk and stop processing. The message is then picked up and placed in quarantine, so I thought writing to a log at that point would be good... but can't figure out any way to write to the log in the router. Is it really not possible, or am I missing it? On Mon, Sep 16, 2019 at 8:51 AM Rob Gunther <red...@gmail.com> wrote: > I am using acl_smtp_data to execute anti-spam/anti-virus checks. > > It works fine. > > I'm now trying to use logwrite if the result of the scan indicates the > message contains a virus. That part is also working, when a virus is > detected I can write to the log. > > The problem is, I want to include the domain of the recipient in the log > but $domain comes up empty. > > I can write the spam score and $sender_address_domain without issue. > > What is the requirement for $domain to be populated? > > > Rob > -- ## List details at https://lists.exim.org/mailman/listinfo/exim-users ## Exim details at http://www.exim.org/ ## Please use the Wiki with this list - http://wiki.exim.org/