lib/Dancer/Plugin/Auth/Basic.pm | |||
---|---|---|---|
Criterion | Covered | Total | % |
condition | 20 | 25 | 80.0 |
line | !l | l&&!r | l&&r | condition |
---|---|---|---|---|
75 | 9 | 0 | 23 | defined $auth and $auth =~ /^Basic (.*)$/ |
81 | 1 | 1 | 6 | $user eq $options{'user'} && _check_password($options{'password'}, $password) |
84 | 8 | 15 | 0 | not defined $authorized and exists $options{'users'} |
87 | 2 | 3 | 8 | exists $options{'users'}{$user} && _check_password($options{'users'}{$user}, $password) |
90 | 14 | 0 | 9 | not $authorized and defined $users |
93 | 5 | 0 | 4 | exists $users->{$user} && _check_password($users->{$user}, $password) |
line | l | !l | condition |
---|---|---|---|
76 | 23 | 0 | &MIME::Base64::decode($1) || ':' |
117 | 1 | 13 | $options{'realm'} || 'Restricted area' |
line | l | !l&&r | !l&&!r | condition |
---|---|---|---|---|
36 | 1 | 6 | 15 | $crypt = $password =~ /^\$\w+\$/ or $password =~ /^\{\w+\}/ |