Stefan Hornburg (Racke) > ACL-Lite-0.0001 > ACL::Lite

Download:
ACL-Lite-0.0001.tar.gz

Dependencies

Annotate this POD

View/Report Bugs
Module Version: 0.0001   Source   Latest Release: ACL-Lite-0.0004

NAME ^

ACL::Lite - Liteweight and flexible ACL checks

VERSION ^

Version 0.0001

SYNOPSIS ^

    use ACL::Lite;

    $acl = ACL::Lite->new(permissions => 'foo,bar');

    $acl->check('foo');

    if ($ret = $acl->check([qw/baz bar/])) {
        print "Check successful with permission $ret\n";
    }

    unless ($acl->check('baz')) {
        print "Permission denied\n";
    }

CONSTRUCTOR ^

new

Creates an ACL::Lite object by passing the following parameters:

uid

User identifier for authenticated users.

permissions

Granted permissions.

separator

Separator used to parse permission strings. Defaults to ,.

check $permissions, $uid

Checks whether any of the permissions in $permissions is granted. Returns first permission which grants access.

CAVEATS ^

Please anticipate API changes in this early state of development.

AUTHOR ^

Stefan Hornburg (Racke), racke@linuxia.de

BUGS ^

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

SUPPORT ^

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

    perldoc ACL::Lite

You can also look for information at:

ACKNOWLEDGEMENTS ^

LICENSE AND COPYRIGHT ^

Copyright 2011 Stefan Hornburg (Racke).

This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.

See http://dev.perl.org/licenses/ for more information.

syntax highlighting: