sec_get_user_auth_token (public)

 sec_get_user_auth_token user_id

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

Get the user's auth token for verifying login cookies.

Parameters:
user_id (required)

Partial Call Graph (max 5 caller/called nodes):
%3 ad_user_login ad_user_login (public) sec_get_user_auth_token sec_get_user_auth_token ad_user_login->sec_get_user_auth_token sec_handler sec_handler (private) sec_handler->sec_get_user_auth_token sec_login_handler sec_login_handler (public) sec_login_handler->sec_get_user_auth_token db_string db_string (public) sec_get_user_auth_token->db_string sec_change_user_auth_token sec_change_user_auth_token (public) sec_get_user_auth_token->sec_change_user_auth_token

Testcases:
No testcase defined.
Source code:
    set auth_token [db_string select_auth_token {
        select auth_token from users where user_id = :user_id
    } -default {}]

    if { $auth_token eq "" } {
        ns_log Debug "Security: User $user_id does not have any auth_token, creating a new one."
        set auth_token [sec_change_user_auth_token $user_id]
    }

    return $auth_token
Generic XQL file:
packages/acs-tcl/tcl/security-procs.xql

PostgreSQL XQL file:
packages/acs-tcl/tcl/security-procs-postgresql.xql

Oracle XQL file:
packages/acs-tcl/tcl/security-procs-oracle.xql

[ hide source ] | [ make this the default ]
Show another procedure: