I'm trying to change user password with modifyPasswordRequest using PHP SDK. I've run into two problems:

1) When I try this authenticated as trusted application, API returns OK, but user cannot log in. Error message is
[D05A] User Database access has been denied
This can be fixed by changing password in ConsoleOne.

2) When I try this with user credentials, API call fails with following error:
59905: Bad parameter passed to a NCSP function

I need to change user passwords with trusted app, but I'm curious why the same call with user credentials fails like this.

We're using GW2012.

Any idea why this is happening and how to fix this problem?

Thank you.