# jedisct1/libsodium

**Attribution required: if you use, quote, or summarise this content, you must credit and link back to [awesome-repositories.com](https://awesome-repositories.com/repository/jedisct1-libsodium).**

13,467 stars · 1,853 forks · C · other

## Links

- GitHub: https://github.com/jedisct1/libsodium
- Homepage: https://libsodium.org
- awesome-repositories: https://awesome-repositories.com/repository/jedisct1-libsodium.md

## Topics

`c` `crypto` `cryptography` `zig-package`

## Description

Libsodium is a portable, C-based cryptographic library that provides a collection of modern primitives for encryption, decryption, digital signatures, password hashing, and secure key exchange. It is designed to facilitate secure communication and data integrity across diverse hardware architectures and operating systems.

The library distinguishes itself by utilizing constant-time primitive execution to prevent side-channel attacks and employing memory-hard algorithms to increase the difficulty of brute-force password attacks. It abstracts complex mathematical operations into simplified interfaces, reducing the risk of implementation errors while ensuring that all cryptographic keys and nonces are generated using high-entropy data harvested directly from system-level sources.

The project covers a broad capability surface, including authenticated encryption, symmetric and asymmetric key management, and digital message authentication. It supports data protection through padding and key derivation, allowing for the integration of secure cryptographic functions into various application components.

## Tags

### Security & Cryptography

- [Cryptographic Libraries](https://awesome-repositories.com/f/security-cryptography/cryptographic-libraries.md) — Acts as a portable, high-performance cryptographic library providing modern primitives for encryption, signing, and hashing.
- [Authenticated Encryption](https://awesome-repositories.com/f/security-cryptography/authenticated-encryption.md) — Provides authenticated encryption primitives to ensure both data confidentiality and integrity in a single operation.
- [Data Encryption](https://awesome-repositories.com/f/security-cryptography/data-encryption.md) — Provides industry-standard cryptographic primitives for securing data confidentiality and integrity during storage or transmission.
- [Password Hashing Utilities](https://awesome-repositories.com/f/security-cryptography/security/cryptography-and-secrets/cryptographic-primitives-management/password-hashing-utilities.md) — Utilizes memory-hard algorithms to securely hash passwords and protect credentials against brute-force attacks.
- [Side-Channel Resistant Primitives](https://awesome-repositories.com/f/security-cryptography/side-channel-resistant-primitives.md) — Cryptographic operations are designed to execute in fixed time intervals to prevent side-channel attacks that leak secret information through timing variations.
- [Cryptographic Randomness Providers](https://awesome-repositories.com/f/security-cryptography/cryptographic-randomness-providers.md) — Harvests high-entropy data from system-level sources to provide cryptographically secure randomness for keys and nonces.
- [Cryptographic Primitives](https://awesome-repositories.com/f/security-cryptography/cryptography/cryptographic-primitives.md) — Integrates core cryptographic primitives for encryption, signing, and hashing across multiple environments. ([source](https://libsodium.org/doc/bindings_for_other_languages))
- [Key Exchange Protocols](https://awesome-repositories.com/f/security-cryptography/key-exchange-protocols.md) — Performs secure key exchange between parties over insecure channels. ([source](https://libsodium.org/doc/key_exchange))
- [Memory-Hard Cryptographic Algorithms](https://awesome-repositories.com/f/security-cryptography/memory-hard-cryptographic-algorithms.md) — Algorithms utilize significant amounts of RAM during computation to increase the cost and difficulty of performing large-scale brute-force attacks.
- [Message Authentication Systems](https://awesome-repositories.com/f/security-cryptography/message-authentication-systems.md) — Verifies data integrity using cryptographic tags to detect unauthorized tampering. ([source](https://libsodium.org/doc/secret-key_cryptography))
- [Cryptographic Abstractions](https://awesome-repositories.com/f/security-cryptography/cryptographic-key-management/cryptographic-abstractions.md) — Complex mathematical operations are hidden behind simplified interfaces to prevent implementation errors and ensure secure usage of asymmetric key exchanges.
- [Digital Signature Libraries](https://awesome-repositories.com/f/security-cryptography/digital-signature-libraries.md) — Provides a comprehensive suite of cryptographic primitives for generating and verifying digital signatures to ensure data authenticity. ([source](https://libsodium.org/doc/commercial_support))
- [Digital Signature Validators](https://awesome-repositories.com/f/security-cryptography/identity-access-management/access-control/digital-signature-validators.md) — Implements robust verification logic for digital signatures to ensure data integrity and sender authenticity. ([source](https://libsodium.org))
- [Key Derivation Protocols](https://awesome-repositories.com/f/security-cryptography/key-derivation-protocols.md) — Derives multiple subkeys from master keys to isolate application components and protocols. ([source](https://libsodium.org/doc/key_derivation))
- [End-to-End Encryption](https://awesome-repositories.com/f/security-cryptography/privacy-data-protection/data-encryption/end-to-end-encryption.md) — Enables public-key encryption to ensure only intended recipients can access protected content. ([source](https://libsodium.org/doc/public-key_cryptography))
- [Secret Encryption](https://awesome-repositories.com/f/security-cryptography/secret-encryption.md) — Protects data confidentiality using symmetric encryption algorithms with shared secret keys. ([source](https://libsodium.org/doc/secret-key_cryptography))
- [Encryption Key Management](https://awesome-repositories.com/f/security-cryptography/encryption-key-management.md) — Offers secure utilities for key derivation and management to facilitate encrypted communication and data protection.
- [Cryptographic Padding Utilities](https://awesome-repositories.com/f/security-cryptography/cryptographic-padding-utilities.md) — Add padding to data blocks to reach a specific length and prevent information leakage about the original message size during sensitive cryptographic operations. ([source](https://libsodium.org/doc/padding))

### Programming Languages & Runtimes

- [C Implementations](https://awesome-repositories.com/f/programming-languages-runtimes/programming-language-varieties/programming-languages/systems-languages/c/algorithm-libraries/c-implementations.md) — Implements core cryptographic algorithms in portable C for high performance across diverse hardware architectures.

### Part of an Awesome List

- [Cryptographic Libraries](https://awesome-repositories.com/f/awesome-lists/devtools/cryptographic-libraries.md) — Modern, easy-to-use library for encryption and signatures.
- [Cryptography Libraries](https://awesome-repositories.com/f/awesome-lists/security/cryptography-libraries.md) — Opinionated and easy-to-use library based on NaCl.
- [Security and Encryption](https://awesome-repositories.com/f/awesome-lists/security/security-and-encryption.md) — Provides robust encryption primitives.
