Hello,
I’m trying to modify the login during the provisioning process through the web interface, so that the supervisor doesn’t have to enter the login manually.
Example
User creation:
First name: Pierre
Last name: Castel
Email: pcastel@domain.com
Currently, the login generated is Pierre.Castel, but I would like it to be pcastel.
How can I achieve this?
You can apply the login creation logic from the synchronization of your authorized source into the transformation script directly, or modify the script /provision/primary/primaryPrincipal.groovy
The implementor of this class should override the provided methods.
The default implmeentation is in the AbstractPrincipalGenerator, which should be
enough for most use-cases.
However, we provide the ability to override the use-case functionality with something more custom.
*/
class UserPrincipal extends AbstractUserPrincipalGenerator {
Please replace the out-of-the-box script with the one that is attached to this post.
This script automatically generates unique login names for new users. It creates logins in “firstInitialLastName” format (like “pcastel” for Pierre Castel), checks if that login already exists and if there’s a conflict, it automatically tries numbered variations (pcastel1, pcastel2, etc.) until it finds an available username.
Thank you very much for the code. I’m a student working in a company, and I’ve been assigned to handle the deployment of OpenIAM on my own. I must admit I’m struggling a bit.
How did you find which functions, classes, and attributes to call (for example, StringOperationalConnectorValue, etc.)? I saw that there used to be a way to add an OpenIAM package to Eclipse, but it seems it’s no longer available — or at least I can’t manage to find it.