Recently, both OpenSSL 3.5 and wolfSSL 5.8.0 have been released. We thought we’d run some benchmarks on an x86_64 Linux PC.
Note: output has been edited for brevity and clarity.
OpenSSL
Configuration and build:
$ ./Configure $ make all
Benchmarking Output:
47317 ML-KEM-512 KEM keygen ops in 0.99s 72114 ML-KEM-512 KEM encaps ops in 1.00s 46625 ML-KEM-512 KEM decaps ops in 1.00s 31811 ML-KEM-768 KEM keygen ops in 1.00s 55855 ML-KEM-768 KEM encaps ops in 0.99s 35390 ML-KEM-768 KEM decaps ops in 1.00s 20942 ML-KEM-1024 KEM keygen ops in 1.00s 42164 ML-KEM-1024 KEM encaps ops in 0.99s 27043 ML-KEM-1024 KEM decaps ops in 1.00s
wolfSSL
Configuration and build:
$ ./configure --enable-mlkem=yes,cache-a --enable-dilithium \ --enable-all-asm $ make all
Benchmarking Output:
ML-KEM 512 128 key gen 293900 ops took 1.000 sec ML-KEM 512 128 encap 271900 ops took 1.000 sec ML-KEM 512 128 decap 237300 ops took 1.000 sec ML-KEM 768 192 key gen 163900 ops took 1.000 sec ML-KEM 768 192 encap 152500 ops took 1.000 sec ML-KEM 768 192 decap 200700 ops took 1.000 sec ML-KEM 1024 256 key gen 109200 ops took 1.000 sec ML-KEM 1024 256 encap 106200 ops took 1.000 sec ML-KEM 1024 256 decap 143600 ops took 1.001 sec
Analysis & Conclusions
It can be observed that wolfSSL is faster than OpenSSL by a wide margin at every operation and parameter set. Here at wolfSSL, we are extremely proud of our long tradition of excellence when it comes to efficiency and performance.
Now, it is worth pointing out that this is not an apples-to-apples comparison. The build configuration for wolfSSL does indicate that assembly optimizations are enabled while to date, OpenSSL does not have such optimizations. Similarly, we are enabling the “Cache A” optimization which is described as:
Stores the matrix A during key generation for use in encapsulation when performing decapsulation. The key is 8KB larger but decapsulation is significantly faster. Turn on when performing make key and decapsulation with the same object.
We would be happy to re-run these comparisons once OpenSSL has such optimizations enabled.
If you have questions about any of the above, please contact us at facts@wolfSSL.com or call us at +1 425 245 8247.
Download wolfSSL Now