
| My Project
    | 
| Functions | |
| int | wc_InitDsaKey (DsaKey *key) | 
| This function initializes a DsaKey object in order to use it for authentication via the Digital Signature Algorithm (DSA).  More... | |
| void | wc_FreeDsaKey (DsaKey *key) | 
| This function frees a DsaKey object after it has been used.  More... | |
| int | wc_DsaSign (const byte *digest, byte *out, DsaKey *key, WC_RNG *rng) | 
| This function signs the input digest and stores the result in the output buffer, out.  More... | |
| int | wc_DsaVerify (const byte *digest, const byte *sig, DsaKey *key, int *answer) | 
| This function verifies the signature of a digest, given a private key. It stores whether the key properly verifies in the answer parameter, with 1 corresponding to a successful verification, and 0 corresponding to failed verification.  More... | |
| int | wc_DsaPublicKeyDecode (const byte *input, word32 *inOutIdx, DsaKey *key, word32 inSz) | 
| This function decodes a DER formatted certificate buffer containing a DSA public key, and stores the key in the given DsaKey structure. It also sets the inOutIdx parameter according to the length of the input read.  More... | |
| int | wc_DsaPrivateKeyDecode (const byte *input, word32 *inOutIdx, DsaKey *key, word32 inSz) | 
| This function decodes a DER formatted certificate buffer containing a DSA private key, and stores the key in the given DsaKey structure. It also sets the inOutIdx parameter according to the length of the input read.  More... | |
| int | wc_DsaKeyToDer (DsaKey *key, byte *output, word32 inLen) | 
| Convert DsaKey key to DER format, write to output (inLen), return bytes written.  More... | |
| int | wc_MakeDsaKey (WC_RNG *rng, DsaKey *dsa) | 
| Create a DSA key.  More... | |
| int | wc_MakeDsaParameters (WC_RNG *rng, int modulus_size, DsaKey *dsa) | 
| FIPS 186-4 defines valid for modulus_size values as (1024, 160) (2048, 256) (3072, 256)  More... | |
| int wc_DsaKeyToDer | ( | DsaKey * | key, | 
| byte * | output, | ||
| word32 | inLen | ||
| ) | 
Convert DsaKey key to DER format, write to output (inLen), return bytes written.
| key | Pointer to DsaKey structure to convert. | 
| output | Pointer to output buffer for converted key. | 
| inLen | Length of key input. | 
Example
| int wc_DsaPrivateKeyDecode | ( | const byte * | input, | 
| word32 * | inOutIdx, | ||
| DsaKey * | key, | ||
| word32 | inSz | ||
| ) | 
This function decodes a DER formatted certificate buffer containing a DSA private key, and stores the key in the given DsaKey structure. It also sets the inOutIdx parameter according to the length of the input read.
| input | pointer to the buffer containing the DER formatted DSA private key | 
| inOutIdx | pointer to an integer in which to store the final index of the certificate read | 
| key | pointer to the DsaKey structure in which to store the private key | 
| inSz | size of the input buffer | 
Example
| int wc_DsaPublicKeyDecode | ( | const byte * | input, | 
| word32 * | inOutIdx, | ||
| DsaKey * | key, | ||
| word32 | inSz | ||
| ) | 
This function decodes a DER formatted certificate buffer containing a DSA public key, and stores the key in the given DsaKey structure. It also sets the inOutIdx parameter according to the length of the input read.
| input | pointer to the buffer containing the DER formatted DSA public key | 
| inOutIdx | pointer to an integer in which to store the final index of the certificate read | 
| key | pointer to the DsaKey structure in which to store the public key | 
| inSz | size of the input buffer | 
Example
| int wc_DsaSign | ( | const byte * | digest, | 
| byte * | out, | ||
| DsaKey * | key, | ||
| WC_RNG * | rng | ||
| ) | 
This function signs the input digest and stores the result in the output buffer, out.
| digest | pointer to the hash to sign | 
| out | pointer to the buffer in which to store the signature | 
| key | pointer to the initialized DsaKey structure with which to generate the signature | 
| rng | pointer to an initialized RNG to use with the signature generation | 
Example
| int wc_DsaVerify | ( | const byte * | digest, | 
| const byte * | sig, | ||
| DsaKey * | key, | ||
| int * | answer | ||
| ) | 
This function verifies the signature of a digest, given a private key. It stores whether the key properly verifies in the answer parameter, with 1 corresponding to a successful verification, and 0 corresponding to failed verification.
| digest | pointer to the digest containing the subject of the signature | 
| sig | pointer to the buffer containing the signature to verify | 
| key | pointer to the initialized DsaKey structure with which to verify the signature | 
| answer | pointer to an integer which will store whether the verification was successful | 
Example
| void wc_FreeDsaKey | ( | DsaKey * | key | ) | 
This function frees a DsaKey object after it has been used.
| key | pointer to the DsaKey structure to free | 
Example
| int wc_InitDsaKey | ( | DsaKey * | key | ) | 
This function initializes a DsaKey object in order to use it for authentication via the Digital Signature Algorithm (DSA).
| key | pointer to the DsaKey structure to initialize | 
Example
| int wc_MakeDsaKey | ( | WC_RNG * | rng, | 
| DsaKey * | dsa | ||
| ) | 
Create a DSA key.
| rng | Pointer to WC_RNG structure. | 
| dsa | Pointer to DsaKey structure. | 
Example
| int wc_MakeDsaParameters | ( | WC_RNG * | rng, | 
| int | modulus_size, | ||
| DsaKey * | dsa | ||
| ) | 
FIPS 186-4 defines valid for modulus_size values as (1024, 160) (2048, 256) (3072, 256)
| rng | pointer to wolfCrypt rng. | 
| modulus_size | 1024, 2048, or 3072 are valid values. | 
| dsa | Pointer to a DsaKey structure. | 
Example