pub trait SslContextExt {
    // Required methods
    fn diffie_hellman_params(&self) -> Result<Option<&[u8]>>;
    fn set_diffie_hellman_params(&mut self, dh_params: &[u8]) -> Result<()>;
    fn certificate_authorities(&self) -> Result<Option<Vec<SecCertificate>>>;
    fn set_certificate_authorities(
        &mut self,
        certs: &[SecCertificate]
    ) -> Result<()>;
    fn add_certificate_authorities(
        &mut self,
        certs: &[SecCertificate]
    ) -> Result<()>;
}
Expand description

An extension trait adding OSX specific functionality to the SslContext type.

Required Methods§

source

fn diffie_hellman_params(&self) -> Result<Option<&[u8]>>

Returns the DER encoded data specifying the parameters used for Diffie-Hellman key exchange.

source

fn set_diffie_hellman_params(&mut self, dh_params: &[u8]) -> Result<()>

Sets the parameters used for Diffie-Hellman key exchange, in the DER format used by OpenSSL.

If a cipher suite which uses Diffie-Hellman key exchange is selected, parameters will automatically be generated if none are provided with this method, but this process can take up to 30 seconds.

This can only be called on server-side sessions.

source

fn certificate_authorities(&self) -> Result<Option<Vec<SecCertificate>>>

Returns the certificate authorities used to validate client certificates.

source

fn set_certificate_authorities( &mut self, certs: &[SecCertificate] ) -> Result<()>

Sets the certificate authorities used to validate client certificates, replacing any that are already present.

source

fn add_certificate_authorities( &mut self, certs: &[SecCertificate] ) -> Result<()>

Adds certificate authorities used to validate client certificates.

Implementors§