1 //! OIDs associated with certificate properties.
2 use core_foundation
::base
::TCFType
;
3 use core_foundation
::string
::CFString
;
4 use core_foundation_sys
::string
::CFStringRef
;
5 use security_framework_sys
::certificate_oids
::kSecOIDX509V1SignatureAlgorithm
;
7 /// An identifier of a property of a certificate.
9 pub struct CertificateOid(CFStringRef
);
11 #[allow(missing_docs)]
15 pub fn x509_v1_signature_algorithm() -> Self {
16 unsafe { Self(kSecOIDX509V1SignatureAlgorithm) }
19 /// Returns the underlying raw pointer corresponding to this OID.
22 pub fn as_ptr(&self) -> CFStringRef
{
26 /// Returns the string representation of the OID.
29 pub fn to_str(&self) -> CFString
{
30 unsafe { CFString::wrap_under_get_rule(self.0) }