use core Digest::SHA rather than Digest::SHA1
[catagits/Catalyst-Plugin-Authentication.git] / t / lib / AuthTestApp.pm
CommitLineData
a3bf437a 1package AuthTestApp;
d055ce0c 2use strict;
3use warnings;
4use base qw/Catalyst/;
a3bf437a 5use Catalyst qw/
fb90f091 6 Authentication
7 Authentication::Store::Minimal
8 Authentication::Credential::Password
a3bf437a 9/;
10
a3bf437a 11use Digest::MD5 qw/md5/;
e8b9ffa9 12use Digest::SHA qw/sha1_base64/;
a3bf437a 13
d055ce0c 14our $users = {
15 foo => {
16 password => "s3cr3t",
17 },
18 bar => {
19 crypted_password => crypt("s3cr3t", "x8"),
20 },
21 gorch => {
22 hashed_password => md5("s3cr3t"),
23 hash_algorithm => "MD5",
24 },
25 shabaz => {
26 hashed_password => sha1_base64("s3cr3t"),
27 hash_algorithm => "SHA-1"
28 },
29 sadeek => {
30 hashed_password => sha1_base64("s3cr3t").'=',
31 hash_algorithm => "SHA-1"
32 },
33 baz => {},
34};
a3bf437a 35
d055ce0c 36__PACKAGE__->config('Plugin::Authentication' =>{users => $users});
a3bf437a 37
d055ce0c 38__PACKAGE__->setup;
a3bf437a 39
d055ce0c 401;
a3bf437a 41