Slackware::Slackget::Network::Auth - The authentification/authorization class for slack-getd network deamons.


Slackware-Slackget documentation  | view source Contained in the Slackware-Slackget distribution.

Index


NAME

Top

Slackware::Slackget::Network::Auth - The authentification/authorization class for slack-getd network deamons.

VERSION

Top

Version 1.0.0

SYNOPSIS

Top

This class is used by slack-get daemon's to verify the permission of an host.

    use Slackware::Slackget::Network::Auth;

    my $auth = Slackware::Slackget::Network::Auth->new($config);
    if(!$auth->can_connect($client->peerhost()))
    {
    	$client->close ;
    }




CONSTRUCTOR

Top

new

The constructor just take one argument: a Slackware::Slackget::Config object :

	my $auth = new Slackware::Slackget::Network::Auth ($config);

FUNCTIONS

Top

All methods name are the same as configuration file directives, but you need to change '-' to '_'.

RETURNED VALUES

All methods return TRUE (1) if directive is set to 'yes', FALSE (0) if set to 'no' and undef if the directive cannot be found in the Slackware::Slackget::Config. For some secure reasons, all directives are in read-only access. But in the real use the undef value must never been returned, because all method fall back to the <all> section on undefined value. So if a method return undef, this is because the <daemon> -> <connection-policy> -> <all> section is not complete, and that's really a very very bad idea !

can_connect

Take an host address and return the appropriate value.

	$auth->can_connect($client->peerhost) or die "client is not allow to connect\n";

can_build_packages_list

can_build_installed_list

can_install_packages

can_upgrade_packages

can_remove_packages

can_require_installed_list

can_require_servers_list

can_require_packages_list

is_allowed_to

AUTHOR

Top

DUPUIS Arnaud, <a.dupuis@infinityperl.org>

BUGS

Top

Please report any bugs or feature requests to bug-Slackware-Slackget@rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Slackware-Slackget. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.

SUPPORT

Top

You can find documentation for this module with the perldoc command.

    perldoc Slackware::Slackget




You can also look for information at:

* Infinity Perl website

http://www.infinityperl.org

* slack-get specific website

http://slackget.infinityperl.org

* RT: CPAN's request tracker

http://rt.cpan.org/NoAuth/Bugs.html?Dist=Slackware-Slackget

* AnnoCPAN: Annotated CPAN documentation

http://annocpan.org/dist/Slackware-Slackget

* CPAN Ratings

http://cpanratings.perl.org/d/Slackware-Slackget

* Search CPAN

http://search.cpan.org/dist/Slackware-Slackget

ACKNOWLEDGEMENTS

Top

Thanks to Bertrand Dupuis (yes my brother) for his contribution to the documentation.

COPYRIGHT & LICENSE

Top


Slackware-Slackget documentation  | view source Contained in the Slackware-Slackget distribution.