1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60
|
Description: use Digest::SHA instead of SHA1
cf. http://wiki.debian.org/Teams/DebianPerlGroup/OpenTasks/Transitions/DigestSHA1ToDigestSHA
Origin: vendor
Author: gregor herrmann <gregoa@debian.org>
Last-Update: 2015-06-13
Forwarded: https://rt.cpan.org/Ticket/Display.html?id=105209
Bug: https://rt.cpan.org/Ticket/Display.html?id=105209
--- a/README
+++ b/README
@@ -227,7 +227,7 @@
digest_module
Which digest module to use to create the checksum. Typically, this
- will be either "Digest::MD5" or "Digest::SHA1". However any module
+ will be either "Digest::MD5" or "Digest::SHA". However any module
supported by "Digest::HMAC" will work.
The default "digest_module" is "Digest::MD5".
--- a/lib/CGI/Application/Plugin/LinkIntegrity.pm
+++ b/lib/CGI/Application/Plugin/LinkIntegrity.pm
@@ -276,7 +276,7 @@
=item digest_module
Which digest module to use to create the checksum. Typically, this will
-be either C<Digest::MD5> or C<Digest::SHA1>. However any module
+be either C<Digest::MD5> or C<Digest::SHA>. However any module
supported by C<Digest::HMAC> will work.
The default C<digest_module> is C<Digest::MD5>.
--- a/t/04-hmac.t
+++ b/t/04-hmac.t
@@ -165,23 +165,23 @@
# Same test but with SHA1 (if available)
SKIP: {
eval {
- require Digest::SHA1;
+ require Digest::SHA;
};
- skip 'Digest::SHA1 not installed', 3 if $@;
+ skip 'Digest::SHA not installed', 3 if $@;
$secret = 'even secreter';
$self->link_integrity_config(
'secret' => $secret,
- 'digest_module' => 'Digest::SHA1',
+ 'digest_module' => 'Digest::SHA',
'additional_data' => 'abcde',
);
$uri = '/foo/bar/baz?one=foo&two=boom';
$link = $self->link($uri);
- $hmac = Digest::HMAC->new($secret, 'Digest::SHA1');
+ $hmac = Digest::HMAC->new($secret, 'Digest::SHA');
$u = URI->new($uri, 'http');
$hmac->add($u->scheme || '');
|