[OJS] Email Settings to Envelope Sender and DMARC Compliant

Hi @asmecher

Currently in my working team we have upgraded our OJS’s instances to version and we have explored the Email settings in the config.inc.php file. I have read the PKP DOCS about Email section; however, I have some doubts, specifically about envelope sender and DMARC compliant. In the config.inc.file says:

; Allow envelope sender to be specified
; (may not be possible with some server configurations)
; allow_envelope_sender = Off

And we have asked what means (may not be possible with some server configurations), which is that server configuration to use an envelope_sender?

The other doubt is about DMARC compliant. The config.inc.php file says:

; Force a DMARC compliant from header (RFC5322.From)
; If any of your users have email addresses in domains not under your control
; you may need to set this to be compliant with DMARC policies published by
; those 3rd party domains.
; Setting this will move the users address into the reply-to field and the
; from field wil be rewritten with the default_envelope_sender.
; To use this you must set force_default_enveloper_sender = On and
; default_envelope_sender must be set to a valid address in a domain you own.
; force_dmarc_compliant_from = Off

Specifically that line:

; default_envelope_sender must be set to a valid address in a domain you own.

the domain for the account used in default_envelope_sender should be the same domain that hosts the journal, assuming my journal responds to the domain “myjournal.unam.mx” my account should be as some_user@myjournal.unam.mx?

I hope you can guide us to resolve these doubts. Thank you for your attention to this matter.

Hi @juancure

The way this works is that when you enable the envelope sender, and set default_envelope_sender to an email address, and then also turn force_default_envelope_sender to On as well, all emails coming from your journal will look like this:

From: the address in the default_envelope_sender via XXXXXX
Reply-To: the person who wrote the email’s real address
Subject: whatever it is

The format of the From line is defined in the dmarc_compliant_from_displayname setting. %n gets replaced with the email/name of the envelope sender and %s gets the site name.

What the configuration file means where it says “must be set to a valid address in a domain you own” is that you must also create a valid SPF record in the domain’s DNS. This SPF record must list the IP address of the server hosting your journal.

The email address can be anything you want it to be, as long as the SPF record is set. You want to see something like this in the headers of the message when it is received:

ARC-Authentication-Results: i=1; mx.google.com;
spf=pass (google.com: domain of noreply@yourjournal.com designates as permitted sender)



@jnugent thank you very much for answer.

I have other 2 doubts about the email settings.

  1. The envelope_sender is compatible with Gmail SMTP provider?
  2. The envelope_sender could resolve that in the editorial workflow all the emails coming from the journal have the address established in the config.ing.php instead of the user’s real address?

Best Regards.

Hi @juancure

I’ve never tried using this with Gmail’s SMTP server, to be honest with you. I suspect GMail will do what it wants. The editorial workflow will show the real email addresses of the people involved in the email, not the envelope sender address. It is purely for ensuring that messages pass the SPF test.