Security Advisories (2)
CVE-2020-17478 (2020-08-10)

ECDSA/EC/Point.pm in Crypt::Perl before 0.33 does not properly consider timing attacks against the EC point multiplication algorithm.

CVE-2020-13895 (2020-06-07)

Crypt::Perl::ECDSA in the Crypt::Perl (aka p5-Crypt-Perl) module before 0.32 for Perl fails to verify correct ECDSA signatures when r and s are small and when s = 1. This happens when using the curve secp256r1 (prime256v1). This could conceivably have a security-relevant impact if an attacker wishes to use public r and s values when guessing whether signature verification will fail.

NAME

Crypt::Perl::ECDSA::Generate - ECDSA key generation

SYNOPSIS

use Crypt::Perl::ECDSA::Generate ();

#$prkey is a C::P::E::PrivateKey instance.
my $prkey = Crypt::Perl::ECDSA::Generate::by_name('secp521r1');

my $signature = $prkey->sign('Hello!');

die 'Wut' if $prkey->verify('Hello!', $signature);

#You can also, in case it’s useful, do this. It’s probably
#only useful if you’re developing a new curve or something … ??
my $prkey2 = Crypt::Perl::ECDSA::Generate::by_explicit_curve(
    {
        p => Crypt::Perl::BigInt->new(...),
        a => ...,
        b => ...,
        n => ...,
        h => ...,
        gx => ...,
        gy => ...,
    },
);

DISCUSSION

Thankfully, this is easy enough on processors that it’s feasible in pure Perl!