mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2026-07-09 14:50:50 +02:00
Merge pull request #10855 from philljj/misc_fixes
wolfcrypt: fix several redefinition of typedef errors.
This commit is contained in:
@@ -299,7 +299,10 @@ wc_static_assert(SLHDSA_MAX_MSG_SZ <= 255);
|
||||
*/
|
||||
|
||||
/* HashAddress type. */
|
||||
#ifndef WC_HASHADDRESS_TYPE_DEFINED
|
||||
typedef word32 HashAddress[8];
|
||||
#define WC_HASHADDRESS_TYPE_DEFINED
|
||||
#endif
|
||||
|
||||
/* Encode a HashAddress.
|
||||
*
|
||||
|
||||
@@ -362,7 +362,7 @@ enum {
|
||||
#define MLKEM_PRF_T wc_Shake
|
||||
|
||||
/* ML-KEM key. */
|
||||
typedef struct MlKemKey {
|
||||
struct MlKemKey {
|
||||
/* Type of key: WC_ML_KEM_512, WC_ML_KEM_768, WC_ML_KEM_1024 */
|
||||
int type;
|
||||
#ifdef WOLFSSL_MLKEM_DYNAMIC_KEYS
|
||||
@@ -418,8 +418,12 @@ typedef struct MlKemKey {
|
||||
sword16* a;
|
||||
#endif
|
||||
#endif
|
||||
} MlKemKey;
|
||||
};
|
||||
|
||||
#ifndef WC_MLKEMKEY_TYPE_DEFINED
|
||||
typedef struct MlKemKey MlKemKey;
|
||||
#define WC_MLKEMKEY_TYPE_DEFINED
|
||||
#endif
|
||||
|
||||
WOLFSSL_API MlKemKey* wc_MlKemKey_New(int type, void* heap, int devId);
|
||||
WOLFSSL_API int wc_MlKemKey_Delete(MlKemKey* key, MlKemKey** key_p);
|
||||
|
||||
@@ -601,7 +601,7 @@ typedef struct SlhDsaParameters {
|
||||
#endif
|
||||
|
||||
/* SLH-DSA key data and state. */
|
||||
typedef struct SlhDsaKey {
|
||||
struct SlhDsaKey {
|
||||
/* Parameters. */
|
||||
const SlhDsaParameters* params;
|
||||
/* Flags of the key. */
|
||||
@@ -654,7 +654,12 @@ typedef struct SlhDsaKey {
|
||||
} sha2;
|
||||
#endif
|
||||
} hash;
|
||||
} SlhDsaKey;
|
||||
};
|
||||
|
||||
#ifndef WC_SLHDSAKEY_TYPE_DEFINED
|
||||
typedef struct SlhDsaKey SlhDsaKey;
|
||||
#define WC_SLHDSAKEY_TYPE_DEFINED
|
||||
#endif
|
||||
|
||||
WOLFSSL_API int wc_SlhDsaKey_Init(SlhDsaKey* key, enum SlhDsaParam param,
|
||||
void* heap, int devId);
|
||||
|
||||
@@ -307,7 +307,10 @@ typedef enum wc_XmssRc (*wc_xmss_read_private_key_cb)(byte* priv, word32 privSz,
|
||||
|
||||
|
||||
/* Type for hash address. */
|
||||
#ifndef WC_HASHADDRESS_TYPE_DEFINED
|
||||
typedef word32 HashAddress[8];
|
||||
#define WC_HASHADDRESS_TYPE_DEFINED
|
||||
#endif
|
||||
|
||||
/* XMSS/XMSS^MT fixed parameters. */
|
||||
typedef struct XmssParams {
|
||||
|
||||
Reference in New Issue
Block a user