Syntax
int getgrouppasswd ( string group [, int attempts])
Description
The getgrouppasswd function prompts you for a user name in the user group group on the policy server and then prompts for that user’s password and authenticates the user on the policy server. The user may try up to attempts times to correctly enter the password before the function exits. The default number of allowed attempts is 3.
By default, this function authenticates the user on the policy server. Set the value of getpasswordfromrun in pm.settings to yes to authenticate the user on the client instead.
Returns true if the user successfully authenticates on the policy server, otherwise returns false if the user fails to authenticate after attempts tries.
Example
if (getgrouppasswd("admin", 2) == false) { reject; }