Wallet::ACL::Nested

(Wallet ACL verifier to check another ACL)

SYNOPSIS

    my $verifier = Wallet::ACL::Nested->new;
    my $status = $verifier->check ($principal, $acl);
    if (not defined $status) {
        die "Something failed: ", $verifier->error, "\n";
    } elsif ($status) {
        print "Access granted\n";
    } else {
        print "Access denied\n";
    }

DESCRIPTION

Wallet::ACL::Nested checks whether the principal is permitted by another named ACL and, if so, returns success. It is used to nest one ACL inside another.

METHODS

new()

Creates a new ACL verifier.

check(PRINCIPAL, ACL)

Returns true if PRINCIPAL is granted access according to the nested ACL, specified by name. Returns false if it is not, and undef on error.

error([ERROR ...])

Returns the error of the last failing operation or undef if no operations have failed. Callers should call this function to get the error message after an undef return from any other instance method. The returned errors will generally come from the nested child ACL.

SEE ALSO

Wallet::ACL(3), wallet-backend(8)

This module is part of the wallet system. The current version is available from <https://www.eyrie.org/~eagle/software/wallet/>.

AUTHOR

Jon Robertson <jonrober@stanford.edu>

Last spun 2024-05-01 from POD modified 2024-04-30