NAME

Articulate::Authentication - determine if a user who they claim to be

SYNOPSIS

# in config:
components:
  authentication:
    Articulate::Authentication:
      providers:
        - Articulate::Authentication::AlwaysAllow

# then any component can dp
$component->authentication->login($credentials);
$component->authentication->login($user_id, $password);

ATTRIBUTE

providers

A list of providers which can respond to login.

login

$authentication->login($credentials);
$authentication->login( $user_id, $password );

Asks each provider if the credentials supplied match a known user. Credentials may be in whatever form will satisfy the credentials function in Articulate::Credentials (username and password, hashref or credentials object).

Each provider must respond true, false, or undef. A true value means the user is authenticated. A false value means that the user exists but is explicitly refused access (this should only be used in exceptional circumstances) and an undef value means the user cannot be authenticated by the provider (but could be authenticated by some other provider).

create_user

$authentication->create_user( $user_id, $password );

Requests that a new user is created. Each provider must respond true, false, or undef.

SEE ALSO