How to Get, Add, Delete, Distribution List using zmprov and How to restrict DistributionList.
:- How to add DistributionListMember.
:- How to list all DistributionList.
:- How to check DistributionListMember in our exsiting DL
Note:- Here is only one member which add earlier.
:- Now i am going to add more member.
:- How to remove DistributionListMember.
:- How to rename DistributionList.
:- How to Delete DistributionList
How to restrict DistributionList
We do that through recipent restraction.
:- Login as zimbra user Put your domain or user who can send email to your protected DL or users
Note:- We can can allowed user or domain as per requirement
:- This is your list of email addresses that may only receive email from permitted senders which we have created above
Note:- In above file we can put DL,Email,Domain as per requirement.
:- Now we have to do postmap
[[email protected] ~]$ postmap /opt/zimbra/postfix/conf/permitted_senders
[[email protected] ~]$ postmap /opt/zimbra/postfix/conf/protected_recipients
[[email protected] ]$ vim /opt/zimbra/conf/zmconfigd/smtpd_recipient_restrictions.cf
check_recipient_access hash:/opt/zimbra/postfix/conf/protected_recipients <——-Put this line—>
%%contains VAR:zimbraServiceEnabled cbpolicyd, check_policy_service inet:localhost:@@[email protected]@%%
%%contains VAR:zimbraMtaRestriction reject_invalid_helo_hostname%%
%%contains VAR:zimbraMtaRestriction reject_non_fqdn_helo_hostname%%
%%contains VAR:zimbraMtaRestriction reject_non_fqdn_sender%%
%%contains VAR:zimbraMtaRestriction reject_unknown_client_hostname%%
%%contains VAR:zimbraMtaRestriction reject_unknown_helo_hostname%%
%%contains VAR:zimbraMtaRestriction reject_unknown_sender_domain%%
%%explode reject_rbl_client VAR:zimbraMtaRestrictionRBLs%%
%%contains VAR:zimbraMtaRestriction check_policy_service unix:private/policy%%
:- Put these lines at botam in main.cf
[[email protected] ]$ vim /opt/zimbra/postfix/conf/main.cf
permitted_senders = check_sender_access hash:/opt/zimbra/postfix/conf/permitted_senders, reject
smtpd_restriction_classes = permitted_senders
[[email protected]]$ postfix reload
/postfix-script: refreshing the Postfix mail system
Note:- Please check mail through sending mail.Only prabhat([email protected]) can send mail.
:- Send mail from other account ([email protected])
:- You can also check in zimbra.log that [email protected] is not able to sendmail on DL
CEO, KV IT-Solutions Pvt. Ltd. | [email protected] | 9810028374|
Linux Professional and an Industrial Trainer | 20 + years Experience in IT Industry
” We are born free, No Gate and Windows can snatch our freedom “