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

Invalid Message-ID header in forum post notifications

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 3.2, 3.2 regressions
    • Fix Version/s: 3.2.1
    • Component/s: Email, Forum, Libraries
    • Labels:
    • Testing Instructions:
      Hide

      To test this, you need outgoing emailing working. You may find $CFG->divertallemailsto useful.

      1. As a user, subscribe into a forum, using the default forum subscription preference to receive one email per one post.
      2. As an admin/teacher, post into the forum, while having checked "Send forum post notifications with no editing-time delay". R
      3. Reply to that post, again with the checkbox checked.
      4. Run cron
      5. Check the subscribed user's inbox
      6. TEST: The forum post notification email should have two emails. Their SMTP header Message-ID must have a value like <some-long-SHA1-hash@wwwroot> and not like <some-short-MD5-hash@hostname>.
      7. TEST: The reply should ideally be displayed as an email reply, but this may be depend on your client settings.
      Show
      To test this, you need outgoing emailing working. You may find $CFG->divertallemailsto useful. As a user, subscribe into a forum, using the default forum subscription preference to receive one email per one post. As an admin/teacher, post into the forum, while having checked "Send forum post notifications with no editing-time delay". R Reply to that post, again with the checkbox checked. Run cron Check the subscribed user's inbox TEST: The forum post notification email should have two emails. Their SMTP header Message-ID must have a value like <some-long-SHA1-hash@wwwroot> and not like <some-short-MD5-hash@hostname> . TEST: The reply should ideally be displayed as an email reply, but this may be depend on your client settings.
    • Difficulty:
      Moderate
    • Affected Branches:
      MOODLE_32_STABLE
    • Fixed Branches:
      MOODLE_32_STABLE
    • Pull from Repository:
    • Pull 3.2 Branch:
      MDL-57474-32-messageid
    • Pull Master Branch:
      MDL-57474-master-messageid

      Description

      Hi,

      I detected this because, since some days ago, my email client (Thunderbird) that strongly relies on the "Message-ID" and their counterparts ("In-Reply-To" & "References") are not matching anymore, so I'm getting here all the forum messages without proper threading.

      Looking to old mails, they were coming with these type of "Message-ID" headers:

      <e1e0ae7cfa4b8e8d003b9e34b793b88f5a76706c4c193b0891aca1b2cc89b625@moodle.org>
      (that are the usual ones, calculated by us in moodle, see generate_email_messageid())

      But, since some days ago, those "Message-ID" headers look like:

      <56bf7dccec6b7e666ea933e354721f73@education-primary.srv.in.moodle.com>

      (completely different from the ones generated by Moodle and obviously, "In-Reply-To" & "References" - also generated by us - do not match anymore).

      I've been looking for code changes but have found nothing justifyng that change. So I think this is something related with some moodle.org configuration change (within moodle, or php.ini mail setting, or mail server itself, or gmail...). But it seems clear that now our (moodle-generated) headers are not being sent anymore, but replaced by another one, completely different.

      MDL-56000 has been identified as a potential change affecting this.

      So matching does not happen anymore and threads are destroyed for some email clients.

      Ciao

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

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

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Fix Release Date:
                    9/Jan/17