From ac79e2e0498669883c2660a69812c2031f40b9a7 Mon Sep 17 00:00:00 2001 From: Zeljko Boros Date: Thu, 29 Apr 2021 13:00:34 +0200 Subject: [PATCH] Dodavanje access lista --- debian/changelog | 1 + debian/dirs | 1 + debian/install | 7 +++++++ debian/postinst | 25 ++++++++++++++++++++++++- 4 files changed, 33 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index 2906ba2..c9bd51f 100644 --- a/debian/changelog +++ b/debian/changelog @@ -4,6 +4,7 @@ postfix-cn (3.4.10+cn10u2) stable; urgency=medium pojavljuje za svaki servis u master.cf * Popravljeno generiranje GECOS aliasa * Dodan RBL eta.cert.hr + * Dodane access liste za lakše blokiranje upornih spamera -- Zeljko Boros Wed, 28 Apr 2021 16:03:04 +0200 diff --git a/debian/dirs b/debian/dirs index 3cb79eb..e0c075a 100644 --- a/debian/dirs +++ b/debian/dirs @@ -1,3 +1,4 @@ var/lib/postfix-cn usr/share/postfix-cn usr/sbin +etc/postfix diff --git a/debian/install b/debian/install index b089b77..fad4a87 100644 --- a/debian/install +++ b/debian/install @@ -1,2 +1,9 @@ carnet_whitelist_clients usr/share/postfix-cn newaliases-gecos usr/sbin +access_client_cn etc/postfix +access_helo_cn etc/postfix +access_sender_cn etc/postfix +access_recipient_cn etc/postfix +access_header_cn etc/postfix +access_mime_header_cn etc/postfix +access_body_cn etc/postfix diff --git a/debian/postinst b/debian/postinst index 818ecff..a88f6ed 100755 --- a/debian/postinst +++ b/debian/postinst @@ -207,7 +207,14 @@ smtpd_recipient_restrictions="reject_invalid_hostname, \ reject_unauth_pipelining, \ permit_sasl_authenticated, \ permit_mynetworks, \ - reject_unauth_destination" + reject_unauth_destination, \ + check_client_access hash:/etc/postfix/access_client_cn, \ + check_helo_access hash:/etc/postfix/access_helo_cn, \ + check_sender_access hash:/etc/postfix/access_sender_cn, \ + check_recipient_access hash:/etc/postfix/access_recipient_cn, \ + check_header_access regexp:/etc/postfix/access_header_cn, \ + check_mime_header_access regexp:/etc/postfix/access_mime_header_cn, \ + check_body_access regexp:/etc/postfix/access_body_cn" # dodaj samo rbl-ove iz debconfa if [ "$rbl" ]; then @@ -399,6 +406,22 @@ do done restart_postfix="yes" + +# obavijest za webmail + +cp-update -t postfix-cn /etc/postfix/main.cf <