SSL/TLS transport wrapping :ssl.
Uses the OS certificate store via :public_key.cacerts_get/0 and
OTP's built-in hostname verification with wildcard SAN support.
Summary
Functions
Returns the ALPN protocol negotiated during the TLS handshake.
Upgrades an existing TCP socket to TLS.
Types
@type t() :: %Quiver.Transport.SSL{ negotiated_protocol: binary() | nil, socket: :ssl.sslsocket() }
Functions
Returns the ALPN protocol negotiated during the TLS handshake.
Returns nil if no protocol was negotiated (e.g. no ALPN extension
was advertised, or the server did not select one).
@spec upgrade(:gen_tcp.socket(), String.t(), :inet.port_number(), keyword()) :: {:ok, t()} | {:error, term()}
Upgrades an existing TCP socket to TLS.
Takes a raw :gen_tcp socket and performs TLS negotiation on it.
Used for CONNECT tunneling where a TCP connection to a proxy
is upgraded to TLS for the target host.