Egg::Model::Auth::Plugin::Keep - The attestation is maintained by Cookie.


Egg-Release-Authorize documentation  | view source Contained in the Egg-Release-Authorize distribution.

Index


NAME

Top

Egg::Model::Auth::Plugin::Keep - The attestation is maintained by Cookie.

SYNOPSIS

Top

  package MyApp::Model::Auth::MyAuth;
  ..........

  __PACKAGE__->config(
    check_sum => 'abcdefghijklmnopqrstu',
    delimiter  => ' : ',
    param_name => '__auto_login',
    cookie => {
      ...........
      },
    crypt => {
      ...........
      },
    );

  __PACKAGE__->setup_plugin(qw/ Keep /);

  __PACKAGE__->setup_session('SessionKit');

DESCRIPTION

Top

The attestation session to which the code that can be decoded to Cookie is set and the session cut is revived. As a result, the attestation is maintained to perpetuity.

'plugin_keep' is set to the configuration to use it, and 'Keep' is included in the list of 'setup_session' method.

  __PACKAGE__->setup_plugin(qw/ Keep /);

It and the session component are needed.

  __PACKAGE__->setup_session( FileCache => qw/ Bind::Cookie / );

When 'login_check' is called, Cookie for the perpetuity attestation is set if the input parameter concerning 'The next automatic log in' is effective.

Attestation information is acquired from Cookie if the attestation session doesn't exist when 'is_login' is called and the attestation session is revived at the following.

It is necessary to note it very when using it to preserve attestation information in Cookie.

CONDIFGURATION

Top

The following items are set and used in 'plugin_keep'.

check_sum

Character string of 20-40 suitable digit to generate checksum.

delimiter

Each attestation data delimiter. Default is ' : '.

param_name

Name of the form data for flag to do perpetuity attestation effectively. Default is '__auto_login'.

crypt

The content is an option to pass to Crypt::CBC.

METHODS

Top

is_login

If the attestation session exists and doesn't exist, attestation information is acquired from Cookie, and the attestation session is revived.

And, processing is passed to 'is_login' of Egg::Model::Auth::Base.

remove_bind_id

reset

Cookie for the perpetuity attestation is annulled. And, processing is passed to 'reset' of Egg::Model::Auth::Base.

SEE ALSO

Top

Egg::Release, Egg::Model::Auth, Egg::Model::Auth::Base, Egg::Response, Crypt::CBC, Digest::SHA1,

AUTHOR

Top

Masatoshi Mizuno <lushe&64;cpan.org>

COPYRIGHT AND LICENSE

Top


Egg-Release-Authorize documentation  | view source Contained in the Egg-Release-Authorize distribution.