#rsa-key #xml-format #key-value #data #encryption-decryption #encrypting

rsa_xml

A simple implementation of RSA key values in XML format, for encrypting and decrypting data

1 unstable release

0.1.0 Jul 21, 2022

#15 in #encrypting

MIT/Apache

7KB
91 lines

RSA XML Encrypter/Decrypter

Summary

rsa-xml is a library for encrypting/decrypting data using RSA key values that are in xml format.

Usage

encryption

use rsa_xml{XmlRSA};

let rsa_xml = XmlRSA{
    public_key: "public key file path",
    private_key: "private key file path"
    }
let encrypted = XmlRSA.ecnrypt("data"); // plaintext data to encrypt
println!("{}", encrypted);



decryption

use rsa_xml{XmlRSA};

let rsa_xml = XmlRSA{
    public_key: "public key file path",
    private_key: "private key file path"
    }
let decrypted = XmlRSA.denrypt("data"); // encrypted data to decrypt
println!("{}", decrypted);



Dependencies

~7.5MB
~167K SLoC