Lines Matching full:user
18 * Create a new user
20 * If no password is provided, a password is auto generated. If the user can't be created
26 * @param string $user The user's login name
27 * @param string $name The user's full name
28 * @param string $mail The user's email address
29 * @param string[] $groups The groups the user should be in
30 * @param string $password The user's password, empty for autogeneration
31 * @param bool $notify Whether to send a notification email to the user
32 * @return bool Wether the user was successfully created
37 public function createUser($user, $name, $mail, $groups, $password = '', $notify = false) argument
53 $user = trim($auth->cleanUser($user));
57 if ($user === '') throw new RemoteException('empty or invalid user', 401);
58 if ($name === '') throw new RemoteException('empty or invalid user name', 402);
63 $password = auth_pwgen($user);
73 $ok = (bool)$auth->triggerUserMod('create', [$user, $password, $name, $mail, $groups]);
76 auth_sendPassword($user, $password);
84 * Remove a user
88 * @param string[] $user The login name of the user to delete
89 * @return bool wether the user was successfully deleted
93 public function deleteUser($user) argument
109 return (bool)$auth->triggerUserMod('delete', [[$user]]);