add rsa
This commit is contained in:
@@ -14,4 +14,5 @@ license = "MIT"
|
||||
rust-crypto = "0.2.36"
|
||||
base64 = "0.11.0"
|
||||
urlencoding = "1.0.0"
|
||||
rust_util="0.2.0"
|
||||
rust_util="0.2.1"
|
||||
ring = "0.16.9"
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
|
||||
/// HMac Utils
|
||||
pub mod hmac;
|
||||
// RSA Utils
|
||||
pub mod rsa;
|
||||
17
src/rsa.rs
Normal file
17
src/rsa.rs
Normal file
@@ -0,0 +1,17 @@
|
||||
|
||||
// use std::path::Path;
|
||||
|
||||
// pub fn read_rsa_private_key_from_file(private_key_path: &Path) {
|
||||
// let private_key_der = read_file(private_key_path)?;
|
||||
|
||||
// }
|
||||
|
||||
// fn read_file(path: &std::path::Path) -> Result<Vec<u8>, MyError> {
|
||||
// use std::io::Read;
|
||||
|
||||
// let mut file = std::fs::File::open(path).map_err(|e| MyError::IO(e))?;
|
||||
// let mut contents: Vec<u8> = Vec::new();
|
||||
// file.read_to_end(&mut contents).map_err(|e| MyError::IO(e))?;
|
||||
// Ok(contents)
|
||||
// }
|
||||
|
||||
Reference in New Issue
Block a user