Skip to content

openssl compat errors and mldsa oid fix#10785

Open
stenslae wants to merge 1 commit into
wolfSSL:masterfrom
stenslae:ml-dsa-ssl-error-queue-fix
Open

openssl compat errors and mldsa oid fix#10785
stenslae wants to merge 1 commit into
wolfSSL:masterfrom
stenslae:ml-dsa-ssl-error-queue-fix

Conversation

@stenslae

@stenslae stenslae commented Jun 25, 2026

Copy link
Copy Markdown
Member

Description

  • Fix 1: verifyX509orX509REQ() in src/x509.c: add ML-DSA case

WC_EVP_PKEY_DILITHIUM was missing from the wolfSSL_X509 verifying switch statement that determines signature OID, so any call with an ML-DSA public key returned WOLFSSL_FATAL_ERROR immediately, with no attempt at actual verification. Adds a WC_EVP_PKEY_DILITHIUM case guarded by WOLFSSL_HAVE_MLDSA that sets type = x509->pubKeyOID.

  • Fix 2: wolfSSL_ERR_get_error / wolfSSL_ERR_peek_last_error / wolfSSL_ERR_peek_last_error_line in src/ssl.c: return 0 when error queue not compiled in

When WOLFSSL_HAVE_ERROR_QUEUE is not defined, all three functions returned (unsigned long)(0 - NOT_COMPILED_IN) (= 174), a non-zero value. This is non-OpenSSL-compatible, so changed all three #else branches to return 0.

@stenslae stenslae self-assigned this Jun 25, 2026

@wolfSSL-Fenrir-bot wolfSSL-Fenrir-bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fenrir Automated Review — PR #10785

Scan targets checked: wolfssl-bugs, wolfssl-src

No new issues found in the changed files. ✅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants