Sets a user's password, erasing the existing password.
Syntax
ESS_FUNC_M EssSetPassword (hCtx, UserName, Password);
Parameter | Data Type | Description |
---|---|---|
hCtx | ESS_HCTX_T | API context handle. |
UserName | ESS_STR_T | User name. |
Password | ESS_STR_T | New password for user. |
Notes
To change a password, the caller must either have supervisor access, or be changing their own password.
The new password will take effect the next time the user logs in.
Return Value
None.
Access
This function requires callers to have Create/Delete User privilege (ESS_PRIV_USERCREATE) for the logged in server, unless they are setting their own password.
Example
ESS_FUNC_M ESS_SetPassword (ESS_HCTX_T hCtx) { ESS_FUNC_M sts = ESS_STS_NOERR; ESS_STR_T UserName; ESS_STR_T Password; UserName = "Jim Smith"; Password = "newpwd"; sts = EssSetPassword (hCtx,UserName, Password); return (sts); }
See Also