Changing passwords using the remote API

5 posts / 0 new
Last post
#1 Thu, 01/26/2012 - 08:53
darrenp

Changing passwords using the remote API

Just wondering if anyone has managed to modify the change password script to support this? I understand that it should be easy to just pass command line args to the perl script but I'm not sure how to go about making this script available to the remote API.

Does anyone have any experience/suggestions?

Thanks!

Thu, 01/26/2012 - 09:12
andreychek

Howdy,

You should be able to do that using the "modify-user" option.

Using the command line tools, that looks like this:

virtualmin modify-user --user USERNAME --pass NEW_PASSWORD

Those same parameters should work in the remote API.

-Eric

Fri, 01/27/2012 - 11:59
darrenp

Hi Eric,

Sorry, I should have been more clear - I mean a virtual server's admin password, hence the "change-password" script. I already have standard user password changes working :-)

Fri, 01/27/2012 - 13:14
andreychek

Howdy,

You can use "modify-domain" for that... there's details here:

https://www.virtualmin.com/documentation/developer/cli/modify_domain

You can pass in the "pass" parameter to modify-domain to change the Virtual Server owner's password.

-Eric

Fri, 01/27/2012 - 13:54
darrenp

Thanks Eric, that did the trick.

Topic locked