Sender address/name in notifications/invitations

When cells sends out notifications it uses the mail address as configured for the mailer plugin for both, the “From” mail header and the envelope.

Currently, there is no option to set a display name to be used for the “From” mail header which makes it hard for the recipient to identify the application/sender (or cells instance). Here we need the ability to control the senders display name.

The default should by to use the application title (as configured in core.pydio plugin). An option should be mane available to override this mailer setting.

For invitations we face a different issue. Here the users display name and email address as configured for the user account are used for the “From” mail header. This causes issues in most setups as nowadays a system has to have permission (SPF, DKIM, DMARC, …) to send mail on behalf of a sender domain. Also, if authentication is required on the MSA, usually only a specific sender address is allowed for the authenticated session.

The default should be to use the sender address (and display name) as configured for the mailer service. There should be an option to chose between:

  • use the global sender address/name (mailer service setting) - this should be the default
  • use the users mail address/name as “from” mail header, but use the global address for the envelope and add a “sender” mail header
  • use the users mail address/name as “from” mail header and for the envelope

Optionally a “reply- to” mail header should be made configurable and should allow to:

  • do not set a reply-to mail header
  • set a static reply-to mail address
  • use the users mail address for the reply-to mail header

This should cover most configurations.

I have a patch ready for dev that at least implements part of the above (for notifications):

  • add a from name field in mailer config
  • use the from name configured as display name in “from” mail header
  • if the display name is not configured, use the application title as display name
  • if neither are available use the string “Pydio”
1 Like

Nice! Maybe worth making a pull request? I’m sure the devs could tell you if there’s any specific requirements for the PR (unit testing, documentation, etc).

Attached please find a patch that will provide a, lets say, minimum implementation to control the use of the from/sender/envelope address. The patch includes the previous mail.from-name.patch.

Beside of providing a configuration option for a default sender display name it allows to choose between 3 configurations:

  1. use users address/name for From: header and envelope, fallback if none defined (this also is the current behaviour)
  2. use users address/name for From: and Reply-to: headers but use the default address/name for a Sender: header and envelope
  3. use the default address/name for both the From: header and envelope

This should cover most installations and keeps the current behaviour as default.
Translations (except for EN and DE) need finishing.

Hi,
as Geoff pointed it out, you can contribute if you wish to,
first i would advise you to read the guidelines https://github.com/pydio/cells/blob/master/CONTRIBUTING.md
and then proceed.

Regards

as Geoff pointed it out, you can contribute if you wish to,

I will consider this option :wink:

Added a PR (#58)

1 Like