2

I have setup a receiving Postfix mail server. Here i have custom code written that parses the whole mail received by postfix and use the headers, body and attachments separately for different uses.

I have currently added SPF and DKIM checks in postfix that result in appending of their results in the mail header to indicate about the character of the mail.

Also i am planning to implement postfix anti-UCE features using DNS based Real time black hole lists (DNSRBL), for this i have added the following:

'smtpd_recipient_restrictions = reject_rbl_client zen.spamhaus.org, reject_rbl_client bl.spamcop.net'

in my Postfix's main.cf file.

My question is, how can I append the results of this check inside the mail headers that are being received?

Thanks in advance!!!

Ashish

2 Answers 2

2

Could you extend your custom parsing to programatically query the RBL in question and then handle the response? i.e., pass the sending address to the RBL, get response, add X- header.

You'd probably want to turn off the smtpd_recipient restrictions if you did this just to reduce the number of hits against the RBL servers.

1

This post is quite old; but is the only one we found that talks about just that (adding a header insead of rejecting, based on RBL result).

So I wonder if you actually made it possible, as we are looking for that behaviour (in order to quarantine, instead of reject, mails)

Thanks

1
  • Have forgotten what solution I implemented, will check my old notes and see if I can provide you with something useful. Sep 6, 2023 at 11:13

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .