Crypto++ 8.9
Free C++ class library of cryptographic schemes
Static Public Member Functions | List of all members
DSA2< H > Class Template Reference

DSA signature scheme. More...

#include <gfpcrypt.h>

+ Inheritance diagram for DSA2< H >:

Static Public Member Functions

static std::string StaticAlgorithmName ()
 
- Static Public Member Functions inherited from DL_SS< DL_Keys_DSA, DL_Algorithm_GDSA< Integer >, DL_SignatureMessageEncodingMethod_DSA, H, DSA2< H > >
static std::string StaticAlgorithmName ()
 

Additional Inherited Members

- Public Types inherited from DL_SS< DL_Keys_DSA, DL_Algorithm_GDSA< Integer >, DL_SignatureMessageEncodingMethod_DSA, H, DSA2< H > >
typedef PK_FinalTemplate< DL_SignerImpl< SchemeOptions > > Signer
 implements PK_Signer interface
 
typedef PK_FinalTemplate< DL_VerifierImpl< SchemeOptions > > Verifier
 implements PK_Verifier interface
 
- Public Types inherited from DL_Keys_DSA
typedef DL_PublicKey_GFP< DL_GroupParameters_DSAPublicKey
 
typedef DL_PrivateKey_WithSignaturePairwiseConsistencyTest< DL_PrivateKey_GFP< DL_GroupParameters_DSA >, DSA2< SHA1 > > PrivateKey
 

Detailed Description

template<class H>
class DSA2< H >

DSA signature scheme.

Template Parameters
HHashTransformation derived class

The class is named DSA2 instead of DSA for backwards compatibility because DSA was a non-template class.

DSA default method GenerateRandom uses a 2048-bit modulus and a 224-bit subgoup by default. The modulus can be changed using the following code:

 DSA::PrivateKey privateKey;
 privateKey.GenerateRandomWithKeySize(prng, 2048);

The subgroup order can be changed using the following code:

 AlgorithmParameters params = MakeParameters
   (Name::ModulusSize(), 2048)
   (Name::SubgroupOrderSize(), 256);

 DSA::PrivateKey privateKey;
 privateKey.GenerateRandom(prng, params);
See also
DSA, as specified in FIPS 186-3, Digital Signature Algorithm on the wiki, and NameValuePairs on the wiki.
Since
Crypto++ 1.0 for DSA, Crypto++ 5.6.2 for DSA2, Crypto++ 6.1 for 2048-bit modulus.

Definition at line 824 of file gfpcrypt.h.

Member Function Documentation

◆ StaticAlgorithmName()

template<class H >
static std::string DSA2< H >::StaticAlgorithmName ( )
inlinestatic

Definition at line 832 of file gfpcrypt.h.


The documentation for this class was generated from the following file: