@@ -372,6 +372,34 @@ def generate_libwolfssl():
372372
373373if RSA_ENABLED :
374374 _cdef += """
375+ static const int WC_RSA_PKCSV15_PAD;
376+ static const int WC_RSA_OAEP_PAD;
377+ static const int WC_RSA_PSS_PAD;
378+ static const int WC_RSA_NO_PAD;
379+
380+ static const int WC_MGF1NONE;
381+ static const int WC_MGF1SHA1;
382+ static const int WC_MGF1SHA224;
383+ static const int WC_MGF1SHA256;
384+ static const int WC_MGF1SHA384;
385+ static const int WC_MGF1SHA512;
386+
387+ static const int WC_HASH_TYPE_NONE;
388+ static const int WC_HASH_TYPE_MD2;
389+ static const int WC_HASH_TYPE_MD4;
390+ static const int WC_HASH_TYPE_MD5;
391+ static const int WC_HASH_TYPE_SHA;
392+ static const int WC_HASH_TYPE_SHA224;
393+ static const int WC_HASH_TYPE_SHA256;
394+ static const int WC_HASH_TYPE_SHA384;
395+ static const int WC_HASH_TYPE_SHA512;
396+ static const int WC_HASH_TYPE_MD5_SHA;
397+ static const int WC_HASH_TYPE_SHA3_224;
398+ static const int WC_HASH_TYPE_SHA3_256;
399+ static const int WC_HASH_TYPE_SHA3_384;
400+ static const int WC_HASH_TYPE_SHA3_512;
401+ static const int WC_HASH_TYPE_BLAKE2B;
402+ static const int WC_HASH_TYPE_BLAKE2S;
375403 typedef struct {...; } RsaKey;
376404
377405 int wc_InitRsaKey(RsaKey* key, void*);
@@ -392,37 +420,9 @@ def generate_libwolfssl():
392420 byte* out, word32 outLen, RsaKey* key, int type,
393421 enum wc_HashType hash, int mgf, byte* label, word32 labelSz);
394422 """
423+
395424 if RSA_PSS_ENABLED :
396425 _cdef += """
397- static const int WC_RSA_PKCSV15_PAD;
398- static const int WC_RSA_OAEP_PAD;
399- static const int WC_RSA_PSS_PAD;
400- static const int WC_RSA_NO_PAD;
401-
402- static const int WC_MGF1NONE;
403- static const int WC_MGF1SHA1;
404- static const int WC_MGF1SHA224;
405- static const int WC_MGF1SHA256;
406- static const int WC_MGF1SHA384;
407- static const int WC_MGF1SHA512;
408-
409- static const int WC_HASH_TYPE_NONE;
410- static const int WC_HASH_TYPE_MD2;
411- static const int WC_HASH_TYPE_MD4;
412- static const int WC_HASH_TYPE_MD5;
413- static const int WC_HASH_TYPE_SHA;
414- static const int WC_HASH_TYPE_SHA224;
415- static const int WC_HASH_TYPE_SHA256;
416- static const int WC_HASH_TYPE_SHA384;
417- static const int WC_HASH_TYPE_SHA512;
418- static const int WC_HASH_TYPE_MD5_SHA;
419- static const int WC_HASH_TYPE_SHA3_224;
420- static const int WC_HASH_TYPE_SHA3_256;
421- static const int WC_HASH_TYPE_SHA3_384;
422- static const int WC_HASH_TYPE_SHA3_512;
423- static const int WC_HASH_TYPE_BLAKE2B;
424- static const int WC_HASH_TYPE_BLAKE2S;
425-
426426 int wc_RsaPSS_Sign(const byte* in, word32 inLen, byte* out, word32 outLen,
427427 enum wc_HashType hash, int mgf, RsaKey* key, WC_RNG* rng);
428428 int wc_RsaPSS_Verify(byte* in, word32 inLen, byte* out, word32 outLen,
0 commit comments