mirror of
https://github.com/arkorty/rustcm-cli.git
synced 2026-03-18 00:57:17 +00:00
Update main.rs
This commit is contained in:
@@ -141,7 +141,7 @@ pub fn read_cipher(path: String) -> (Vec<u8>, Vec<u8>) {
|
|||||||
pub fn decrypt(ciphertext: Vec<u8>, secret_key: orion::kdf::SecretKey) -> String {
|
pub fn decrypt(ciphertext: Vec<u8>, secret_key: orion::kdf::SecretKey) -> String {
|
||||||
let plaintext = match aead::open(&secret_key, &ciphertext) {
|
let plaintext = match aead::open(&secret_key, &ciphertext) {
|
||||||
Ok(temp) => {
|
Ok(temp) => {
|
||||||
println!("{} Data was decrypted", "Success".bright_green());
|
println!("{} Data was decrypted", "Success:".bright_green());
|
||||||
temp
|
temp
|
||||||
}
|
}
|
||||||
Err(_) => {
|
Err(_) => {
|
||||||
|
|||||||
Reference in New Issue
Block a user