Difference between revisions of "emCrypt"

From SEGGER Wiki
Jump to: navigation, search
m (Performance)
m (Performance)
Line 35: Line 35:
 
|-
 
|-
 
| EdDSA sign and verify || STM32F746 || CM7 || 200 MHz || No || Run from flash, data in internal RAM || [[EdDSA_Sign_Verify_STM32F746|Results]]
 
| EdDSA sign and verify || STM32F746 || CM7 || 200 MHz || No || Run from flash, data in internal RAM || [[EdDSA_Sign_Verify_STM32F746|Results]]
  +
|-
  +
| EdDSA sign and verify || STM32H753 || CM7 || 400 MHz || No || Run from flash, data in internal RAM || [[EdDSA_Sign_Verify_STM32H753|Results]]
 
|-
 
|-
 
| EdDSA sign and verify || AT91SAM9263 || ARM926 || 200 MHz || No || Run from SDRAM with cache enabled || [[EdDSA_Sign_Verify_AT91SAM9263|Results]]
 
| EdDSA sign and verify || AT91SAM9263 || ARM926 || 200 MHz || No || Run from SDRAM with cache enabled || [[EdDSA_Sign_Verify_AT91SAM9263|Results]]

Revision as of 11:05, 6 August 2019

emCrypt is a secure and efficient implementation of essential cryptographic algorithms specifically designed for embedded systems.

This wiki page explains and links to other articles providing information too specific for the user manual or product pages on www.segger.com

Performance

Cryptography benchmarks on real hardware
Benchmark Device Core Speed HW Accel Notes Link
ECDSA sign and verify STM32F072 CM0 48 MHz No Run from flash, data in internal RAM Results
ECDSA sign and verify R7FS124 CM0 24 MHz No Run from flash, data in internal RAM Results
ECDSA sign and verify MK66FN2M0 CM4 168 MHz No Run from flash, data in internal RAM Results
ECDSA sign and verify STM32F746 CM7 200 MHz No Run from flash, data in internal RAM Results
ECDSA sign and verify STM32H753 CM7 400 MHz No Run from flash, data in internal RAM Results
ECDSA sign and verify AT91SAM9263 ARM926 200 MHz No Run from SDRAM with cache enabled Results
EdDSA sign and verify MK66FN2M0 CM4 168 MHz No Run from flash, data in internal RAM Results
EdDSA sign and verify STM32F746 CM7 200 MHz No Run from flash, data in internal RAM Results
EdDSA sign and verify STM32H753 CM7 400 MHz No Run from flash, data in internal RAM Results
EdDSA sign and verify AT91SAM9263 ARM926 200 MHz No Run from SDRAM with cache enabled Results
Hash algorithms MK66FN2M0 CM4 168 MHz Yes Run from flash, data in internal RAM Results
Hash algorithms STM32F746 CM7 200 MHz No Run from flash, data in internal RAM Results
Hash algorithms STM32F756 CM7 200 MHz Yes Run from flash, data in internal RAM Results
Hash algorithms STM32H753 CM7 400 MHz Yes Run from flash, data in internal RAM Results
Hash algorithms AT91SAM9263 ARM926 200 MHz No Run from SDRAM with cache enabled Results
MAC algorithms STM32F746 CM7 200 MHz No Run from flash, data in internal RAM Results
MAC algorithms AT91SAM9263 ARM926 200 MHz No Run from SDRAM with cache enabled Results
RSA (ModExp) AT91SAM9263 ARM926 200 MHz No Run from SDRAM with cache enabled Results
RSA (ModExp) STM32F756 CM7 200 MHz No Run from flash, data in internal RAM Results
RSA (ModExp) STM32H753 CM7 400 MHz No Run from flash, data in internal RAM Results
Cipher (AES) AT91SAM9263 ARM926 200 MHz No Run from SDRAM with cache enabled Results
Cipher (AES) STM32F756 CM7 200 MHz Yes Run from flash, data in internal RAM Results
Cipher (AES) STM32H753 CM7 400 MHz Yes Run from flash, data in internal RAM Results

FAQs

For safety, my application cannot use a heap. How can I use emCrypt?

All hashes, ciphers, MACs, and other simple cryptographic operations never require the use of a heap; such operations may use a context that the caller provides.

Public key operations and signature algorithms (such as RSA, ECDSA, and EdDSA) and key agreement protocols based on integer factorization and elliptic curve cryptography (such as DH and ECDH) require an allocator. However, the allocator implementation is entirely under control of the caller and emCrypt never uses malloc() and free() internally.

emCrypt ships with a set of memory allocators:

  • Use a fixed area of memory with dynamic block sizes.
  • Use a fixed area of memory with constant-size block sizes.
  • Use a fixed area of memory with power-of-two sizes that avoids fragmentation.
  • Use the system heap through malloc() and free() for e.g. desktop applications.

All benchmarks demonstrate use of the emCrpt API using a fixed-size memory area and constant-size blocks avoiding use of any heap. Please refer to the emCrypt applications that ship in the product for examples of how to use fixed-size memory for API calls that require an allocator.