# How to forward mail copy with sendmail BEFORE invoking spamd (spamassassin)?



## sidney2017 (Dec 17, 2021)

Hi,

I have sendmail running with spamd (+procmail evaluation of the spam header generated by spamassassin) on a domain1.tld and postfix with rspamd set up on a new machine (domain2.tld). 

I would like to make a comparison between the spam detection rate of Spamassassin and rspamd and for this purpose I would like to forward all mails sent to an emailaccount spamassassin@domain1.tld also as a copy to rspamd@domain2.tld BEFORE the checking and marking by Spamassassin on domain1.tld, so that the mails are unchanged and rspamd can do its job on domain2.tld. 

This way I can make a comparison with regard to the detection rate of Spamassassin and rspamd. 

The question is, where do I have to start, so that the above mentioned mail copy is forwarded to rspamd@domain2.tld, before Spamassassin does its work on domain1.tld. If the mail arrives on domain1.tld in procmail, Spamassassin has already done its job and set the mail headers accordingly. 

Does anyone have an idea how I can implement the desired scenario? 

Thanks and best regards
sidney2017


----------

