You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This commit was created on GitHub.com and signed with GitHub’s verified signature.
added: Server::first_request_timeout, which closes connections that do not send a request in time. This also covers the protocol detection read that hyper does before any HTTP timeout applies.
added: Server::accept_error_handler, which reports connection accept errors instead of silently dropping them.
added: TLS acceptors now add axum_server::tls::TlsInfo (SNI, ALPN, and client certificates) to request extensions as Arc<TlsInfo> for both rustls and OpenSSL.
added: axum_server::accept::LocalAddrAcceptor adds the local socket address of the connection to request extensions as LocalAddr.
added: RustlsConfig::from_sni_pem_files, which selects the certificate using the server name sent by the client through SNI.
added: the tls-rustls-encrypted-keys feature and RustlsConfig::from_pem_with_password plus file and reload variants, for encrypted PKCS#8 private keys.
added: accept::TcpConfigAcceptor, accept::TcpSocketConfig, and accept::TcpKeepaliveConfig apply TCP_NODELAY and TCP keepalive settings to accepted connections.
added: a timeouts example showing the request, header, keep-alive, and TLS handshake timeouts.
added: a reverse_proxy example that terminates TLS and forwards requests to an HTTP upstream.
breaking: TLS acceptors now return a tls::TlsService wrapper service. Custom acceptors that wrap a TLS acceptor and assume the service type is unchanged need to be updated; examples/rustls_session.rs now uses the built-in TlsInfo.
fixed: Handle::listening() now returns None after a bind failure instead of waiting forever, and no longer races with server startup.
fixed: RustlsConfig::from_pem_chain_file now sets the h2 and http/1.1 ALPN protocols like the other RustlsConfig constructors.
fixed: Connections that are still performing the TLS handshake are now cancelled on shutdown instead of keeping a task and file descriptor alive until the handshake timeout.
fixed: A timer is now installed by default, so header_read_timeout and keep_alive_timeout no longer panic with "timeout set, but no timer set".
fixed: from_tcp and from_unix now put the provided listener into non-blocking mode, as required by Tokio. The from_std_listener examples work without extra setup.
fixed: Server::acceptor and Server::map now preserve the HTTP version selected by http1_only/http2_only.
changed: The tls-rustls feature now enables TLS 1.2, restoring the behavior from before 0.7.0.
changed: fs-err is now an optional dependency and is only pulled in by the rustls features.