גאבור סבו - Gábor Szabó > CGI-FileManager > CGI::FileManager::Auth

Download:
CGI-FileManager-0.06.tar.gz

Dependencies

Annotate this POD

CPAN RT

Open  0
View/Report Bugs
Source  

SYNOPIS ^

 my $auth = CGI::FileManager::Auth->new();
 if ($auth->verify($username, $password)) {
   # Valid user
 } else {
   $ Invalid username/password pair
 }

 Currently username/password pairs are hard coded and clear text. Just for testing.
 Later we expect to have Authentication plugins to the system and this module will probably
 hide them from the real module.

new

 my $auth = CGI::FileManager::Auth->new;

 Does nothing
        my $self    = {
                users => {
                        gabor => {
                                password => 'nincs',
                                home     => "$Bin/../dir",
                                #home     => '/home/gabor/work/gabor/dev/CGI-FileManager/dir',
                        }
                },
        };
        bless $self, $class;

home

Return the home directory of the given user

verify

verify username password

syntax highlighting: