Problem/Motivation

Our client has a requirement to allow users with specific email domains to be able to login with local accounts.

Proposed resolution

Add a configuration option for allowing specific email domains to login with local accounts, similar to the existing allow_default_login_roles and allow_default_login_users options. Patch coming soon.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

malik.kotob created an issue. See original summary.

malik.kotob’s picture

Here's a patch that has been tested and behaves the same way as the allow_default_login_users config option.

malik.kotob’s picture

Status: Active » Needs review
dakku’s picture

@malik.kotob I think thats a really useful addition. I would be keen to get this included, Can you re-roll the patch against the latest dev version?

joelpittet’s picture

As a suggestion it may be good to either log and/or notify the user about the email domain?

mstrelan’s picture

On the flipside, I have the opposite requirement. I need to prevent users with a particular domain from logging in with a local account, since they should exist in the IdP. I wonder if that could be combined with this?

drupalevangelist’s picture

Will this patch be a part of an upcoming release?