File: TestAuthenticator.pm

package info (click to toggle)
gbrowse 2.56%2Bdfsg-11
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 13,144 kB
  • sloc: perl: 50,765; javascript: 15,890; sh: 227; sql: 62; makefile: 50; ansic: 27
file content (20 lines) | stat: -rw-r--r-- 454 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
package Bio::Graphics::Browser2::Plugin::TestAuthenticator;
# $Id$
use strict;
use base 'Bio::Graphics::Browser2::Plugin::AuthPlugin';

sub authenticate {
    my $self = shift;
    my ($name,$password) = $self->credentials;
    if ($name eq 'lincoln' && $password eq 'foobar') {
	return ($name,'Lincoln Stein');  # username, fullname	
    } elsif ($name eq 'jane' && $password eq 'foobar') {
	return ($name,'Jane Doe');
    }
    return;
}


1;

__END__