Crates.io | uni_vault |
lib.rs | uni_vault |
version | 0.0.3 |
created_at | 2025-03-06 13:58:35.648026+00 |
updated_at | 2025-03-07 22:58:57.922147+00 |
description | uni_vault is a high-level Rust crate that provides secure vault functionality through advanced encryption methods. It leverages Trezor Ethereum signatures as a seed to generate SSH private keys and corresponding Rage key pairs, enabling asymmetric encryption and decryption operations. Built atop the signature_to_keys crate, uni_vault abstracts complex cryptographic processes into an accessible API, ensuring secure storage and management of sensitive data. |
homepage | https://github.com/RyderFreeman4Logos/onion_vault/tree/main/crates/uni_vault |
repository | https://github.com/OnionVault/onion_vault |
max_upload_size | |
id | 1581126 |
size | 110,869 |
uni_vault is a high-level Rust crate that provides secure vault functionality using advanced encryption techniques. It leverages Trezor Ethereum signatures as a seed to generate SSH private keys and Rage key pairs, ensuring robust asymmetric encryption and decryption operations. Built on top of the signature_to_keys crate, uni_vault abstracts complex cryptographic processes into an accessible API for secure data storage and management.
Add uni_vault to your Cargo.toml file:
cargo add uni_vault
Below is an example demonstrating how to use uni_vault for encryption and decryption:
use uni_vault::encryptor::{
asymmetric::rage_trezor::{RageTrezorEncryptorBuilder, RageTrezorEncryptor},
Encryptor,
HasUserIdentifier,
SecretType,
};
use uni_vault::common::traits::JsonSerializable;
let password = b"my_secret_password";
let mut encryptor: RageTrezorEncryptor = RageTrezorEncryptorBuilder::default()
.platform_id("example.com")
.username("user123")
.secret_type(SecretType::Password)
.bip32_path("m/44h/60h/11h/0/12")
.comment("Example encryption using uni_vault")
.build()
.unwrap();
// Encrypt the secret.
let encrypted = encryptor.encrypt(password).unwrap();
// Decrypt the secret.
let decrypted = encryptor.decrypt(&encrypted).unwrap();
assert_eq!(password.to_vec(), decrypted);
For detailed API documentation, please refer to the docs.rs page for uni_vault.
Contributions are welcome!
This project is licensed under the MIT License.