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

User signup fails if city name is over 20 characters long

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.6.3, 1.7
    • Fix Version/s: 1.7.1, 1.8
    • Component/s: Authentication
    • Labels:
      None
    • Environment:
      Any
    • Database:
      Any
    • Affected Branches:
      MOODLE_16_STABLE, MOODLE_17_STABLE
    • Fixed Branches:
      MOODLE_17_STABLE, MOODLE_18_STABLE

      Description

      Currently .../login/signup_form.html specifies a length of 25 chars for the city field, but the database schema only has 20 characters for the city name. In addition to that, there is currently no check in the signup code to trim fields to their maximum database lenghts. We should be using truncate_userinfo() on the $user object before doing anything else with it.

      Tha attached patches fix the issue in 1.6.3+, 1.7+ and HEAD.

      Saludos. Iñaki.

        Attachments

        1. 163+.diff
          0.5 kB
        2. 17+.diff
          0.5 kB
        3. head.diff
          0.5 kB

          Activity

            People

            Assignee:
            lazyfish Yu Zhang
            Reporter:
            iarenaza Iñaki Arenaza
            Tester:
            Nobody
            Participants:
            Component watchers:
            Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias, Sujith Haridasan
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Fix Release Date:
              17/Jan/07