Support de la whitelist pour le domaine local
On peut activer la whitelist automatique pour le domaine local ce qui fait ques les mails qui ont un "from" dans le domaine local ne sont pas filtrés et sont automatiquement accpetés
This commit is contained in:
parent
94b433ba0b
commit
0d7af23658
|
@ -7,6 +7,8 @@
|
|||
<container name='mail' id='13'>
|
||||
<package>eole-rspamd-pkg</package>
|
||||
<service servicelist='rspamd'>rspamd</service>
|
||||
<file filelist='whitelist' name="/etc/rspamd/local.d/multimap.conf" rm='True'/>
|
||||
<file filelist='whitelist' name="/etc/rspamd/map/domain_whitelist.map" rm='True'/>
|
||||
</container>
|
||||
</containers>
|
||||
<variables>
|
||||
|
@ -19,13 +21,20 @@
|
|||
<variable name='rs_spam_box' type='string' description='Nom de la boite de réception des Pourriels'>
|
||||
<value>Pourriel</value>
|
||||
</variable>
|
||||
<variable name='activer_whitelist_domaine' type='oui/non' description='Voulez-vous filtrer les mails qui proviennent des domaines locaux ?'>
|
||||
<value>non</value>
|
||||
</variable>
|
||||
</family>
|
||||
</variables>
|
||||
<constraints>
|
||||
<condition name='disabled_if_in' source='activer_rspamd'>
|
||||
<param>non</param>
|
||||
<target type='servicelist'>rspamd</target>
|
||||
<target type='variable'>rs_spam_box</target>
|
||||
<target type='family'>antispam</target>
|
||||
</condition>
|
||||
<condition name='disabled_if_in' source='activer_whitelist_domaine'>
|
||||
<param>non</param>
|
||||
<target type='filelist'>whitelist</target>
|
||||
</condition>
|
||||
</constraints>
|
||||
<help>
|
||||
|
|
|
@ -0,0 +1,4 @@
|
|||
%if %%activer_whitelist_domaine == 'oui'
|
||||
%%domaine_messagerie_etab
|
||||
i-%%domaine_messagerie_etab
|
||||
%end if
|
|
@ -0,0 +1,9 @@
|
|||
%if %%activer_whitelist_domaine == 'oui'
|
||||
sender_from_domain_whitelist {
|
||||
type = "from";
|
||||
filter = "email:domain";
|
||||
map = "file:///etc/rspamd/map/domain_whitelist.map";
|
||||
symbol = "SENDER_FROM_DOMAIN_WHITELIST";
|
||||
action = "accept"; # Prefilter mode
|
||||
}
|
||||
%end if
|
Loading…
Reference in New Issue