line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Crypt::PBKDF2::Hash::HMACSHA1; |
2
|
|
|
|
|
|
|
# ABSTRACT: HMAC-SHA1 support for Crypt::PBKDF2 using Digest::SHA |
3
|
|
|
|
|
|
|
our $VERSION = '0.161520'; # VERSION |
4
|
|
|
|
|
|
|
our $AUTHORITY = 'cpan:ARODLAND'; # AUTHORITY |
5
|
5
|
|
|
5
|
|
2975
|
use Moo 2; |
|
5
|
|
|
|
|
111
|
|
|
5
|
|
|
|
|
30
|
|
6
|
5
|
|
|
5
|
|
1125
|
use strictures 2; |
|
5
|
|
|
|
|
55
|
|
|
5
|
|
|
|
|
216
|
|
7
|
5
|
|
|
5
|
|
824
|
use namespace::autoclean; |
|
5
|
|
|
|
|
5
|
|
|
5
|
|
|
|
|
40
|
|
8
|
5
|
|
|
5
|
|
2298
|
use Digest::SHA (); |
|
5
|
|
|
|
|
10366
|
|
|
5
|
|
|
|
|
122
|
|
9
|
5
|
|
|
5
|
|
22
|
use Carp qw(croak); |
|
5
|
|
|
|
|
9
|
|
|
5
|
|
|
|
|
666
|
|
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
with 'Crypt::PBKDF2::Hash'; |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
sub hash_len { |
14
|
9012
|
|
|
9012
|
0
|
15528
|
return 20; |
15
|
|
|
|
|
|
|
} |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
sub generate { |
18
|
210509
|
|
|
210509
|
0
|
128067
|
my $self = shift; # ($data, $key) |
19
|
210509
|
|
|
|
|
946340
|
return Digest::SHA::hmac_sha1(@_); |
20
|
|
|
|
|
|
|
} |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
sub to_algo_string { |
23
|
1001
|
|
|
1001
|
0
|
1454
|
return; |
24
|
|
|
|
|
|
|
} |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
sub from_algo_string { |
27
|
0
|
|
|
0
|
0
|
|
croak "No argument expected"; |
28
|
|
|
|
|
|
|
} |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
1; |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
__END__ |