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

New users created at login using LDAP don't have their country set to site default

    XMLWordPrintable

Details

    • MOODLE_311_STABLE, MOODLE_400_STABLE
    • MOODLE_311_STABLE
    • MDL-72634-311
    • Hide

      Start LDAP Server

      $ docker run --rm --env LDAP_USERS=user01 --env LDAP_PASSWORDS=user01 -p 1389:1389 bitnami/openldap
      

      Configure Moodle

      1. Log in as admin
      2. Navigate to General > Location > Location settings in site administration
      3. Set the following values:
        • Default city: Nadi
        • Default country: Fiji
      4. Save changes
      5. Navigate to Plugins > Authentication > Manage authentication in site administration
      6. Ensure Prevent account creation when authenticating is not enabled
      7. Enable LDAP server
      8. Press Settings to configure LDAP server
      9. Set the following values:
        • Host URL: ldap://localhost:1389 (or the IP address of the Docker container if not localhost)
        • Distinguished name: cn=admin,dc=example,dc=org
        • Password (Password for bind-user): adminpassword
        • Contexts: ou=users,dc=example,dc=org
      10. Save changes
      11. Use Test settings from the Manage authentication page to confirm connection succeeds
      12. Log out

      Test New User

      1. Log in as user01:user01 (our new LDAP user)
      2. When prompted to edit new profile:
        • Confirm the City/town field contains "Nadi"
        • Confirm the Select a country field contains "Fiji"
      Show
      Start LDAP Server $ docker run --rm --env LDAP_USERS=user01 --env LDAP_PASSWORDS=user01 -p 1389:1389 bitnami/openldap Configure Moodle Log in as admin Navigate to General > Location > Location settings in site administration Set the following values: Default city: Nadi Default country: Fiji Save changes Navigate to Plugins > Authentication > Manage authentication in site administration Ensure Prevent account creation when authenticating is not enabled Enable LDAP server Press Settings to configure LDAP server Set the following values: Host URL: ldap://localhost:1389 (or the IP address of the Docker container if not localhost) Distinguished name: cn=admin,dc=example,dc=org Password (Password for bind-user): adminpassword Contexts: ou=users,dc=example,dc=org Save changes Use Test settings from the Manage authentication page to confirm connection succeeds Log out Test New User Log in as user01:user01 (our new LDAP user) When prompted to edit new profile: Confirm the City/town field contains "Nadi" Confirm the Select a country field contains "Fiji"

    Description

      As a site admin:

      1. I set the default country for new user accounts to "United Kingdom"
      2. I disable "Prevent account creation when authenticating"

      As a new user registering with my LDAP account:

      1. I login for the first time
      2. My account is created
      3. But the country field is empty (not what site admin set as default for new accounts) until I manually update my profile

      Attachments

        Activity

          People

            pholden Paul Holden
            pholden Paul Holden
            Carlos Escobedo Carlos Escobedo
            Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
            Gladys Basiana Gladys Basiana
            David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo, David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              9/May/22

              Time Tracking

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