@@ -17176,11 +17176,12 @@ int test_mldsa_x509_pubkey_sigtype(void)
1717617176 !defined(NO_CERTS) && !defined(NO_FILESYSTEM)
1717717177 static const struct {
1717817178 const char* pem_path;
17179- word32 expected_sig_oid; /* CTC_ML_DSA_LEVEL* */
17179+ int expected_sig_oid; /* CTC_ML_DSA_LEVEL* (stored as int,
17180+ * same bit pattern as word32 return) */
1718017181 } cases[] = {
17181- { "./certs/mldsa/mldsa44-cert.pem", CTC_ML_DSA_LEVEL2 },
17182- { "./certs/mldsa/mldsa65-cert.pem", CTC_ML_DSA_LEVEL3 },
17183- { "./certs/mldsa/mldsa87-cert.pem", CTC_ML_DSA_LEVEL5 },
17182+ { "./certs/mldsa/mldsa44-cert.pem", (int) CTC_ML_DSA_LEVEL2 },
17183+ { "./certs/mldsa/mldsa65-cert.pem", (int) CTC_ML_DSA_LEVEL3 },
17184+ { "./certs/mldsa/mldsa87-cert.pem", (int) CTC_ML_DSA_LEVEL5 },
1718417185 };
1718517186 int i;
1718617187 int n = (int)(sizeof(cases) / sizeof(cases[0]));
@@ -17199,7 +17200,7 @@ int test_mldsa_x509_pubkey_sigtype(void)
1719917200
1720017201 /* wolfSSL_X509_get_signature_type() must return the ML-DSA OID sum */
1720117202 sig_oid = wolfSSL_X509_get_signature_type(x509);
17202- ExpectIntEQ((word32) sig_oid, cases[i].expected_sig_oid);
17203+ ExpectIntEQ(sig_oid, cases[i].expected_sig_oid);
1720317204
1720417205 /* wolfSSL_X509_get_pubkey() must succeed */
1720517206 ExpectNotNull(pkey = wolfSSL_X509_get_pubkey(x509));
0 commit comments