Lemonldap::NG::Common::Conf::SOAP - Perl extension written to access to Lemonldap::NG Web-SSO configuration via SOAP.
package My::Package; use base Lemonldap::NG::Handler::SharedConf; __PACKAGE__->init ( { localStorage => "Cache::FileCache", localStorageOptions => { 'namespace' => 'lemonldap-ng', 'default_expires_in' => 600, }, configStorage => { type => 'SOAP', proxy => 'http://auth.example.com/index.pl/config', # If soapserver is protected by HTTP Basic: User => 'http-user', Password => 'pass', }, https => 0, } );
use Lemonldap::NG::Portal::SharedConf; my $portal = Lemonldap::NG::Portal::SharedConf->new ( { configStorage => { type => 'SOAP', proxy => 'http://auth.example.com/index.pl/config', # If soapserver is protected by HTTP Basic: User => 'http-user', Password => 'pass', } }); # Next as usual... See Lemonldap::NG::Portal(3) if($portal->process()) { ...
use Lemonldap::NG::Manager; my $m=new Lemonldap::NG::Manager( { configStorage=>{ type => 'SOAP', proxy => 'http://auth.example.com/index.pl/config', # If soapserver is protected by HTTP Basic: User => 'http-user', Password => 'pass', }, dhtmlXTreeImageLocation=> "/imgs/", } ) or die "Unable to start manager"; $m->doall();
You just have to set "Soap => 1" in your portal. See HTML documentation for more.
Lemonldap::NG::Common::Conf provides a simple interface to access to Lemonldap::NG Web-SSO configuration. It is used by Lemonldap::NG::Handler, Lemonldap::NG::Portal and Lemonldap::NG::Manager.
Lemonldap::NG::Common::Conf::SOAP provides the "SOAP" target used to access configuration via SOAP.
As Lemonldap::NG::Common::Conf::SOAP use SOAP::Lite, you have to see SOAP::Transport to know arguments that can be passed to proxyOptions. Lemonldap::NG provides a system for HTTP basic authentication.
proxyOptions
Examples :
HTTP Basic authentication
package My::Package; use base Lemonldap::NG::Handler::SharedConf; __PACKAGE__->init ( { localStorage => "Cache::FileCache", localStorageOptions => { 'namespace' => 'lemonldap-ng', 'default_expires_in' => 600, }, configStorage => { type => 'SOAP', proxy => 'http://auth.example.com/index.pl/config', User => 'http-user', Password => 'pass', }, https => 1, } );
SSL Authentication
SOAP::transport provides a simple way to use SSL certificate: you've just to set environment variables.
package My::Package; use base Lemonldap::NG::Handler::SharedConf; # AUTHENTICATION $ENV{HTTPS_CERT_FILE} = 'client-cert.pem'; $ENV{HTTPS_KEY_FILE} = 'client-key.pem'; __PACKAGE__->init ( { localStorage => "Cache::FileCache", localStorageOptions => { 'namespace' => 'lemonldap-ng', 'default_expires_in' => 600, }, configStorage => { type => 'SOAP', proxy => 'http://auth.example.com/index.pl/config', }, https => 1, } );
Lemonldap::NG::Common::Conf::SOAP, Lemonldap::NG::Handler, Lemonldap::NG::Portal, http://lemonldap-ng.org/
Use OW2 system to report bug or ask for features: http://jira.ow2.org
Lemonldap::NG is available at http://forge.objectweb.org/project/showfiles.php?group_id=274
This library is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
To install Lemonldap::NG::Common, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Lemonldap::NG::Common
CPAN shell
perl -MCPAN -e shell install Lemonldap::NG::Common
For more information on module installation, please visit the detailed CPAN module installation guide.