pub fn with_single_cert(
        self,
        cert_chain: Vec<key::Certificate>,
        key_der: key::PrivateKey,
    ) -> Result<ServerConfig, Error> {
        let resolver = handy::AlwaysResolvesChain::new(cert_chain, &key_der)?;
        Ok(self.with_cert_resolver(Arc::new(resolver)))
    }
/// Sets a single certificate chain and matching private key.  This
/// certificate and key is used for all subsequent connections,
/// irrespective of things like SNI hostname.
///
/// Note that the end-entity certificate must have the
/// [Subject Alternative Name](https://tools.ietf.org/html/rfc6125#section-4.1)
/// extension to describe, e.g., the valid DNS name. The `commonName` field is
/// disregarded.
///
/// `cert_chain` is a vector of DER-encoded certificates.
/// `key_der` is a DER-encoded RSA, ECDSA, or Ed25519 private key.
///
/// This function fails if `key_der` is invalid.
Sets a single certificate chain and matching private key.  This
certificate and key is used for all subsequent connections,
irrespective of things like SNI hostname.

Note that the end-entity certificate must have the
[Subject Alternative Name]
extension to describe, e.g., the valid DNS name. The `commonName` field is
disregarded.

`cert_chain` is a vector of DER-encoded certificates.
`key_der` is a DER-encoded RSA, ECDSA, or Ed25519 private key.

This function fails if `key_der` is invalid.
Sets a single certificate chain and matching private key . This certificate and key is used for all subsequent connections irrespective of things like SNI hostname . Note that the end - entity certificate must have the [ Subject Alternative Name ] extension to describe e . g . the valid DNS name . The ` commonName ` field is disregarded . ` cert_chain ` is a vector of DER - encoded certificates . ` key_der ` is a DER - encoded RSA ECDSA or Ed25519 private key . This function fails if ` key_der ` is invalid .
pub fn with_single_cert(
        self,
        cert_chain: Vec<key::Certificate>,
        key_der: key::PrivateKey,
    ) -> Result<ServerConfig, Error> {
        let resolver = handy::AlwaysResolvesChain::new(cert_chain, &key_der)?;
        Ok(self.with_cert_resolver(Arc::new(resolver)))
    }
pub fn with_single_cert ( self , cert_chain : Vec < key :: Certificate > , key_der : key :: PrivateKey , ) -> Result < ServerConfig , Error > { let resolver = handy :: AlwaysResolvesChain :: new ( cert_chain , & key_der ) ? ; Ok ( self . with_cert_resolver ( Arc :: new ( resolver ) ) ) }
Sets a single certificate chain and matching private key.
Sets a single certificate chain and matching private key .
self
cert_chain
Vec<key::Certificate>
key_der
key::PrivateKey