In an LDAP read only environment, we don't want to let the user request a new password, change email address or change password. all three of these are handled by existing procedures & applications. there's a variable 'user_request_password' which removes the link in the login block, and two permissions 'change own email' and 'change own password'

attached is a unified diff patch to 4.7.0

CommentFileSizeAuthor
#2 user.patch_2.txt2.15 KBcorris
user.patch_1.txt2.15 KBcorris

Comments

killes@www.drop.org’s picture

Version: 4.7.0 » x.y.z
Status: Reviewed & tested by the community » Needs work

No new features will be added to 4.7.

Your patch does nor comply with our coding standards.

corris’s picture

Status: Needs work » Needs review
StatusFileSize
new2.15 KB

oh, yea, should have been cvs, sorry.

was it the indentation? how's this one?

Tobias Maier’s picture

have a look at http://drupal.org/node/53103
I think this would be userful for your purpose

dries’s picture

Status: Needs review » Needs work

Coding style needs work; incorrect use of spaces. Also, we write 'e-mail' not 'email'. All minor changes. ;)

Now, with Drupal 4.7.0, an LDAP authentication module might actually be able to modify the user.module's generated forms. Maybe that's a better solution? Worth exploring? It wouldn't require fiddling with permissions when the LDAP authentication module is enabled.

dries’s picture

Cross-posted an issue at http://drupal.org/node/65159. Let's see what the LDAP integration module maintainers think/need.

dries’s picture

Bèr Kessels’s picture

Version: x.y.z » 6.x-dev

One big problem with implementing http://drupal.org/node/65159 cleanly is that Drupal has hardcoded the requirement of an emailaddress.

user_validate_mail($mail) is called, instead of the default Form Api validation. We would need to implement a better way in core first, then LDAP auth can simply override the forms with form_alter. Right now we cannot simply unset a form, because of this harcoded requirement of an email address.

pancho’s picture

Version: 6.x-dev » 7.x-dev

New features go to the D7 branch.

Jaza’s picture

Version: 7.x-dev » 8.x-dev
Status: Needs work » Closed (fixed)

Surely this can be achieved by form_alter'ing the 'email' and 'password' fields to be 'value' or 'hidden' types?

Closing.