Crypto Benchmark on ESP32 MCU
Tensilica Xtensa LX6 @ 240 MHz

This benchmark conducted on ESP32-DevKitC Development Board will help you in qualifying performance of CycloneCRYPTO (Cryptography library), CycloneSSL (TLS 1.3 & DTLS 1.2 library), CycloneSSH (SSH library with SCP & SFTP protocols), CycloneIPSEC (IPsec/IKEv2 library) and CycloneTCP (TCP/IPv4/IPv6 stack with secure protocols like HTTPS, FTPS, MQTTS, Secure WebSocket, Secure CoAP, Secure Modbus/TCP, SNMPv3...) running on Espressif ESP32 microcontroller.

ESP32 MCU also includes crypto hardware acceleration. In the following comparison charts, both hardware and software performance are presented in the relevant sections.

Cipher Algorithms

ESP32 @ 240 MHz

  • Benchmark generated with CycloneCRYPTO 2.5.0
  • Compiled using GCC with optimization level 3
AlgorithmEncryption
(Software)
Decryption
(Software)
Encryption
(Hardware)
Decryption
(Hardware)
3DES-CBC0.563 MB/s0.557 MB/s--
3DES-CTR0.565 MB/s0.565 MB/s--
AES128-CBC1.953 MB/s1.915 MB/s10 MB/s11.363 MB/s
AES192-CBC1.689 MB/s1.658 MB/s9.708 MB/s11.363 MB/s
AES256-CBC1.488 MB/s1.464 MB/s9.708 MB/s11.363 MB/s
AES128-CTR1.984 MB/s1.984 MB/s10.204 MB/s10.204 MB/s
AES192-CTR1.715 MB/s1.715 MB/s10 MB/s9.9 MB/s
AES256-CTR1.506 MB/s1.506 MB/s10 MB/s9.9 MB/s
SM4-CBC2.202 MB/s2.15 MB/s--
SM4-CTR2.237 MB/s2.242 MB/s--

AEAD Algorithms

ESP32 @ 240 MHz

  • Benchmark generated with CycloneCRYPTO 2.5.0
  • Compiled using GCC with optimization level 3
AlgorithmEncryption
(Software)
Decryption
(Software)
Encryption
(Hardware)
Decryption
(Hardware)
AES128-GCM1.25 MB/s1.245 MB/s1.808 MB/s1.805 MB/s
AES192-GCM1.135 MB/s1.131 MB/s1.785 MB/s1.776 MB/s
AES256-GCM1.038 MB/s1.036 MB/s1.773 MB/s1.769 MB/s
AES128-CCM1.005 MB/s1.007 MB/s2.036 MB/s2.04 MB/s
AES192-CCM0.862 MB/s0.863 MB/s1.968 MB/s1.98 MB/s
AES256-CCM0.754 MB/s0.755 MB/s1.941 MB/s1.949 MB/s
SM4-GCM1.347 MB/s1.344 MB/s--
SM4-CCM1.14 MB/s1.142 MB/s--
Ascon-AEAD1281.466 MB/s1.438 MB/s--
ChaCha20Poly13053.076 MB/s3.086 MB/s--

Hash Algorithms

ESP32 @ 240 MHz

  • Benchmark generated with CycloneCRYPTO 2.5.0
  • Compiled using GCC with optimization level 3
AlgorithmSpeed
(Software)
Speed
(Hardware)
MD513.513 MB/s-
SHA-12.531 MB/s28.571 MB/s
SHA-2242.173 MB/s-
SHA-2562.173 MB/s27.777 MB/s
SHA-3841.412 MB/s29.411 MB/s
SHA-5121.412 MB/s29.411 MB/s
SHA3-2241.017 MB/s-
SHA3-2560.961 MB/s-
SHA3-3840.738 MB/s-
SHA3-5120.513 MB/s-
SM32.105 MB/s-
Ascon-Hash2560.545 MB/s-

Signature Algorithms

ESP32 @ 240 MHz

  • Benchmark generated with CycloneCRYPTO 2.5.0
  • Compiled using GCC with optimization level 3
AlgorithmGeneration
(Software)
Verification
(Software)
Generation
(Hardware)
Verification
(Hardware)
RSA (1024 bits)96 ms13 ms34 ms18 ms
RSA (2048 bits)587 ms47 ms167 ms106 ms
RSA (3072 bits)1802 ms100 ms465 ms314 ms
RSA (4096 bits)4072 ms177 ms996 ms698 ms
DSA (1024 bits)58 ms117 ms28 ms57 ms
DSA (2048 bits)296 ms605 ms131 ms277 ms

EC Signature Algorithms

ESP32 @ 240 MHz

  • Benchmark generated with CycloneCRYPTO 2.5.0
  • Compiled using GCC with optimization level 3
AlgorithmGeneration
(Software)
Verification
(Software)
Generation
(Hardware)
Verification
(Hardware)
ECDSA (secp256r1)82 ms74 ms62 ms57 ms
ECDSA (secp384r1)219 ms207 ms135 ms124 ms
ECDSA (secp521r1)470 ms422 ms241 ms213 ms
ECDSA (brainpoolP256r1)161 ms162 ms134 ms134 ms
ECDSA (brainpoolP384r1)441 ms447 ms245 ms245 ms
ECDSA (brainpoolP512r1)939 ms965 ms437 ms440 ms
SM272 ms72 ms55 ms55 ms
EdDSA (Ed25519)29 ms28 ms--
EdDSA (Ed448)114 ms102 ms--

Key Exchange Algorithms

ESP32 @ 240 MHz

  • Benchmark generated with CycloneCRYPTO 2.5.0
  • Compiled using GCC with optimization level 3
AlgorithmPublic Key Generation
(Software)
Shared Secret Computation
(Software)
Public Key Generation
(Hardware)
Shared Secret Computation
(Hardware)
Diffie-Hellman (1024 bits)256 ms256 ms19 ms19 ms
Diffie-Hellman (2048 bits)1898 ms1898 ms106 ms106 ms

EC Key Exchange Algorithms

ESP32 @ 240 MHz

  • Benchmark generated with CycloneCRYPTO 2.5.0
  • Compiled using GCC with optimization level 3
AlgorithmPublic Key Generation
(Software)
Shared Secret Computation
(Software)
Public Key Generation
(Hardware)
Shared Secret Computation
(Hardware)
ECDH (secp256r1)71 ms70 ms54 ms54 ms
ECDH (secp384r1)191 ms190 ms121 ms121 ms
ECDH (secp521r1)404 ms404 ms209 ms209 ms
ECDH (brainpoolP256r1)148 ms148 ms124 ms123 ms
ECDH (brainpoolP384r1)409 ms409 ms228 ms228 ms
ECDH (brainpoolP512r1)869 ms869 ms407 ms406 ms
ECDH (SM2)72 ms71 ms55 ms54 ms
ECDH (X25519)17 ms16 ms--
ECDH (X448)58 ms58 ms--