Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

dsa.h File Reference

#include "pubkey.h"
#include "modexppc.h"
#include "sha.h"
#include <limits.h>

Go to the source code of this file.

Compounds

class  DSAPrivateKey
class  GDSADigestSigner
class  GDSADigestVerifier
class  GDSASigner
class  GDSAVerifier

Typedefs

typedef GDSAVerifier<SHADSAPublicKey
 DSA. More...


Enumerations

enum  DSASignatureFormat { DSA_P1363, DSA_DER, DSA_OPENPGP }

Functions

unsigned int DSAConvertSignatureFormat (byte *buffer,unsigned int bufferSize,DSASignatureFormat toFormat,const byte *signature,unsigned int signatureLen,DSASignatureFormat fromFormat)
 This function converts between these formats, and returns length of signature in the target format. More...

bool GenerateDSAPrimes (byte *seed,unsigned int seedLength,int &counter,Integer &p,unsigned int primeLength,Integer &q)
 Generate DSA primes according to NIST standard. More...


Variables

const int MIN_DSA_PRIME_LENGTH = 512
const int MAX_DSA_PRIME_LENGTH = 1024


Detailed Description

Definition in file dsa.h.


Typedef Documentation

typedef GDSAVerifier< SHA > DSAPublicKey
 

DSA.

Definition at line 161 of file dsa.h.


Enumeration Type Documentation

enum DSASignatureFormat
 

The DSA signature format used by Crypto++ is as defined by IEEE P1363. Java uses the DER format, and OpenPGP uses the OpenPGP format.

Definition at line 17 of file dsa.h.


Function Documentation

unsigned int DSAConvertSignatureFormat ( byte * buffer,
unsigned int bufferSize,
DSASignatureFormat toFormat,
const byte * signature,
unsigned int signatureLen,
DSASignatureFormat fromFormat )
 

This function converts between these formats, and returns length of signature in the target format.

If toFormat == DSA_P1363, bufferSize must equal publicKey.SignatureLength()

Definition at line 12 of file dsa.cpp.

bool GenerateDSAPrimes ( byte * seed,
unsigned int seedLength,
int & counter,
Integer & p,
unsigned int primeLength,
Integer & q )
 

Generate DSA primes according to NIST standard.

both seedLength and primeLength are in bits, but seedLength should be a multiple of 8

Definition at line 295 of file dsa.cpp.


Variable Documentation

const int MAX_DSA_PRIME_LENGTH = 1024
 

Definition at line 130 of file dsa.h.

const int MIN_DSA_PRIME_LENGTH = 512
 

Definition at line 129 of file dsa.h.


Generated at Mon Jan 15 01:16:39 2001 for Crypto++ by doxygen1.2.4 written by Dimitri van Heesch, © 1997-2000