Registry / crypto / sodalite

sodalite

JSON →
library0.4.0rscratesunverified

Tweetnacl in pure rust with no std dependency, providing cryptographic primitives.

# Cargo.toml [dependencies] sodalite = "0.4.0"
INSTALL
IMPORT
SIG · SODALITE
S
sodalite
cryptorustv0.4.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

SecretKey
use sodalite::box_::curve25519xsalsa20poly1305::SecretKey;

Generate a keypair and encrypt a message using NaCl box.

use sodalite::box_::curve25519xsalsa20poly1305::{SecretKey, PublicKey, seal}; let sk = SecretKey::new(); let pk = PublicKey::from_secret(&sk); let message = b"Hello, world!"; let ciphertext = seal(message, &pk, &sk); println!("Encrypted: {:?}", ciphertext);
Debug
Known issues
gotchaThe API is low-level and requires careful handling of nonces and keys.
fix
Use higher-level wrappers like sodiumoxide if you need safer defaults.
affects: >=0.1.0
Upgrade
Version history
0.4.0latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
10 hits · last 30 days
node
10
Resources
sodalite — cargo add sodalite · libregistry