Class ::xo::Authorize

::xo::Authorize[i] create ... \
           [ -after_successful_login_url (default "/pvt/") ] \
           [ -base_url base_url ] \
           [ -client_id client_id ] \
           [ -client_secret client_secret ] \
           [ -create_not_registered_users:boolean (default "false") ] \
           [ -create_with_dotlrn_role (default "") ] \
           [ -debug:boolean (default "false") ] \
           [ -login_failure_url (default "/") ] \
           [ -pretty_name pretty_name ] \
           [ -responder_url responder_url ] \
           [ -scope scope ]

Base class to support OAuth authorization API
Defined in packages/xooauth/tcl/authorize-procs.tcl

Class Relations

  • class: ::nx::Class[i]
  • superclass: ::xo::REST[i]
  • subclass: ::ms::Authorize[i], ::xo::oauth::GitHub[i]

Methods (to be applied on instances)

  • login_url (scripted, public)

     <instance of xo::Authorize[i]> login_url [ -return_url return_url ] \
        [ -login login ]

    Returns the URL for log-in

    Switches:
    -return_url (optional)
    -login (optional)

    Testcases:
    No testcase defined.
  • logout (scripted, public)

     <instance of xo::Authorize[i]> logout

    Perform logout operation from oauth in the background (i.e. without a redirect) when the logout_url is nonempty.

    Testcases:
    No testcase defined.
  • name (scripted, public)

     <instance of xo::Authorize[i]> name
    Returns:
    instance name

    Testcases:
    No testcase defined.
  • perform_login (scripted, public)

     <instance of xo::Authorize[i]> perform_login [ -token token ] \
        [ -state state ]

    Get the provided claims from the identity provider and perform an OpenACS login, when the user exists. In case the user does not exist, create it optionally (when "create_not_registered_users" is activated. When the user is created, and dotlrn is installed, the new user might be added optionally as a dotlrn user with the role as specified in "create_with_dotlrn_role".

    Switches:
    -token (optional)
    -state (optional)

    Testcases:
    No testcase defined.