Share all details related to your problem, including any error messages you may have received.
Hi,
We have a requirement to remove detected roles from SailPoint for approx.400 users. Can you please help how can i achieve this as this is on priority. Please provide the complete walkthrough of how we can achieve this in our project.
As @ipobeidi said - problem is with entitlement - not with roles in the end - the easiest way (but you need to do role by role)
Is to use bulk revoke on entitlements to remove entitlements matching to the role. In the end it is enought if at least one entitlement won’t match with the definition of IT Role and it will not be displayed on the list of detected anymore.
@ayadav_12
Detected roles are nothing but the IT roles. When you say that you had an requirement to remove detected roles from 400 users, do you want to remove only the detected flag or wan to remove the whole IT role along with underlying Entitlements (assumming IT roles have direct entitlements configured)?
Can we have the rule for role and it should remove entitlements falling under it as it appears to have close to 80 entitlements for one user related with the role. Please help
The roles that you want to remove are IT Role (Detected) and so ideally way will be to remove the entitlement and then refresh task will do the rest.
But for this also if the entitlement has some patterns like from same application or a fixed list then it is simply an extra step where you can iterate through identity links and remove only those which is assigned to identity.
Let me know if you need help with any specific case.
identify all the users who are having that IT role.
Filter f = Filter.collectionCondition("bundles", Filter.and(Filter.eq("name", "<Role name>")))
Iterator it = context.search(Identity.class, new QueryOptions().addFilter(f), "name");
// Get the name by iterating the above result
Create the provisioning plan to remove the IT role from the user.
ProvisioningPlan plan = new ProvisioningPlan();
List accReqList = new ArrayList();
// Sample plan creation for one user.
AccountRequest accRequest = new AccountRequest();
accRequest.setApplication("IIQ");
accRequest.setNativeIdentity("<add the user name>");
accRequest.setOperation(ProvisioningPlan.AccountRequest.Operation.Create);
accRequest.add(new AttributeRequest("assignedRoles", ProvisioningPlan.Operation.Remove, "<role_name>"));
//perform this for all users
accReqList.add(accReqList);
plan.setAccountRequests(accReqList);
Use the provisioner API to remove the role from the user.
Provisioner prov = new Provisioner(context);
prov.execute(plan);
Note: This will work if the IT role is not tagged to any business roles; otherwise in next refresh the IT roles will be provisioned again. It wil be better untag the IT role from the business role before running the script.