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.160010'; # TRIAL VERSION |
4
|
|
|
|
|
|
|
our $AUTHORITY = 'cpan:ARODLAND'; # AUTHORITY |
5
|
5
|
|
|
5
|
|
3887
|
use Moo 2; |
|
5
|
|
|
|
|
125
|
|
|
5
|
|
|
|
|
37
|
|
6
|
5
|
|
|
5
|
|
1463
|
use strictures 2; |
|
5
|
|
|
|
|
40
|
|
|
5
|
|
|
|
|
243
|
|
7
|
5
|
|
|
5
|
|
1136
|
use namespace::autoclean; |
|
5
|
|
|
|
|
10
|
|
|
5
|
|
|
|
|
37
|
|
8
|
5
|
|
|
5
|
|
4598
|
use Digest::SHA (); |
|
5
|
|
|
|
|
37394
|
|
|
5
|
|
|
|
|
188
|
|
9
|
5
|
|
|
5
|
|
35
|
use Carp qw(croak); |
|
5
|
|
|
|
|
11
|
|
|
5
|
|
|
|
|
1137
|
|
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
with 'Crypt::PBKDF2::Hash'; |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
sub hash_len { |
14
|
9012
|
|
|
9012
|
0
|
24139
|
return 20; |
15
|
|
|
|
|
|
|
} |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
sub generate { |
18
|
210509
|
|
|
210509
|
0
|
242152
|
my $self = shift; # ($data, $key) |
19
|
210509
|
|
|
|
|
1595356
|
return Digest::SHA::hmac_sha1(@_); |
20
|
|
|
|
|
|
|
} |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
sub to_algo_string { |
23
|
1001
|
|
|
1001
|
0
|
2152
|
return; |
24
|
|
|
|
|
|
|
} |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
sub from_algo_string { |
27
|
0
|
|
|
0
|
0
|
|
croak "No argument expected"; |
28
|
|
|
|
|
|
|
} |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
1; |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
__END__ |