Is there a way to have header checks happen as a condition during
smtpd_recipient_restrictions but not happen other times?
Something like assign the header check to a restriction class which
can be called on during a check_recipient_access?
End goal is to conditionally run header matching/action based on
recipient checked against mysql:/lookup
I guess i should elaborate on that more, the real real end goal is
per-recipient kdim enforcement. Since it's impossible to control if
milter/dkim runs or not based on recipient, my next option to explore is
allowing dkim to run passive to just create the headers, then during
smtpd_recipient_restrictions based on recipient decide whether or not to
take action on the information in the dkim header to reject or allow the
mail.