Bulk update the user authentication type to external
search cancel

Bulk update the user authentication type to external

book

Article ID: 220235

calendar_today

Updated On:

Products

CA Performance Management - Usage and Administration DX NetOps

Issue/Introduction

We are planning to implement the LDAP in our current production which has around 450+ active users. 

So in order to retain there current level of access post LDAP implementation.  As far i know is to change the authentication from "Dxnetops" to "external" for the users.

Am looking for way to update the in Bulk.

 

Environment

Dx NetOps Performance Management 20.2

Resolution

1. First, you must get a list of all names: http://CAPC_HOST:8181/pc/center/webservice/users/en-US
- you will have to parse out the name between the <name> ...</name> tags
- Important:  exclude the 'admin' and 'user' user from this
2. You would need to write a script to change the authentication type to external
- Here is the endpoint: http://CAPC_HOST:8181/pc/center/webservice/users/userName/<username>/authenticationType/<authentication type> 

Example: 
curl -v -u 'admin:admin' -X PUT http://CAPC_HOST:8181/pc/center/webservice/users/userName/joer/authenticationType/EXTERNAL 

- admin:admin would be your admin username / password for CAPC
- This changes user joer to and authentication type of EXTERNAL

You will notice the password for the user is blank.  This is normal

We will check the user password against LDAP, and then pass the username and blank password to check user_definitions.  We never store ldap password in PC DB.