aad-sso-wordpress icon indicating copy to clipboard operation
aad-sso-wordpress copied to clipboard

Auto-Provision Usernames as Alias, Rather than Email Address

Open mrjarbenne opened this issue 5 years ago • 1 comments

Currently users who are created via this plugin end up with a username format matching their email address. Prior to activating this plugin, our user sync through SAML created users based on their alias, so a user with the email address [email protected] was assigned the WP username bob. Under the new logic, Bob's username is [email protected]. Because we are authenticating to a BuddyPress social network, this username format makes @mentioning cumbersome.

The plugin is accounting for existing alias usernames like "bob" to be matched to Azure profiles like [email protected], but new users are being created with their email address as the username. If I manually change the username from [email protected] to bob, the plugin still recognizes this is the same user on subsequent authentications, but it would be awesome if there was a snippet I could add, or a toggle in the settings I'm not fully understanding, to switch this logic to auto-provision users with the alias as their username.

mrjarbenne avatar Oct 01 '19 01:10 mrjarbenne

@mrjarbenne Thanks for this great feedback. This is definitely something we can consider for a future release.

psignoret avatar Oct 02 '19 22:10 psignoret