pub struct Certificate { /* private fields */ }Expand description
Wraps SecCertificateRef.
Implementations§
Source§impl Certificate
impl Certificate
Sourcepub fn from_der(der: &[u8]) -> Result<Self>
pub fn from_der(der: &[u8]) -> Result<Self>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn import_item(
data: &[u8],
file_name_or_extension: Option<&str>,
format: ExternalFormat,
item_type: ExternalItemType,
) -> Result<Self>
pub fn import_item( data: &[u8], file_name_or_extension: Option<&str>, format: ExternalFormat, item_type: ExternalItemType, ) -> Result<Self>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn export_item(
&self,
format: ExternalFormat,
pem_armour: bool,
) -> Result<Vec<u8>>
pub fn export_item( &self, format: ExternalFormat, pem_armour: bool, ) -> Result<Vec<u8>>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn from_pem(pem: &[u8]) -> Result<Self>
pub fn from_pem(pem: &[u8]) -> Result<Self>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn subject_summary(&self) -> Result<Option<String>>
pub fn subject_summary(&self) -> Result<Option<String>>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn common_name(&self) -> Result<Option<String>>
pub fn common_name(&self) -> Result<Option<String>>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn email_addresses(&self) -> Result<Vec<String>>
pub fn email_addresses(&self) -> Result<Vec<String>>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn normalized_subject_sequence(&self) -> Result<Vec<u8>>
pub fn normalized_subject_sequence(&self) -> Result<Vec<u8>>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn normalized_issuer_sequence(&self) -> Result<Vec<u8>>
pub fn normalized_issuer_sequence(&self) -> Result<Vec<u8>>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn serial_number(&self) -> Result<Vec<u8>>
pub fn serial_number(&self) -> Result<Vec<u8>>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn not_valid_before(&self) -> Result<Option<SystemTime>>
pub fn not_valid_before(&self) -> Result<Option<SystemTime>>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn not_valid_after(&self) -> Result<Option<SystemTime>>
pub fn not_valid_after(&self) -> Result<Option<SystemTime>>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn public_key(&self) -> Result<PublicKey>
pub fn public_key(&self) -> Result<PublicKey>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn add_to_keychain(&self) -> Result<()>
pub fn add_to_keychain(&self) -> Result<()>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn values(&self, keys: &[&str]) -> Result<Value>
pub fn values(&self, keys: &[&str]) -> Result<Value>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn long_description(&self) -> Result<String>
pub fn long_description(&self) -> Result<String>
Wraps the corresponding SecCertificateRef operation.
Sourcepub fn short_description(&self) -> Result<String>
pub fn short_description(&self) -> Result<String>
Wraps the corresponding SecCertificateRef operation.