-
Improvement
-
Resolution: Fixed
-
Major
-
3.1
-
MOODLE_31_STABLE
-
MOODLE_31_STABLE
-
MDL-53102-messageid -
The Message-ID sent by the forums looks like this:
Message-ID: <4bbdaa38e103be58480dec51fb53776b007b2e41917d6e1be74a1e5d5245e475@moodle.local>
All other emails though don't have a message id set in moodle so it gets autogenerated somewhere up the chain which defaults to the OS hostname box which is often different to the moodle domain, eg so from my dev box with the same moodle but an email message from somewhere other than the forum:
Message-ID: <c6c95b91d0859cca25bb324a6649fc46@silverbirch>
So proposing to detect missing message id's and auto generate them in email_to_user() to make sure they exist with the right domain, and also refactoring some of the generation logic in mod/forum so it can be used from all plugins / core, and also consistent everywhere.
This is blocking MDL-53023 which will enable postfix or another MTA to communicate SMTP results back to moodle, but it needs to know which moodle the email came from in the first place. The only reliable place to get this is MessageID, all other fields could be indistinguishable across multiple moodle instances all using the same MTA.