pub struct SignatureContext(/* private fields */);Expand description
Used to extract additional information from the signing leaf certificate
Implementations§
Source§impl SignatureContext
impl SignatureContext
Sourcepub fn subject_name(&self) -> Name
pub fn subject_name(&self) -> Name
Retrieve the subject name on the leaf certificate
§Examples
use codesign_verify::CodeSignVerifier;
let ctx = CodeSignVerifier::for_file("C:/Windows/explorer.exe").unwrap().verify().unwrap();
assert_eq!(
ctx.subject_name().organization.as_deref(),
Some("Microsoft Corporation")
);
Sourcepub fn issuer_name(&self) -> Name
pub fn issuer_name(&self) -> Name
Retrieve the issuer name on the leaf certificate
Sourcepub fn sha1_thumbprint(&self) -> String
pub fn sha1_thumbprint(&self) -> String
Compute the sha1 thumbprint of the leaf certificate
Sourcepub fn sha256_thumbprint(&self) -> String
pub fn sha256_thumbprint(&self) -> String
Compute the sha256 thumbprint of the leaf certificate
Auto Trait Implementations§
impl Freeze for SignatureContext
impl RefUnwindSafe for SignatureContext
impl !Send for SignatureContext
impl !Sync for SignatureContext
impl Unpin for SignatureContext
impl UnwindSafe for SignatureContext
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more