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

Security keys page: 'valid until' information is not matching the user language

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.2.1, 2.2.9, 2.3.6, 2.4.3, 2.5
    • Fix Version/s: 2.3.7, 2.4.4
    • Component/s: Web Services
    • Labels:
    • Testing Instructions:
      Hide

      To do this test you'll need to create a token with a valid until date for a manager.

      Go to Admin > Plugins > Web service > Manage token
      Check that a token with a "Valid until" date has the correct date displayed in the correct user language.

      Connect as Manager
      Go to Edit profile > My security keys
      Check that a token with a "Valid until" date has the correct date displayed in the correct user language.

      Show
      To do this test you'll need to create a token with a valid until date for a manager. Go to Admin > Plugins > Web service > Manage token Check that a token with a "Valid until" date has the correct date displayed in the correct user language. Connect as Manager Go to Edit profile > My security keys Check that a token with a "Valid until" date has the correct date displayed in the correct user language.
    • Affected Branches:
      MOODLE_22_STABLE, MOODLE_23_STABLE, MOODLE_24_STABLE, MOODLE_25_STABLE
    • Fixed Branches:
      MOODLE_23_STABLE, MOODLE_24_STABLE
    • Pull Master Branch:
      MDL-31193-master

      Description

      webservice/renderer.php: user_webservice_tokens_box()

      Fix the following TODO:

      if (!empty($token->validuntil)) {
          $validuntil = date("F j, Y"); //TODO: language support (look for moodle function)
      }

      To see the 'valid until' information on your security keys page: you need to be a non admin user who has a token. The admin need to have set you up as an authorised user, and to have also set you up a 'valid until'.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

              Hide
              poltawski Dan Poltawski added a comment -

              heh, we weren't even using the date at all before?!

              Show
              poltawski Dan Poltawski added a comment - heh, we weren't even using the date at all before?!
              Hide
              poltawski Dan Poltawski added a comment -

              Hi Jerome,

              Looks OK to me - only thing is that you could avoid the core_ prefix in the lange strings and just use langconfig (I think thats more conventional in moodle atm).

              cheers,
              dan

              Show
              poltawski Dan Poltawski added a comment - Hi Jerome, Looks OK to me - only thing is that you could avoid the core_ prefix in the lange strings and just use langconfig (I think thats more conventional in moodle atm). cheers, dan
              Hide
              jerome Jérôme Mouneyrac added a comment -

              Done

              Show
              jerome Jérôme Mouneyrac added a comment - Done
              Hide
              damyon Damyon Wiese added a comment -

              wrong date in the wrong language!

              Show
              damyon Damyon Wiese added a comment - wrong date in the wrong language!
              Hide
              damyon Damyon Wiese added a comment -

              Thanks Jerome,

              This is not a security issue so has not been applied to 22.

              Integrated to 23, 24 and master.

              Show
              damyon Damyon Wiese added a comment - Thanks Jerome, This is not a security issue so has not been applied to 22. Integrated to 23, 24 and master.
              Hide
              andyjdavis Andrew Davis added a comment -

              After some initial confusion this appears to be working. Passing.

              Show
              andyjdavis Andrew Davis added a comment - After some initial confusion this appears to be working. Passing.
              Hide
              stronk7 Eloy Lafuente (stronk7) added a comment -

              Did you think this day was not going to arrive ever?

              Your patience has been rewarded, yay, sent upstream, thanks!

              Closing...ciao

              Show
              stronk7 Eloy Lafuente (stronk7) added a comment - Did you think this day was not going to arrive ever? Your patience has been rewarded, yay, sent upstream, thanks! Closing...ciao

                People

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

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Fix Release Date:
                    13/May/13