Hallo everyone,
I'd like to write a header_check that'll replace (or delete) the
User-Agent header, only if it comes from someone either sending on a
particular port, or using SMTP-AUTH. (The particular port is possible
since SMTP-AUTH is only allowed on one port only, and disallowed on port
25.). Additionally, the check should only restrict on User-Agent as
there are SUbject and Date checks that ought to be applied to all Email
received.
The one I wrote has this, but it'll rewrite every email received by
postfix:-
if /^User-Agent:/
/^User-Agent: Mozilla\/5.0/ REPLACE User-Agent:Replaced
endif
Is this possible?
Best wishes, s