Classes for the DSA signature algorithm. More...
Go to the source code of this file.
Enumerations | |
| enum | DSASignatureFormat { DSA_P1363, DSA_DER, DSA_OPENPGP } |
DSA Signature Format. More... | |
Functions | |
| size_t | DSAConvertSignatureFormat (byte *buffer, size_t bufferSize, DSASignatureFormat toFormat, const byte *signature, size_t signatureLen, DSASignatureFormat fromFormat) |
| Converts between signature encoding formats. | |
Classes for the DSA signature algorithm.
Definition in file dsa.h.
| enum DSASignatureFormat |
DSA Signature Format.
The DSA signature format used by Crypto++ is as defined by IEEE P1363. Java nad .Net use the DER format, and OpenPGP uses the OpenPGP format.
| size_t DSAConvertSignatureFormat | ( | byte * | buffer, | |
| size_t | bufferSize, | |||
| DSASignatureFormat | toFormat, | |||
| const byte * | signature, | |||
| size_t | signatureLen, | |||
| DSASignatureFormat | fromFormat | |||
| ) |
Converts between signature encoding formats.
| buffer | byte buffer for the converted signature encoding | |
| bufferSize | the length of the converted signature encoding buffer | |
| toFormat | the source signature format | |
| signature | byte buffer for the existing signature encoding | |
| signatureLen | the length of the existing signature encoding buffer | |
| fromFormat | the source signature format |
This function converts between these formats, and returns length of signature in the target format. If toFormat == DSA_P1363, then bufferSize must equal publicKey.SignatureLength()
Definition at line 15 of file dsa.cpp.
References Integer::BERDecode(), Integer::Decode(), Integer::DEREncode(), DSA_DER, DSA_OPENPGP, DSA_P1363, Integer::Encode(), Integer::OpenPGPDecode(), and Integer::OpenPGPEncode().
1.6.1