Account unlocking using CURL
- Install CURL on your local computer using this link (https://curl.haxx.se/)
- This step is applicable when operating in a clustered environment; otherwise,
skip this step.
You must ascertain which node the user is blocked; follow the steps listed below:
- Obtain
amlbcookiefrom blocked-user (amlbcookiedetermines which OpenAM node is being used by the user), to do this, inspect the Request headers send by the client browser. Note thatamlbcookieis sent in the cookie header. - As an OpenAM administrator, follow the instructions in the list below to
determine which node is using
amlbcookie:- Login to OpenAM as an OpenAM administrator (username: amadmin
and password entered in
deploy.properties/security.admin.passwordduring installation of security bundle). From the menubar select deployment/servers, here you will find a server listing. - You now need to establish which server the user has been
locked-out. To do this, on each server, check its
amlbcookie(after clicking on the server choose Advanced and check value of the propertycom.iplanet.am.lbcookie.value). The propertycom.iplanet.am.lbcookie.valueshould be the same asamlbcookie. - By following the instructions in the points above, you can determine which OpenAM server address and port to be used in step 4 below.
NOTE: The process listed in this step may be time-consuming, and in certain scenarios, it may be advisable to wait for the lockout time period determined in the
deploy.propertiesfile instead of carrying out this step. - Login to OpenAM as an OpenAM administrator (username: amadmin
and password entered in
- Obtain
- Obtain session token for OpenAM administrator, as follows:
curl -X POST -H "X-OpenAM-Username: amadmin" -H "X-OpenAM-Password: <OPENAM ADMIN PASSWORD>" -H "Content-Type: application/json" <ADDRESS>:<OPENAM PORT>/OpenAM/json/authenticate - Use the session token obtained from the previous step to clear login attempts
data, as
follows:
curl -X PUT -H "iPlanetDirectoryPro: <SESSION TOKEN>" -H "Content-type: application/json" -d "{ \"sunAMAuthInvalidAttemptsData\":[] }" <ADDRESS>:<OPENAM PORT>/OpenAM/json/EngageOne/users/<LOCKED ACCOUNT NAME>
Important:
<OPENAM ADMIN PASSWORD> is the password specified in
deploy.properties/ security.admin.password