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

The user_login_failed event "reason" is ambiguous

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • 3.2.6, 3.3.3
    • 2.7.10, 3.2.5, 3.3, 3.4
    • Logging
    • MOODLE_27_STABLE, MOODLE_32_STABLE, MOODLE_33_STABLE, MOODLE_34_STABLE
    • MOODLE_32_STABLE, MOODLE_33_STABLE
    • master-MDL-51892
    • Hide
      1. Generate bad login attempts by entering wrong password/username
      2. Login as admin
      3. go to Site administration->Reports->Logs
      4. Change "All activities" to "Site errors" and click on "Get these logs"
      5. Failed logins should have meaningful  description, not only error ID
      Show
      Generate bad login attempts by entering wrong password/username Login as admin go to Site administration->Reports->Logs Change "All activities" to "Site errors" and click on "Get these logs" Failed logins should have meaningful  description, not only error ID

    Description

      When reviewing the site logs, the description for the "User login failed" event is "Login failed for the username 'bob' for the reason with id '3'."

      "Reason id '3'" doesn't mean anything to an administrator viewing the logs. To find out what '3' refers to requires looking at lib/authlib.php and deciphering the constants.

      The event description should instead show a proper description of the error, eg "Login failed for the username 'bob' with status:

      {user doesn't exist | user is suspended | ...}

      " etc

      Component report 2015-10-23 11-47-12.png

      /report/log/user.php?id=123&course=1&mode=all

      Attachments

        1. Component report 2015-10-23 11-47-12.png
          16 kB
          Chris Wharton
        2. scrshot.png
          32 kB
          Grzegorz Ziółek

        Issue Links

          Activity

            People

              grzesiek Grzegorz Ziółek
              chrisw Chris Wharton
              Ankit Agarwal Ankit Agarwal
              Andrew Lyons Andrew Lyons
              Mihail Geshoski Mihail Geshoski
              Votes:
              5 Vote for this issue
              Watchers:
              10 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                13/Nov/17