wolfSSL / wolfssl

The wolfSSL library is a small, fast, portable implementation of TLS/SSL for embedded devices to the cloud. wolfSSL supports up to TLS 1.3 and DTLS 1.3!
https://www.wolfssl.com
GNU General Public License v2.0
2.31k stars 823 forks source link

Fixes for WolfSSL ML-DSA implementation #7677

Closed Frauschi closed 3 months ago

Frauschi commented 3 months ago

Hi everybody,

After trying the new WolfSSL implementation of ML-DSA, I found some problems. On the one hand, interoperability has been lost to the OQS project due to different OIDs etc. (WolfSSL had ML-DSA implemented following the NIST draft, which is incompatible with the Round 3 version, but the OIDs have still been the Round 3 ones from OQS). Furthermore, private key files in PEM/DER format stored on disk typically contain both the private and the public key. The parsing code was unable to properly handle those keys, resulting in failing private key loading.

Both identified issues are fixed with the changes in this commit:

Tested using in-house TLS client and server applications using WolfSSL and with OpenSSL s_client / s_server applications with OQS provider (current master branch), always using private key files generated by OQS.

wolfSSL-Bot commented 3 months ago

Can one of the admins verify this patch?

dgarske commented 3 months ago

Okay to test

dgarske commented 3 months ago

Retest this please

dgarske commented 3 months ago

Contributor agreement on file. Okay to merge.