ForgeRock cloud how to achieve attribute uniqueness in identities

I am using ForgeRock cloud and want to make email id as unique attribute for identities. No identity should be created with similar email id which is already existing in identity store. How to achieve this?

Hi,

I think you can use the existing policies valid-username and valid-email-address-format for the email address attribute in the managed objects.

https://backstage.forgerock.com/docs/idcloud/latest/idm-objects/configuring-default-policy.html#policy-reference

Regards,
KK

2 Likes

Hi,

You can enable uniqueness for any attribute using validation policies in IDM (unique) which is OOTB. Use IDM native console and navigate to mail attribute by following below steps.

  1. Platform UI → Native Consoles → Identity Management
  2. Go to Configure → Managed Objects → Choose your user object (where mail attribute is present - alpha_user OOTB).
  3. Click on the mail attribute and then click on Validation. Now add unique policy to the mail attribute.

Test by creating a user with same email id which already exists.

Refer ForgeRock Documentation for OOTB validation policies: Apply policies to managed objects :: ForgeRock Identity Cloud Docs

You can also write your own validation policy and import.

1 Like

Hi @sandeep.dommari , thanks for your reply.
If I am adding unique policy in validation it resolves my problem while creating identities and no identity is created with similar email id.
But then when I try to login into the journey it does not allow me to login and every time I get message that mail should be unique even if only this single mail exists in the repository.

Please let me know how to resolve this issue.