Struct security_framework::os::macos::code_signing::SecStaticCode
source · pub struct SecStaticCode(_);
Expand description
A static code object representing signed code on disk.
Implementations§
source§impl SecStaticCode
impl SecStaticCode
sourcepub fn from_path(path: &CFURL, flags: Flags) -> Result<Self>
pub fn from_path(path: &CFURL, flags: Flags) -> Result<Self>
Creates a static code object representing the code at a specified file system path.
sourcepub fn path(&self, flags: Flags) -> Result<CFURL>
pub fn path(&self, flags: Flags) -> Result<CFURL>
Retrieves the location on disk of signed code, given a code or static code object.
sourcepub fn check_validity(
&self,
flags: Flags,
requirement: &SecRequirement
) -> Result<()>
pub fn check_validity( &self, flags: Flags, requirement: &SecRequirement ) -> Result<()>
Performs dynamic validation of signed code.
Trait Implementations§
source§impl Clone for SecStaticCode
impl Clone for SecStaticCode
source§fn clone(&self) -> SecStaticCode
fn clone(&self) -> SecStaticCode
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Drop for SecStaticCode
impl Drop for SecStaticCode
source§impl PartialEq<SecStaticCode> for SecStaticCode
impl PartialEq<SecStaticCode> for SecStaticCode
source§fn eq(&self, other: &SecStaticCode) -> bool
fn eq(&self, other: &SecStaticCode) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl TCFType for SecStaticCode
impl TCFType for SecStaticCode
§type Ref = *mut OpaqueSecStaticCodeRef
type Ref = *mut OpaqueSecStaticCodeRef
The reference type wrapped inside this type.
source§fn as_concrete_TypeRef(&self) -> SecStaticCodeRef
fn as_concrete_TypeRef(&self) -> SecStaticCodeRef
Returns the object as its concrete TypeRef.
source§unsafe fn wrap_under_get_rule(reference: SecStaticCodeRef) -> Self
unsafe fn wrap_under_get_rule(reference: SecStaticCodeRef) -> Self
Returns an instance of the object, wrapping the underlying
CFTypeRef
subclass. Use this
when following Core Foundation’s “Get Rule”. The reference count is bumped.source§fn as_CFTypeRef(&self) -> CFTypeRef
fn as_CFTypeRef(&self) -> CFTypeRef
Returns the object as a raw
CFTypeRef
. The reference count is not adjusted.source§unsafe fn wrap_under_create_rule(reference: SecStaticCodeRef) -> Self
unsafe fn wrap_under_create_rule(reference: SecStaticCodeRef) -> Self
Returns an instance of the object, wrapping the underlying
CFTypeRef
subclass. Use this
when following Core Foundation’s “Create Rule”. The reference count is not bumped.source§fn as_CFType(&self) -> CFType
fn as_CFType(&self) -> CFType
Returns the object as a wrapped
CFType
. The reference count is incremented by one.source§fn into_CFType(self) -> CFTypewhere
Self: Sized,
fn into_CFType(self) -> CFTypewhere Self: Sized,
Returns the object as a wrapped
CFType
. Consumes self and avoids changing the reference
count.source§fn retain_count(&self) -> isize
fn retain_count(&self) -> isize
Returns the reference count of the object. It is unwise to do anything other than test
whether the return value of this method is greater than zero.
source§fn instance_of<OtherCFType>(&self) -> boolwhere
OtherCFType: TCFType,
fn instance_of<OtherCFType>(&self) -> boolwhere OtherCFType: TCFType,
Returns true if this value is an instance of another type.
source§impl<'a> ToVoid<SecStaticCode> for &'a SecStaticCode
impl<'a> ToVoid<SecStaticCode> for &'a SecStaticCode
source§impl ToVoid<SecStaticCode> for SecStaticCode
impl ToVoid<SecStaticCode> for SecStaticCode
source§impl ToVoid<SecStaticCode> for SecStaticCodeRef
impl ToVoid<SecStaticCode> for SecStaticCodeRef
impl ConcreteCFType for SecStaticCode
impl Eq for SecStaticCode
Auto Trait Implementations§
impl RefUnwindSafe for SecStaticCode
impl !Send for SecStaticCode
impl !Sync for SecStaticCode
impl Unpin for SecStaticCode
impl UnwindSafe for SecStaticCode
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