How to reset password of Organization Administrator Password of Apigee Edge

How to reset password of Organization Administrator Password of one of the admin user if we have multiple Organization Administrator in Apigee Edge.

DHCP is not setup

I have password of another Organization Administrator.

I have access to edge linux instance as well so if it is possible through shell scripts then I can do that.

@Mukundha Madhavan

Solved Solved
0 6 1,896
2 ACCEPTED SOLUTIONS

adas
Participant V

@Sandy Learnera You could use the /users UPDATE api to do this, if you have the sysadmin credentails:

PUT /v1/users/testuser@xyz.com

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<User>
    <EmailId>testuser@xyz.com</EmailId>
    <FirstName>arghya</FirstName>
    <LastName>das</LastName>
    <Password>Secret123$</Password>
</User>

This should set the new password for a user but you need to be the sysadmin, if you are to make this call. An orgadmin doesn't have the privileges to make this call.

View solution in original post

$ curl -u sysadmin@email.com:sysadminpassword  -X  POST http://managementUI_IP:8080/v1/users/resetUser@email.com  -d  '<?xml version="1.0" encoding="UTF-8" standalone="yes"?><User><Password>newPassword8Digit</Password><FirstName>ResetuserFirst</FirstName>
<LastName>resetUserLast</LastName><EmailId>resetUser@email.com</EmailId></User>'  -H    "Content-Type:application/xml"

View solution in original post

6 REPLIES 6

adas
Participant V

@Sandy Learnera You could use the /users UPDATE api to do this, if you have the sysadmin credentails:

PUT /v1/users/testuser@xyz.com

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<User>
    <EmailId>testuser@xyz.com</EmailId>
    <FirstName>arghya</FirstName>
    <LastName>das</LastName>
    <Password>Secret123$</Password>
</User>

This should set the new password for a user but you need to be the sysadmin, if you are to make this call. An orgadmin doesn't have the privileges to make this call.

There are a couple of ways you can do this. If you have Edge Management UI and email sending configured, then the orgadmin can use the "Forgot password?" link in that UI:

1219-forgotpassword.png

That will trigger an email with a reset password link to the email address of that orgadmin.

Alternatively, using your sysadmin credential, you can make an Edge Management API call to update a password:

curl -u <adminEmail>:<passwd> -X POST \ 
http://<management-ip>:8080/v1/users/{userEmail} \ 
-d '<User> 
	<Password>{newPW}</Password> 
	<FirstName>{firstName}</FirstName> 
	<LastName>{lastName}</LastName> 
	<EmailId>{userEmail}</EmailId> 
</User>' \ 
-H "Content-Type: application/xml"

where:

adminEmail is the email address of your sysadmin user,

passwd is the password of your sysadmin user,

userEmail is the email address of the orgadmin,

newPW is the new password for the orgadmin.

Note: Above API request can be used for resetting passwords of all Edge users, not just orgadmins.

This does need the sysadmin user credential, i.e. you can't reset passwords with just orgadmin access.

For more details see the section in the Apigee Edge Operations Guide under Post-Installation Tasks. If you don't have it, you can get it via the Library link after you log in to your Apigee Support Portal.

Please look into my question, I said "NO DHCP", your first answer scratches out there.

Second answer there is some syntactical mistake but I got your point. I have posted my answer which worked for me.

Thanks for pointing that out @Sandy Learnera, the sample curl I pasted was corrupted by the system trying to auto create a link out of the http:// part. I have now removed the extra <a ....> and </a> tags. I also tweaked it a bit to format the body for better readability.

Thanks. Now it looks good.

$ curl -u sysadmin@email.com:sysadminpassword  -X  POST http://managementUI_IP:8080/v1/users/resetUser@email.com  -d  '<?xml version="1.0" encoding="UTF-8" standalone="yes"?><User><Password>newPassword8Digit</Password><FirstName>ResetuserFirst</FirstName>
<LastName>resetUserLast</LastName><EmailId>resetUser@email.com</EmailId></User>'  -H    "Content-Type:application/xml"