#[repr(C)]pub struct SecTrustedApplication { /* private fields */ }
SecBase
only.Expand description
Contains information about a trusted application.
See also Apple’s documentation
Implementations§
Source§impl SecTrustedApplication
impl SecTrustedApplication
Sourcepub unsafe fn create_from_path(
path: *const c_char,
app: NonNull<*mut SecTrustedApplication>,
) -> i32
👎Deprecated: SecKeychain is deprecatedAvailable on crate feature SecTrustedApplication
only.
pub unsafe fn create_from_path( path: *const c_char, app: NonNull<*mut SecTrustedApplication>, ) -> i32
SecTrustedApplication
only.Creates a trusted application reference based on the trusted application specified by path.
Parameter path
: The path to the application or tool to trust. For application bundles, use the
path to the bundle directory. Pass NULL to refer to yourself, i.e. the application or tool
making this call.
Parameter app
: On return, a pointer to the trusted application reference.
Returns: A result code. See “Security Error Codes” (SecBase.h).
Sourcepub unsafe fn copy_data(
self: &SecTrustedApplication,
data: NonNull<*const CFData>,
) -> i32
👎Deprecated: SecKeychain is deprecatedAvailable on crate feature SecTrustedApplication
only.
pub unsafe fn copy_data( self: &SecTrustedApplication, data: NonNull<*const CFData>, ) -> i32
SecTrustedApplication
only.Retrieves the data of a given trusted application reference
Parameter appRef
: A trusted application reference to retrieve data from
Parameter data
: On return, a pointer to a data reference of the trusted application.
Returns: A result code. See “Security Error Codes” (SecBase.h).
Sourcepub unsafe fn set_data(self: &SecTrustedApplication, data: &CFData) -> i32
👎Deprecated: SecKeychain is deprecatedAvailable on crate feature SecTrustedApplication
only.
pub unsafe fn set_data(self: &SecTrustedApplication, data: &CFData) -> i32
SecTrustedApplication
only.Sets the data of a given trusted application reference
Parameter appRef
: A trusted application reference.
Parameter data
: A reference to the data to set in the trusted application.
Returns: A result code. See “Security Error Codes” (SecBase.h).
Methods from Deref<Target = CFType>§
Sourcepub fn downcast_ref<T>(&self) -> Option<&T>where
T: ConcreteType,
Available on crate feature SecCustomTransform
only.
pub fn downcast_ref<T>(&self) -> Option<&T>where
T: ConcreteType,
SecCustomTransform
only.Attempt to downcast the type to that of type T
.
This is the reference-variant. Use CFRetained::downcast
if you
want to convert a retained type. See also ConcreteType
for more
details on which types support being converted to.
Sourcepub fn retain_count(&self) -> usize
Available on crate feature SecCustomTransform
only.
pub fn retain_count(&self) -> usize
SecCustomTransform
only.Get the reference count of the object.
This function may be useful for debugging. You normally do not use this function otherwise.
Beware that some things (like CFNumber
s, small CFString
s etc.) may
not have a normal retain count for optimization purposes, and can
return usize::MAX
in that case.
Trait Implementations§
Source§impl AsRef<AnyObject> for SecTrustedApplication
impl AsRef<AnyObject> for SecTrustedApplication
Source§impl AsRef<CFType> for SecTrustedApplication
impl AsRef<CFType> for SecTrustedApplication
Source§impl Borrow<AnyObject> for SecTrustedApplication
impl Borrow<AnyObject> for SecTrustedApplication
Source§impl Borrow<CFType> for SecTrustedApplication
impl Borrow<CFType> for SecTrustedApplication
Source§impl ConcreteType for SecTrustedApplication
Available on crate feature SecTrustedApplication
only.
impl ConcreteType for SecTrustedApplication
SecTrustedApplication
only.Source§impl Debug for SecTrustedApplication
impl Debug for SecTrustedApplication
Source§impl Deref for SecTrustedApplication
impl Deref for SecTrustedApplication
Source§impl Hash for SecTrustedApplication
impl Hash for SecTrustedApplication
Source§impl Message for SecTrustedApplication
impl Message for SecTrustedApplication
Source§impl PartialEq for SecTrustedApplication
impl PartialEq for SecTrustedApplication
Source§impl RefEncode for SecTrustedApplication
impl RefEncode for SecTrustedApplication
Source§const ENCODING_REF: Encoding
const ENCODING_REF: Encoding
Source§impl Type for SecTrustedApplication
impl Type for SecTrustedApplication
Source§fn retain(&self) -> CFRetained<Self>where
Self: Sized,
fn retain(&self) -> CFRetained<Self>where
Self: Sized,
Source§fn as_concrete_TypeRef(&self) -> &Self
fn as_concrete_TypeRef(&self) -> &Self
core-foundation
crate.Source§unsafe fn wrap_under_get_rule(ptr: *const Self) -> CFRetained<Self>where
Self: Sized,
unsafe fn wrap_under_get_rule(ptr: *const Self) -> CFRetained<Self>where
Self: Sized,
core-foundation
crate. Read moreSource§fn as_CFTypeRef(&self) -> &CFType
fn as_CFTypeRef(&self) -> &CFType
core-foundation
crate.Source§unsafe fn wrap_under_create_rule(ptr: *const Self) -> CFRetained<Self>where
Self: Sized,
unsafe fn wrap_under_create_rule(ptr: *const Self) -> CFRetained<Self>where
Self: Sized,
core-foundation
crate. Read more