My requirement is domain based user login, consider a scenario where user has the email id (PII Removed by Staff) then he would be able to login my site(global-pay-dp) and if another user having email id (PII Removed by Staff) then he would not be able to login because he does not belong to our organization.
I know we can create Rules and in Condition, we have Data to compare, option but it contains only two operations: Equal and is one of .
and we cannot give email as a Data selector Value, because we just want to compare the domain not entire email id.
It sounds like you are wanting to restrict user registration based on email domain name. So a user would be able to create an account with an @globalpay.com domain, but not with an @gmail.com domain. I have not tested this, but this module seems to handle this use case exactly: https://www.drupal.org/project/domain_registration
Once an account is created for a user, they will be able to login normally.
User | Count |
---|---|
7 | |
2 | |
2 | |
2 | |
1 |