auth::create_local_account (public)

 auth::create_local_account [ -user_id user_id ] \
    -authority_id authority_id [ -username username ] -array array

Defined in packages/acs-authentication/tcl/authentication-procs.tcl

Create the local account for a user.

Switches:
-user_id (optional)
-authority_id (required)
-username (optional)
-array (required)
Name of an array containing the registration elements to update. Fields are specified by auth::get_all_registration_elements
Returns:
Array list containing the following entries:
  • creation_status: ok, data_error, reg_error, failed_to_connect. Says whether user creation succeeded.
  • creation_message: Information about the problem, to be relayed to the user. If creation_status is not ok, then either creation_message or element_messages is guaranteed to be nonempty, and both are guaranteed to be in the array list. May contain HTML.
  • element_messages: list of (element_name, message, element_name, message, ...) of errors on the individual registration elements. to be relayed on to the user. If creation_status is not ok, then either creation_message or element_messages is guaranteed to be nonempty, and both are guaranteed to be in the array list. Cannot contain HTML.
  • account_status: ok, closed. Only set if creation_status was ok, this says whether the newly created account is ready for use or not. For example, we may require approval, in which case the account would be created but closed.
  • account_message: A human-readable explanation of why the account was closed. May include HTML, and thus shouldn't be quoted. Guaranteed to be nonempty if account_status is not ok.
All entries are guaranteed to always be set, but may be empty.
See Also:

Partial Call Graph (max 5 caller/called nodes):
%3 test_auth_use_email_for_login_p auth_use_email_for_login_p (test acs-authentication) auth::create_local_account auth::create_local_account test_auth_use_email_for_login_p->auth::create_local_account _ _ (public) auth::create_local_account->_ acs_user::get_by_username acs_user::get_by_username (public) auth::create_local_account->acs_user::get_by_username acs_user::get_user_info acs_user::get_user_info (public) auth::create_local_account->acs_user::get_user_info ad_conn ad_conn (public) auth::create_local_account->ad_conn ad_log ad_log (public) auth::create_local_account->ad_log Class ::xo::Authorize Class ::xo::Authorize (public) Class ::xo::Authorize->auth::create_local_account auth::create_user auth::create_user (public) auth::create_user->auth::create_local_account auth::get_local_account auth::get_local_account (private) auth::get_local_account->auth::create_local_account auth::sync::job::action auth::sync::job::action (public) auth::sync::job::action->auth::create_local_account install::xml::action::create-user install::xml::action::create-user (public) install::xml::action::create-user->auth::create_local_account

Testcases:
auth_use_email_for_login_p
[ show source ]
Show another procedure: