1

Topic: Whitelist recipients

==== Required information ====
- iRedMail version (check /etc/iredmail-release):  0.9.2
- Linux/BSD distribution name and version: Ubuntu 14.04
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): LDAP
- Web server (Apache or Nginx): Nginx
- Manage mail accounts with iRedAdmin-Pro? Yes
- Related log if you're reporting an issue:
====

HI All ,

is it possible to allow sending mails to only whitelist domains or only 1 domain I don't want my users to send mails to any .

thanks.

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: Whitelist recipients

Sure. with iRedMail-0.9.2 and iRedAdmin-Pro-LDAP-2.3.1, it's a little harder to manage this per-user white/blacklisted recipients, but it's much improved in upcoming iRedMail + iRedAdmin-Pro release. screenshot attached for your reference.

It's done in iRedAPD plugin `amavisd_wblist` (note: this plugin is improved in upcoming iRedAPD-1.7.0 to support white/blacklisting recipients), and iRedAdmin-Pro manages the data. (of course you can manage data with SQL command line tools.)

http://www.iredmail.org/images/iredadmin/system_wblist.png

3

Re: Whitelist recipients

thats gr8 news Zhang, but I need it urgently can you guide me how to do it through mysql I need to whitelist only 2 domains recipients.

thanks.

4

Re: Whitelist recipients

Currently, you have to enable iRedAPD plugin 'ldap_recipient_restrictions', but it's removed in upcoming iRedAPD release. So you need to remove this plugin in /opt/iredapd/settings.py when upgrading to new iRedAPD release, and re-configure this white/blacklist stuff (with new iRedAdmin-Pro).

Here's the summary:

*) Enable plugins 'ldap_recipient_restrictions' in /opt/iredapd/settings.py.
*) Manage user's LDIF data with phpLDAPadmin or `ldapvi`, or other LDAP management tools.

Let's take your user 'user@domain.com' for example, this user is allowed to send email to 'gmail.com' and 'hotmail.com', but not other domains.

*) Add ldap attribute/value `mailWhitelistRecipient=@gmail.com` (without quotes) for your user 'user@domain.com'.
*) Add ldap attribute/value `mailWhitelistRecipient=@hotmail.com` for your user 'user@domain.com'.
*) Add ldap attribute/value `mailBlacklistRecipient=@.` for your user 'user@domain.com'.

That's it. Please test it and check iRedAPD log file /var/log/iredapd.log.

5

Re: Whitelist recipients

hi Zhang,

thanks for the great guide ,though I need it global on the entire domain not for specific user is it doable  ?

thanks.

6

Re: Whitelist recipients

I'm afraid that it doesn't support per-domain white/blacklist. That's why we removed this plugin in upcoming iRedAPD release.

BTW, iRedAPD + iRedAdmin-Pro supports global, per-domain and per-user white/blacklists.

7

Re: Whitelist recipients

Zhang,
I understand iRedAPD+iRedAdmin-Pro support global per domain white/blacklists for senders now , and in the upcoming version will support also recipients. right ?? so in the current version can't limit sending globally to only 2 domains .

Thanks.,

8

Re: Whitelist recipients

k-hussein wrote:

I understand iRedAPD+iRedAdmin-Pro support global per domain white/blacklists for senders now , and in the upcoming version will support also recipients. right ??

right.

k-hussein wrote:

so in the current version can't limit sending globally to only 2 domains .

correct.

9

Re: Whitelist recipients

hi Zhang,
sorry for bringing this up again but the management here in my company are nagging on me to limit the recipients.
any news when when the new version will be available or any way to be in beta testing for it ??
thanks.

10

Re: Whitelist recipients

New releases of iRedMail + iRedAdmin-Pro are scheduled to be released in November, after OpenBSD 5.8 release and new Ubuntu releases (hopefully).

It's not recommended to try the latest iRedAdmin-Pro development edition right now, because several components are not stable yet. If you're interested in giving it a try, i summary the steps below, hope it helps you make the decision.

*) Upgrade iRedMail to the upcoming iRedMail-0.9.3 by following this (DRAFT) upgrade tutorial:
http://www.iredmail.org/docs/upgrade.ir … 0.9.3.html

if you're not running iRedMail-0.9.2, please upgrade your iRedMail first. All upgrade tutorials are available here:
http://www.iredmail.org/docs/iredmail.releases.html

*) During upgrading iRedMail, you need to upgrade iRedAPD to the latest iRedAPD-1.7.0. it hasn't been released yet, but you can check out the latest development edition.

Important things are:

1) iRedAPD requires a new SQL database `iredapd`, used to store throtte settings (and throttle tracking info).
2) iRedAPD requires a new SQL table `amavisd.outbound_wblist`, used to store white/blacklists for outbound emails.

Once you have iRedMail-0.9.3 and iRedAPD-1.7.0 running, it's ok to upgrade iRedAdmin-Pro as usual (run 'tools/upgrade_iredadmin.sh').

WARNING: as mentioned above, both iRedMail + iRedAPD + iRedAdmin-Pro are still under development, something may be changed in final release, the changes between current development phase and final release will not be covered in iRedMail upgrade tutorials.

11

Re: Whitelist recipients

hmmm , I guess then I'll have to wait the official release thanks Zhang.