Unique Sequential ID Creation in Create Account Policy

Hello Experts,

We have a requirement where we need to generate a unique sequential uidnumber during account creation.

This is an IBM Tivoli DS connector which follows LDAP. We thought of implementing this using the Create Unique LDAP Attribute / username generator transform but it is designed for username and has no native awareness of the current maximum uidnumber.

The recommended approach would be to query the LDAP server during account creation, retireve the current maximum uidnumber, increment it, and use the incremented value for provisioning the new account. What would be the best way to implement this and is this approach supported/recommended in ISC? Limitation around concurrency is not an issue as the source account is created on request basis.

Hi @shyam_sreevalsan ,
Welcome Back to Community.

For this case you can use BeforeProvisioning Rule to achieve above use case. Utilise IdnRuleUtil for checking the new value exists in the application or not.

Thank you.

Hi @suraj_gorle Could you please provide more detail on your proposal? AFAIK this is not a simple use case.

Hi @j_place ,

The idea is to use a BeforeProvisioning Rule to check for the current maximum uidNumber exists in source, increment it, and inject the new value into the provisioning plan during account creation.

IdnRuleUtil can additionally be used for uniqueness validation. Since the provisioning is request-based, concurrency should not be a major concern in this case. Let us know if you have better approach to handle this use case.

Thank you.

Thanks @suraj_gorle How exactly can you find the maximum UID number using idnRuleUtil?

Hi @j_place ,

You are correct — IdnRuleUtil itself cannot retrieve the maximum uidNumber directly.

My intention was that the actual max uidNumber lookup would need to be performed through an LDAP query (or connector-supported search) inside the BeforeProvisioning Rule logic, while IdnRuleUtil could still be used separately for uniqueness validation/checks if needed.

So the sequence generation logic would primarily rely on the LDAP lookup rather than IdnRuleUtil alone.

Thank you for pointing that out.

Thank you, @suraj_gorle

Do you know which classes can be utilised or how I can lookup the max uidnumber through an LDAP query within the BeforeProvisioning rule?

Ah, you pre-empted my next question :wink:

As I said above, this is not a simple use case and there are a number of posts on this subject in the forum.

Hi @shyam_sreevalsan Let me know if you are pulling the uidNumber into the ISC application schema. If you are aggregating the uidNumber data into the application, and if you are not aggregating the uidNumber, please add the attribute into the schema and aggregate the data. You have the data and you can simply write the account transform by incrementing 1, which is provided by the ISC uniqueCounter.

Thanks,

PVR.

Hi @Peddapolu Could you please provide more detail on your proposal? AFAIK this is not a simple use case.

I believe your uid number is just a number not a pattern (using user details)

There is no method available to run a LDAP query using IDN Rule Util, please check documentation once again

Transform is only meant for generating uniqueness based on user attributes

The challenge here is finding the maximum uid number, there are no OOTB methods available for this AFAIK, would love to know if any

At the moment, I propose

  • Go with Before Provisioning Rule
  • You can make use of SailPoint API calls
  • Use /accounts API by passing your source as filter to get all the available accounts, get UID attribute alone, pass it to a list, find the max number

Hi @KRM7 It’s my understanding you cant make API calls in a Cloud Rule. However, even if you could, how would you find the max number?

SailPoint doc doesn’t say that you should not make API calls

I haven’t come across any use case to make API calls, but I have read in community other developers implemented, however we can get confirmation on this.

Get all accounts, get uid of all accounts, feed them to a list, find the max number using Collections

HI @KRM7 I’ve heard people have had success using API to write back the last used to an application attribute, but via a connector rule (AD).

Thing is with Cloud Rules, would SP authorise a Rule to retrieve what could be thousands of objects? Also, what about paging? I think it could get messy.

Also using Collections on what could be a large array, could be intensive.

Hi @j_place Here is my proposal: Since LDAP has the UIDNumber, we will aggregate the UIDNumber at the application level. Once we get the UIDNumber at the application level, we have the control to write the transform. From there, we can increase it by 1. That would be a simple solution I would recommend instead of hard-pulling every time during the account request. What would you say @j_place ?

Thanks @Peddapolu How would you determine the highest (latest) UID?

Hi @j_place we can determine using the “type”: “lookup” and accountPropertyFilter transfrom.

Thanks,

PVR.

Thanks @Peddapolu

Say you’ve got 10,000 accounts on your source. These are aggregated into ISC (including the UID attribute). You would need to find the highest of the 10,000 UID values to then increment. I’m not aware of any Transform functionality that can do that for you. Obviously, I would be happy to be corrected, so if you could give just a bit more detail on your solution, that would be appreciated.

Yes it is, I don’t see any other way.

There is no such thing, this filter is in Account Attribute Transform that can be applied on current Identity account

Hi @KRM7 @j_place ,we did this senarion can you check and confirm ,In the Active Directory source’s account create provisioning policy, the sAMAccountName
attribute will be calculated using the Create Unique LDAP Attribute generator with
the pattern $(samValue)$(uniqueCounter)

Thanks,

PVR.