Trait tugger_apple_codesign::AppleCertificateBuilder[][src]

pub trait AppleCertificateBuilder: Sized {
    fn apple_subject(
        &mut self,
        team_id: &str,
        person_name: &str,
        country: &str
    ) -> Result<(), AppleCodesignError>;
fn apple_email_address(
        &mut self,
        address: &str
    ) -> Result<(), AppleCodesignError>;
fn apple_extended_key_usage(
        &mut self,
        usage: ExtendedKeyUsagePurpose
    ) -> Result<(), AppleCodesignError>;
fn apple_code_signing_certificate_extension(
        &mut self,
        extension: CodeSigningCertificateExtension
    ) -> Result<(), AppleCodesignError>;
fn apple_certificate_profile(
        &mut self,
        profile: CertificateProfile
    ) -> Result<(), AppleCodesignError>;
fn apple_code_signing_extensions(
        &self
    ) -> Vec<CodeSigningCertificateExtension>

Notable traits for Vec<u8, A>

impl<A> Write for Vec<u8, A> where
    A: Allocator
; }

Extensions to X509CertificateBuilder specializing in Apple certificate behavior.

Most callers should call Self::apple_certificate_profile to configure a preset profile for the certificate being generated. After that - and it is important it is after - call Self::apple_subject to define the subject field. If you call this after registering code signing extensions, it detects the appropriate format for the Common Name field.

Required methods

fn apple_subject(
    &mut self,
    team_id: &str,
    person_name: &str,
    country: &str
) -> Result<(), AppleCodesignError>
[src]

This functions defines common attributes on the certificate subject.

team_id is your Apple team id. It is a short alphanumeric string. You can find this at https://developer.apple.com/account/#/membership/.

fn apple_email_address(
    &mut self,
    address: &str
) -> Result<(), AppleCodesignError>
[src]

Add an email address to the certificate’s subject name.

fn apple_extended_key_usage(
    &mut self,
    usage: ExtendedKeyUsagePurpose
) -> Result<(), AppleCodesignError>
[src]

Add an ExtendedKeyUsagePurpose to this certificate.

fn apple_code_signing_certificate_extension(
    &mut self,
    extension: CodeSigningCertificateExtension
) -> Result<(), AppleCodesignError>
[src]

Add a certificate extension as defined by a CodeSigningCertificateExtension instance.

fn apple_certificate_profile(
    &mut self,
    profile: CertificateProfile
) -> Result<(), AppleCodesignError>
[src]

Add a CertificateProfile to this builder.

All certificate extensions relevant to this profile are added.

This should be the first function you call after creating an instance because other functions rely on the state that it sets.

fn apple_code_signing_extensions(&self) -> Vec<CodeSigningCertificateExtension>

Notable traits for Vec<u8, A>

impl<A> Write for Vec<u8, A> where
    A: Allocator
[src]

Find code signing extensions that are currently registered.

Loading content...

Implementations on Foreign Types

impl AppleCertificateBuilder for X509CertificateBuilder[src]

fn apple_subject(
    &mut self,
    team_id: &str,
    person_name: &str,
    country: &str
) -> Result<(), AppleCodesignError>
[src]

fn apple_email_address(
    &mut self,
    address: &str
) -> Result<(), AppleCodesignError>
[src]

fn apple_extended_key_usage(
    &mut self,
    usage: ExtendedKeyUsagePurpose
) -> Result<(), AppleCodesignError>
[src]

fn apple_code_signing_certificate_extension(
    &mut self,
    extension: CodeSigningCertificateExtension
) -> Result<(), AppleCodesignError>
[src]

fn apple_certificate_profile(
    &mut self,
    profile: CertificateProfile
) -> Result<(), AppleCodesignError>
[src]

fn apple_code_signing_extensions(&self) -> Vec<CodeSigningCertificateExtension>

Notable traits for Vec<u8, A>

impl<A> Write for Vec<u8, A> where
    A: Allocator
[src]

Loading content...

Implementors

Loading content...