18 #ifndef __CRYPTO_INTERFACE_DSA_HEADER__ 19 #define __CRYPTO_INTERFACE_DSA_HEADER__ 79 MOC_DSA(hwAccelDescr hwAccelCtx)
112 DSAKey **pp_dsaDescr,
153 MOC_DSA(hwAccelDescr hwAccelCtx) randomContext* pFipsRngCtx,
191 MOC_DSA(hwAccelDescr hwAccelCtx)
192 const DSAKey *p_dsaDescr,
194 ubyte4 *pRetKeyBlobLength
223 MOC_DSA(hwAccelDescr hwAccelCtx)
224 DSAKey **pp_RetNewDsaDescr,
225 const ubyte *pKeyBlob,
254 MOC_DSA(hwAccelDescr hwAccelCtx)
279 MOC_DSA(hwAccelDescr hwAccelCtx)
281 sbyte4* cipherTextLen
306 MOC_DSA(hwAccelDescr hwAccelCtx)
355 MOC_DSA(hwAccelDescr hwAccelCtx) randomContext* pFipsRngCtx,
359 DSAHashType hashType,
398 MOC_DSA(hwAccelDescr hwAccelCtx) randomContext* pFipsRngCtx,
446 MOC_DSA(hwAccelDescr hwAccelCtx) randomContext* pFipsRngCtx,
450 DSAHashType hashType,
490 MOC_DSA(hwAccelDescr hwAccelCtx) randomContext *pRngCtx,
537 MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey *pKey,
544 intBoolean *pIsGoodSignature,
568 MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey *pKey,
569 MDsaKeyTemplatePtr pTemplate
595 MOC_DSA(hwAccelDescr hwAccelCtx)
597 MDsaKeyTemplatePtr pTemplate,
621 MDsaKeyTemplatePtr pTemplate
655 randomContext *pRandomContext, ubyte **ppH, ubyte4 *pHLen, vlong **ppVlongQueue);
693 ubyte **ppR, ubyte4 *pRLen, ubyte **ppS, ubyte4 *pSLen, vlong **ppVlongQueue);
731 ubyte *pR, ubyte4 rLen, ubyte *pS, ubyte4 sLen,
732 intBoolean *pIsGoodSignature, vlong **ppVlongQueue);
756 MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey *pKey,
757 intBoolean *pIsValid,
758 vlong **ppVlongQueue);
782 MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey *pKey,
783 intBoolean *pIsValid,
784 vlong **ppVlongQueue);
809 MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey *pKey,
810 intBoolean *pIsValid,
811 vlong **ppVlongQueue);
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_getCipherTextLength(MOC_DSA(hwAccelDescr hwAccelCtx) const DSAKey *pKey, sbyte4 *cipherTextLen)
Gets the length in bytes of the DSA prime p.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_generatePQ(MOC_DSA(hwAccelDescr hwAccelCtx) randomContext *pFipsRngCtx, DSAKey *p_dsaDescr, ubyte4 L, ubyte4 Nin, DSAHashType hashType, ubyte4 *pRetC, ubyte *pRetSeed, vlong **ppVlongQueue)
Generates the DSA domain parameters p and q.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_generateKeyAux2(MOC_DSA(hwAccelDescr hwAccelCtx) randomContext *pFipsRngCtx, DSAKey *p_dsaDescr, ubyte4 keySize, ubyte4 qSize, DSAHashType hashType, vlong **ppVlongQueue)
Generate DSA key pair (private and public keys) and associated parameters with flexibility to set the...
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_computeSignature2Aux(MOC_DSA(hwAccelDescr hwAccelCtx) RNGFun rngfun, void *pRngArg, DSAKey *pKey, ubyte *pM, ubyte4 mLen, ubyte **ppR, ubyte4 *pRLen, ubyte **ppS, ubyte4 *pSLen, vlong **ppVlongQueue)
Computes the DSA signature after message truncation.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_computeSignatureAux(MOC_DSA(hwAccelDescr hwAccelCtx) randomContext *pRngCtx, DSAKey *pKey, ubyte *pM, ubyte4 mLen, intBoolean *pVerify, ubyte **ppR, ubyte4 *pRLen, ubyte **ppS, ubyte4 *pSLen, vlong **ppVlongQueue)
Computes the DSA signature.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_freeKey(DSAKey **pp_dsaDescr, vlong **ppVlongQueue)
Free (delete) a DSA key.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_generateRandomGAux(MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey *pKey, randomContext *pRandomContext, ubyte **ppH, ubyte4 *pHLen, vlong **ppVlongQueue)
Randomly computes a generator g of the cyclic group of order q.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_extractKeyBlob(MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey **pp_RetNewDsaDescr, const ubyte *pKeyBlob, ubyte4 keyBlobLength)
Get DSA key data structure converted from DSA key blob.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_cloneKey(MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey **ppNew, const DSAKey *pSrc)
Clone (copy) a DSA key.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_verifySignature2Aux(MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey *pKey, ubyte *pM, ubyte4 mLen, ubyte *pR, ubyte4 rLen, ubyte *pS, ubyte4 sLen, intBoolean *pIsGoodSignature, vlong **ppVlongQueue)
Verifies a DSA signature after message truncation.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_getKeyParametersAlloc(MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey *pKey, MDsaKeyTemplatePtr pTemplate, ubyte keyType)
Gets DSA key and domain parameters.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_freeKeyTemplate(DSAKey *pKey, MDsaKeyTemplatePtr pTemplate)
Frees the fields within a key template.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_verifyPublicKey(MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey *pKey, intBoolean *pIsValid, vlong **ppVlongQueue)
Validates a DSA public key.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_makeKeyBlob(MOC_DSA(hwAccelDescr hwAccelCtx) const DSAKey *p_dsaDescr, ubyte *pKeyBlob, ubyte4 *pRetKeyBlobLength)
Get DSA key blob converted from DSA key data structure.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_setKeyParametersAux(MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey *pKey, MDsaKeyTemplatePtr pTemplate)
Sets DSA key and domain parameters.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_generateKeyAux(MOC_DSA(hwAccelDescr hwAccelCtx) randomContext *pFipsRngCtx, DSAKey *p_dsaDescr, ubyte4 keySize, vlong **ppVlongQueue)
Generate DSA key pair (private and public keys) and associated parameters.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_verifyPrivateKey(MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey *pKey, intBoolean *pIsValid, vlong **ppVlongQueue)
Validates a DSA private key.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_verifyKeyPair(MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey *pKey, intBoolean *pIsValid, vlong **ppVlongQueue)
Validates a DSA private/public key pair.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_computeKeyPair(MOC_DSA(hwAccelDescr hwAccelCtx) randomContext *pFipsRngCtx, DSAKey *p_dsaDescr, vlong **ppVlongQueue)
Generate DSA key pair (but not their associated parameters).
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_getSignatureLength(MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey *pKey, ubyte4 *pSigLen)
Gets the length in bytes of the DSA prime q and therefore the signature components r and s...
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_equalKey(MOC_DSA(hwAccelDescr hwAccelCtx) const DSAKey *pKey1, const DSAKey *pKey2, byteBoolean *pResult)
Determine whether two DSA keys are equal.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_createKey(DSAKey **pp_dsaDescr)
Create memory storage for a DSA key.
MOC_EXTERN MSTATUS CRYPTO_INTERFACE_DSA_verifySignatureAux(MOC_DSA(hwAccelDescr hwAccelCtx) DSAKey *pKey, ubyte *pM, ubyte4 mLen, ubyte *pR, ubyte4 rLen, ubyte *pS, ubyte4 sLen, intBoolean *pIsGoodSignature, vlong **ppVlongQueue)
Verifies a DSA signature.