mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-07-30 02:37:28 +02:00
no priv or pub in dhKey struct in FIPS
This commit is contained in:
@ -4411,7 +4411,10 @@ int wc_DhKeyDecode(const byte* input, word32* inOutIdx, DhKey* key, word32 inSz)
|
||||
return ASN_PARSE_E;
|
||||
|
||||
#if defined(WOLFSSL_QT) || defined(OPENSSL_ALL)
|
||||
#if !defined(HAVE_FIPS) || \
|
||||
( defined(HAVE_FIPS_VERSION) && (HAVE_FIPS_VERSION > 2) )
|
||||
temp = *inOutIdx;
|
||||
#endif /* !HAVE_FIPS || HAVE_FIPS_VERSION > 2 */
|
||||
#endif
|
||||
|
||||
/* Assume input started after 1.2.840.113549.1.3.1 dhKeyAgreement */
|
||||
@ -4421,6 +4424,8 @@ int wc_DhKeyDecode(const byte* input, word32* inOutIdx, DhKey* key, word32 inSz)
|
||||
}
|
||||
|
||||
#if defined(WOLFSSL_QT) || defined(OPENSSL_ALL)
|
||||
#if !defined(HAVE_FIPS) || \
|
||||
( defined(HAVE_FIPS_VERSION) && (HAVE_FIPS_VERSION > 2) )
|
||||
/* If ASN_DH_KEY_E: Check if input started at beginning of key */
|
||||
if (ret == ASN_DH_KEY_E) {
|
||||
/* rewind back to after the first sequence */
|
||||
@ -4465,6 +4470,7 @@ int wc_DhKeyDecode(const byte* input, word32* inOutIdx, DhKey* key, word32 inSz)
|
||||
ret = 0;
|
||||
}
|
||||
}
|
||||
#endif /* !HAVE_FIPS || HAVE_FIPS_VERSION > 2 */
|
||||
#endif /* WOLFSSL_QT || OPENSSL_ALL */
|
||||
|
||||
WOLFSSL_MSG("wc_DhKeyDecode Success");
|
||||
|
Reference in New Issue
Block a user