Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-52818

Allow divertallemailsexcept whitelist of emails when using $CFG->divertallemailsto

    XMLWordPrintable

    Details

      Description

      We typically don't use the $CFG->divertallemailsto, we instead set this up instead at the postfix level because we can do more fine grained filtering using recipient_canonical. eg we allow all email through that are to our developers domain, and selected client testing emails so we can do end to end testing with no risk of test emails going to real students.

      But in some cases we want to use the smpt inside moodle rather than at the system level, but we'd still like this level of fine grained filtering. So proposing a new config.php var to complement:

      $CFG->divertallemailsto = 'some@email.com';

      $CFG->divertallemailsexcept = '@catalyst, client@organisation.com';

      divertallemailsexcept would be a comma separated list of whitelist strings which if found in the email let it pass through un-diverted.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Fix Release Date:
                23/May/16