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

Mnet - link to mnet_email.php shows when it shouldn't

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • 1.9.8, 2.0
    • 1.9.7
    • Authentication, MNet
    • None
    • MOODLE_19_STABLE
    • MOODLE_19_STABLE, MOODLE_20_STABLE

    Description

      when Mnet is enabled, if a user gets their password wrong on the login screen a link to Mnet_email is always shown even when SSO to Moodle isn't configured - if a site is only configured to allow their users to SSO to other sites - not the other way round, Moodle shouldn't show the link as it's useless - here's a patch that fixes it:

      — a/login/index.php
      +++ b/login/index.php
      @@ -238,7 +238,8 @@ httpsrequired();
      // TODO: if the user failed to authenticate, check if the username
      if ( !empty($CFG->mnet_dispatcher_mode)
      && $CFG->mnet_dispatcher_mode === 'strict'

      • && is_enabled_auth('mnet'))
        Unknown macro: {+ && is_enabled_auth('mnet') &&+ record_exists('mnet_host2service', 'publish', '1', 'serviceid', get_field('mnet_service', 'id', 'name', 'sso_sp')) ) { $errormsg .= get_string('loginlinkmnetuser', 'mnet', "mnet_email.php?u=$frm->username"); } }

      Attachments

        Issue Links

          Activity

            People

              mjollnir Penny Leach
              danmarsden Dan Marsden
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                25/Mar/10