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

Password reset email doesn't fill in $a->link when auth_method is LDAP

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide
      Prerequisites
      1. Outgoing email setup (e.g. using Mailcatcher, etc.)
      Setup
      1. Log in as admin
      2. Go to "Site administration / Plugins / Authentication / Manage authentication"
      3. Enable "LDAP server"
      4. Click on the "Settings" link for the "LDAP server" authentication method.
      5. Set the "Password-change URL" ("auth_ldap | changepasswordurl") to "https://example.com/wherever.php?a=1&b=2"
      6. Save the changes.
      7. Go to "Site administration / Users / Accounts / Browse list of users"
      8. Edit a user's profile (let's call this user1).
      9. Change user1's authentication method to "LDAP server".
      10. Save the changes then log out
      Test
      1. Go to the login page.
      2. Click the "Forgotten your username or password?" link.
      3. Enter user1's username, then press "Search"
      4. Check the password reset email.
      5. Confirm that email contains the URL corresponding to the "Password-change URL" setting ("https://example.com/wherever.php?a=1&b=2").
      Show
      Prerequisites Outgoing email setup (e.g. using Mailcatcher, etc.) Setup Log in as admin Go to " Site administration / Plugins / Authentication / Manage authentication " Enable " LDAP server " Click on the " Settings " link for the " LDAP server " authentication method. Set the " Password-change URL " (" auth_ldap | changepasswordurl ") to " https://example.com/wherever.php?a=1&b=2 " Save the changes. Go to " Site administration / Users / Accounts / Browse list of users " Edit a user's profile (let's call this user1). Change user1's authentication method to " LDAP server ". Save the changes then log out Test Go to the login page. Click the " Forgotten your username or password? " link. Enter user1's username, then press " Search " Check the password reset email. Confirm that email contains the URL corresponding to the " Password-change URL " setting (" https://example.com/wherever.php?a=1&b=2 ").
    • Affected Branches:
      MOODLE_37_STABLE
    • Fixed Branches:
      MOODLE_37_STABLE, MOODLE_38_STABLE
    • Pull 3.7 Branch:
    • Pull 3.8 Branch:
    • Pull Master Branch:
      MDL-66581-master

      Description

      When a LDAP user tries to reset the password from /login/forgot_password.php the mail he/she receives have all the parameters filled except the reset link:

      Hi Iñigo,

      Someone (probably you) has requested a new password for your
      account 'izendegi' on 'MoodleSite'.

      To change your password, please go to the following web address:

      {$a->link}

      In most mail programs (...)

      It may be a regression from MDL-59298:

      https://github.com/moodle/moodle/commit/206ec32890b47e7ad6eae860663e861495f145ba#diff-d46e32d459d55f2123253fbc22108fc7

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              izendegi Iñigo Zendegi
              Reporter:
              izendegi Iñigo Zendegi
              Peer reviewer:
              Jun Pataleta
              Integrator:
              Jake Dallimore
              Tester:
              Janelle Barcega
              Participants:
              Component watchers:
              Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias
              Votes:
              4 Vote for this issue
              Watchers:
              8 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                13/Jan/20

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 3 hours, 33 minutes
                  3h 33m