libtom/libtomcrypt logo

libtom/libtomcrypt

Free

LibTomCrypt is a fairly comprehensive, modular and portable cryptographic toolkit that provides developers with a vast array of well known published block ciphers, one-way hash functions, chaining modes, pseudo-random number generators, public key cryptography and a plethora of other routines.

FreeFree tier
Type
Open Source

About libtom/libtomcrypt

LibTomCrypt is a comprehensive, modular, and portable cryptographic toolkit written in C. It provides a vast array of well-known block ciphers, one-way hash functions, chaining modes, pseudo-random number generators, public key cryptography, and many other routines. The library is designed for flexibility and can be trimmed down for embedded targets via configuration options. It is actively maintained with CI integration and supports multiple MPI providers (GMP, libtommath, tomsfastmath). The project follows a develop-branch workflow for patches and includes extensive self-tests.

Key Features

Block ciphers (AES, DES, Blowfish, etc.)
One-way hash functions (SHA-1, SHA-2, MD5, etc.)
Chaining modes (ECB, CBC, CTR, GCM, etc.)
Pseudo-random number generators
Public key cryptography (RSA, DH, ECC, etc.)
Modular and portable design
Configurable to trim features for embedded systems
Support for multiple MPI providers (GMP, libtommath, tomsfastmath)
Self-tests for algorithms
Active maintenance with CI and releases

Pros & Cons

Pros
  • Comprehensive collection of well-established cryptographic primitives
  • Highly modular and portable across platforms
  • Actively maintained with CI and releases
  • Configurable to reduce footprint for embedded devices
  • Includes self-tests to verify algorithm correctness
  • Support for multiple math libraries for flexibility
Cons
  • Documentation PDF removed from git repository (only available in tarball releases)
  • Large default build may require configuration trimming for resource-constrained systems
  • Configuration options can be numerous, potentially overwhelming for beginners

Best For

Cryptographic operations in software applicationsEmbedded systems requiring tailored cryptographic functionalityImplementing secure communication protocolsData encryption and hashing in file storageAuthentication and digital signatures

FAQ

Where can I find the detailed documentation?
The documentation PDF (crypt.pdf) was removed from the git repository and is now only available from the tarball of the appropriate version or from the GitHub releases page (https://github.com/libtom/libtomcrypt/releases).
How do I submit a patch or contribute?
Patches should be branched off from the develop branch. Include tests and documentation in your patch, and update the makefiles by running the updatemakes.sh script in a separate commit. Pull requests are reviewed to ensure code quality.