Users who authenticated using the simplesamlphp_auth module are not able to change their e-mail addresses because Drupal 7 requires that they enter their current password in order to change their e-mail. Of course they don't know their Drupal password because they never set it. For these users (people with an authmap entry) the password fields should be removed from the User edit form. The requirement to provide a password when changing e-mail should also be removed for these users.

Consider this patch for the CAS module http://drupal.org/files/issues/1011876-Remove-requirement-to-validate-cu... as an example of how to do this.

Comments

haggster’s picture

Make a custom module and add this code:

function mymodule_form_alter(&$form, $form_state) {
unset($form['account']['current_pass']);
unset($form['account']['current_pass_required_values']);
$form['#validate'] = array_diff($form['#validate'], array('user_validate_current_pass'));
}

Works for me!

geekwisdom’s picture

I would also be good if administrators had the option of allowing SAML users to set a password in order to log in with their local Drupal account. This would allow SAML users to log in either way (SAML or local account).

geekwisdom’s picture

Status: Active » Fixed

User's with a simplesamlphp_auth authmap record are no longer required to know their password to change their Drupal e-mail address. Also, there is a new configuration setting to control whether these users are permitted to set a password for their local Drupal account. If they are permitted to do this, and the configuration allows them to log in with a local Drupal account, then they will have the option of logging in with SimpleSAMLphp or the local account. This change is in the 7.x-2.x development branch. See: http://drupalcode.org/project/simplesamlphp_auth.git/commit/3d2516a76b49...

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.