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

Incorrect redirection after password change

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.0.4, 3.1
    • Fix Version/s: 3.0.5, 3.1.1
    • Component/s: Authentication
    • Labels:
    • Testing Instructions:
      Hide
      • As an admin, create a new user in the interface
      • Enter a temporary password and check the option "Force password change"
      • Enter the other required field and click on the "Create user" button
      • As the new user, directly go to the login page (write it manually in a new browser, click on it or from a bookmark) and login with the temporary password
      • Change your password as requested
      • You should see a page who confirm the page. Click on the "Continue" button
      • You should be redirected on the default redirection after login page
      • Go the user preference page (from the user menu)
      • Click on "change password"
      • Change your password
      • You should see a page who confirm the page. Click on the "Continue" button
      • You should be redirected on the user preference page

      You can also run the following behat tests :

      cd path/to/your/moodle
      php admin/tool/behat/cli/util.php --enable
      vendor/bin/behat --config path/to/your/behatdata/behat/behat.yml $(pwd)/login/tests/behat/change_password.feature
      

      Show
      As an admin, create a new user in the interface Enter a temporary password and check the option "Force password change" Enter the other required field and click on the "Create user" button As the new user, directly go to the login page (write it manually in a new browser, click on it or from a bookmark) and login with the temporary password Change your password as requested You should see a page who confirm the page. Click on the "Continue" button You should be redirected on the default redirection after login page Go the user preference page (from the user menu) Click on "change password" Change your password You should see a page who confirm the page. Click on the "Continue" button You should be redirected on the user preference page You can also run the following behat tests : cd path/to/your/moodle php admin/tool/behat/cli/util.php --enable vendor/bin/behat --config path/to/your/behatdata/behat/behat.yml $(pwd)/login/tests/behat/change_password.feature
    • Affected Branches:
      MOODLE_30_STABLE, MOODLE_31_STABLE
    • Fixed Branches:
      MOODLE_30_STABLE, MOODLE_31_STABLE
    • Pull Master Branch:
      MDL-54755_master

      Description

      The redirection page after the password change from an email or from a new session is incorrect.
      This will work correctly if there is a referer (see get_local_referer in index.php page).

      To reproduce :

      • As an admin, create a new user in the interface
      • Enter a temporary password and check the option "Force password change"
      • Enter the other required field and click on the "Create user" button
      • As the new user, directly go to the login page (write it manually in a new browser, click on it or from a bookmark) and login with the temporary password
      • Change your password as requested
      • You should see a page who confirm the page. Click on the "Continue" button
      • EXPECTED : To be redirected on the default redirection after login page
      • ACTUAL : Redirected in my dashboard > Preferences

      After checking in the code, it seems the default behavior is to return to the user preferences page.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Fix Release Date:
                11/Jul/16