Skip to main content

Module tls

Module tls 

Source
Expand description

TLS configuration from a Policy: which versions, cipher suites, key-exchange groups and handshake signature schemes a provider carries, in preference order.

Structs§

CertificateKey
A TLS certificate key: a key of one of the profile’s TLS key algorithms (Resolved::keys), for a certificate request (csr::generate_csr) and this side’s certificate (Resolved::certified_key). It is held once, as the module’s parsed key (decision 0012), and is not Clone; its Debug prints the algorithm only. It has no sign; it signs through the TLS key provider with the policy’s TLS schemes, and that signer signs whatever bytes it is given (decision 0016, residual 2). Its PKCS#8 export is the private key, which imports as a signature::KeyPair only under an Admitted whose signatures admit the algorithm; what else takes it is decision 0016, residuals 2 and 4.
ClientVerifierBuilder
A client-certificate verifier builder preserving hints, authentication and revocation modes.
ClientVerifierHandle
An owned client-certificate verifier bound to its rule and handshake schemes.
PeerLeaf
The end-entity certificate after crypto-profile’s own checks have passed.
Policy
What a TLS configuration may use: versions, suites and groups in preference order, and a set of signature schemes. No list may name an entry twice.
ServerVerifierBuilder
A server-certificate verifier builder preserving baseline revocation configuration.
ServerVerifierHandle
An owned server-certificate verifier bound to its rule and handshake schemes.

Enums§

ClientVerifierInput
Input to strict server completion. Opaque verifiers are rejection-only.
ServerVerifierInput
Input to strict client completion. Opaque verifiers are rejection-only.

Traits§

PeerIdentity
An application’s check of the peer’s identity, run after every crate check has passed.

Functions§

assert_provider_matches
Refuses a provider that does not carry exactly the suites, groups, handshake schemes and their verifiers, certificate-chain verifiers, random source and key provider that crypto_provider(p) carries, in its order. Each is compared by identity, so a substitute that reports the same codepoint or algorithm identifiers is refused.
client_builder
A client configuration builder on p.
client_cert_verifier_builder
Builds a client-certificate verifier with p’s canonical identity.
crypto_provider
A provider carrying exactly p. It refuses, in this order: an empty version, group or scheme list; a duplicate entry in any list, naming the first one found in versions, suites, groups, then schemes; an unavailable algorithm; and a suite list left empty once suites of unlisted versions are dropped; then, for each listed version in policy order, a version with no suite, no group usable at it, or no scheme a suite at it can sign with, checked in that order (PolicyVersionUnusable). A key loaded through its key provider signs only with a scheme in p.signature_schemes.
install_default
Installs a provider for p as the process default; refuses if one is already installed.
load_private_key
Loads a private key into a signing key that signs only with a scheme in p.signature_schemes. The key’s algorithm is not checked against any profile; Resolved::certified_key checks it.
server_builder
A server configuration builder on p.
server_cert_verifier_builder
Builds a server-certificate verifier with p’s canonical identity.
strict_client_builder
Completes a client builder with an owned verifier matching both rule and scheme set.
strict_server_builder
Completes a server builder with an owned verifier matching both rule and scheme set.