CPM scanner - How do I resync the API credfile for the CPM Scanner service?
Question
How do I resync the API credfile for the CPM Scanner Service for On Prem Self Hosted?
Environment
10.10;11.1;11;11.2;11.3;11.4;11.5;11.6;11.7;12.0;12.1;12.2;11.9;11.8;14.0;14.2 Privileged Access Manager (PAM, self-hosted) Central Policy Manager (CPM)
Answer
The executable 'apikeymanager.exe' is used to manage the credential file that is needed for the CPM Scanner service.
Do the following:
Note: https://AddressOfThePVWAl/passwordvault/api/ has to use hostname instead of IP
1. log into the CPM machine and open the services console
2. Stop the CyberArk Password Manager service and CyberArk Central Policy Manager Scanner services
3. Open an administrative level command prompt
4. Browse to <drive>:\Program Files (x86)\CyberArk\Password Manager\Vault
5. Run one of the following sets of commands:
To revoke the key and recreate it:
Note:
- The passwordmanageruser's username can be found in the credfile, user.ini, located in the same file location as apikeymanager.exe
- The username used in the apikeymanager.exe command is case-sensitive.
a. Type the following:
apikeymanager.exe revoke -t <CPMComponentUser> -u <installeruser_account> -a "https://AddressOfThePVWAl/passwordvault/api/"
b. Type the following:
apikeymanager.exe add -f apikey.ini -t <CPMComponentUser> -u <installeruser_account> -a "https://AddressOfThePVWA/passwordvault/api/"
To update the existing key pair:
apikeymanager.exe update -f apikey.ini -t <CPMComponentUser> -u <installeruser_account> -a "https://AddressOfThePVWA/passwordvault/api/"
6. Start the CPM and Scanner Services
Additional Information
Details
Q- revoke the key and then recreate
- apikeymanager revoke -t PasswordManager -u administrator -a "https://AddressOfThePVWAl/passwordvault/api/"
- apikeymanager add -f apikey.ini -t PasswordManager -u administrator -a "https://AddressOfThePVWA/passwordvault/api/"
- update the existing key pair
- apikeymanager update -f apikey.ini -t PasswordManager -u administrator -a "https://AddressOfThePVWA/passwordvault/api/"