feat: update dependencies

This commit is contained in:
2023-05-13 22:31:46 +08:00
parent 709f83ce77
commit 6c600ae4b0
3 changed files with 17 additions and 101 deletions

View File

@@ -38,10 +38,7 @@ pub fn get_pki_algorithm(algorithm_identifier: &AlgorithmIdentifier) -> XResult<
}
pub fn bytes_to_pem<T>(tag: &str, contents: T) -> String where T: Into<Vec<u8>> {
let cert_public_key_pem_obj = Pem {
tag: tag.to_string(),
contents: contents.into(),
};
let cert_public_key_pem_obj = Pem::new(tag, contents);
pem::encode(&cert_public_key_pem_obj).trim().to_string()
}