Re: regexp not blocking attachments

From: Todd Lahman (no email)
Date: Sat Dec 01 2001 - 22:29:19 EST


> In /etc/postfix/main.cf I have:
> body_checks = regexp:/etc/postfix/body_checks

That's close you just left off the end:
body_checks = regexp:/etc/postfix/body_checks.regexp

> /etc/postfix/body_checks contains only the following (as one line):
> /^(Content-(Type|Disposition):.*|[[:space:]]*(file)?)name=("[^"]*|[^[:space:
> ]]*)\.(exe|com|scr|pif|bat|lnk|dll|vbs|js)[[:>:]]/ REJECT

The following line should all be on one line, and it will reject what you want. Remove any entries that you want to allow through:

/^(content.*[[:space:]]+|[[:space:]]*)(filename|name)=".*\.(scr|pif|exe|com|bat|shs|shb|vxd|rm|chm|vbs|ini|cmd|do|hta|xl|reg|lnk|js|jse)"/ REJECT

-
To unsubscribe, send mail to with content
(not subject): unsubscribe postfix-users








Hosted Email Solutions

Invaluement Anti-Spam DNSBLs



Powered By FreeBSD   Powered By FreeBSD