There seems to be a bug in the interaction between user.module and drupal.module

even though at administer >> settings >> drupal I have set:

"Allow other Drupal sites to register:" to Disabled and "Authentication service:" to Disabled

the user.module still ads this text to the registration form:

Note: if you have an account with one of our affiliates (Drupal), you may login now instead of registering.

Which is (at the least) confusing for new users.

The responsible function in user.module seems to be:

function user_auth_help_links() {
  $links = array();
  foreach (module_list() as $module) {
    if (module_hook($module, 'auth')) {
      $links[] = l(module_invoke($module, 'info', 'name'), "user/help#$module");
    }
  }
  return $links;
}

which thus leads to:

function drupal_auth($username, $password, $server) {
  if (variable_get('drupal_authentication_service', 0)) {
    $result = xmlrpc("http://$server/xmlrpc.php", 'drupal.login', $username, $password);
    if ($result === FALSE) {
      drupal_set_message(t('Error %code : %message', array('%code' => theme('placeholder', xmlrpc_errno()), '%message' =>  theme('placeholder', xmlrpc_error_msg()))), 'error');
    }
    else {
      return $result;
    }
  }
}

Maybe the problem is just that $result is not initialized? I confirmed in my database that drupal_authentication_service has the value s:1:"0"

Comments

pwolanin’s picture

Just looked up module_hook. So the problem is really that user.module ony checks that an auth hook exists, not whether it is active!

magico’s picture

Version: 4.7.2 » x.y.z
Status: Active » Fixed

Fixed

Anonymous’s picture

Status: Fixed » Closed (fixed)