Lemonldap::NG::Handler::CDA - Module to use Lemonldap::NG::Handler


Lemonldap-NG-Handler documentation Contained in the Lemonldap-NG-Handler distribution.

Index


Code Index:

NAME

Top

Lemonldap::NG::Handler::CDA - Module to use Lemonldap::NG::Handler mechanisms with Cross-Domain-Authentication.

SYNOPSIS

Top

New usage:

  package My::Package;
  use Lemonldap::NG::Handler;
  @ISA = qw(Lemonldap::NG::Handler);
  __PACKAGE__->init ( {
    cda                 => 1,
    localStorage        => "Cache::FileCache",
    localStorageOptions => {
        'namespace' => 'MyNamespace',
        'default_expires_in' => 600,
      },
    reloadTime          => 1200, # Default: 600
    configStorage       => {
       type                => "DBI"
       dbiChain            => "DBI:mysql:database=$database;host=$hostname;port=$port",
       dbiUser             => "lemonldap",
       dbiPassword         => "password",
    },
  } );

Call your package in /apache-dir/conf/httpd.conf :

  PerlRequire MyFile
  # TOTAL PROTECTION
  PerlHeaderParserHandler My::Package
  # OR SELECTED AREA
  <Location /protected-area>
    PerlHeaderParserHandler My::Package
  </Location>

The configuration is loaded only at Apache start. Create an URI to force configuration reload, so you don't need to restart Apache at each change :

  # /apache-dir/conf/httpd.conf
  <Location /location/that/I/ve/choosed>
    Order deny,allow
    Deny from all
    Allow from my.manager.com
    PerlHeaderParserHandler My::Package->refresh
  </Location>

DESCRIPTION

Top

This library inherit from Lemonldap::NG::Handler::SharedConf and add the capability to control users that are authenticated with a Lemonldap::NG::Portal::CDA CGI in another domain.

EXPORT

Same as Lemonldap::NG::Handler::SharedConf.

SEE ALSO

Top

Lemonldap::NG::Manager, Lemonldap::NG::Handler, Lemonldap::NG::Handler::SharedConf, http://lemonldap-ng.org/

AUTHOR

Top

Xavier Guimard, <x.guimard@free.fr>

BUG REPORT

Top

Use OW2 system to report bug or ask for features: http://jira.ow2.org

DOWNLOAD

Top

Lemonldap::NG is available at http://forge.objectweb.org/project/showfiles.php?group_id=274

COPYRIGHT AND LICENSE

Top


Lemonldap-NG-Handler documentation Contained in the Lemonldap-NG-Handler distribution.

##@file
# Cross-domain mechanism for handler

##@class
# Cross-domain mechanism for handler
package Lemonldap::NG::Handler::CDA;

use strict;

use Lemonldap::NG::Handler::SharedConf qw(:all);

our $VERSION = '1.0.0';

use base qw(Lemonldap::NG::Handler::SharedConf);

## @rmethod int run(Apache2::RequestRec apacheRequest)
# overload run subroutine to implement cross-domain mechanism.
# @param $apacheRequest
# @return Apache constant
sub run ($$) {
    my $class;
    ( $class, $apacheRequest ) = splice @_;
    $cda = 1;
    return $class->SUPER::run($apacheRequest);
}

1;
__END__