rustls breaking changes
rustls 0.23.0 (February 29, 2024) is its newest release with breaking changes, 42 of them. The first: Signature changed rustls::CommonState::peer_certificates. Every breaking API change we have recorded in rustls on crates.io: 235 breaking changes in 3 versions. Below, its 3 versions with breaking changes, newest first, removals and renames first, each with its source.
Updated December 4, 2026
On this page
Latest version 0.23.48, released December 3, 2026. Source repository
Packages on crates.io run on Rust. Rust end of life dates.
rustls 0.23.0 breaking changes
- Signature changed
rustls::CommonState::peer_certificates
Was fn peer_certificates(&self) -> Option<&[CertificateDer<'_>]>; now fn peer_certificates(&self) -> Option<&[CertificateDer<'static>]>. crates.io - Signature changed
rustls::crypto::cipher::MessageDecrypter::decrypt
Was fn decrypt(&mut self, msg: OpaqueMessage, seq: u64) -> Result<PlainMessage, Error>; now fn decrypt<'a>(&mut self, msg: InboundOpaqueMessage<'a>, seq: u64) -> Result<InboundPlainMessage<'a>, Error>. crates.io - Signature changed
rustls::crypto::cipher::MessageEncrypter::encrypt
Was fn encrypt(&mut self, msg: BorrowedPlainMessage, seq: u64) -> Result<OpaqueMessage, Error>; now fn encrypt(&mut self, msg: OutboundPlainMessage, seq: u64) -> Result<OutboundOpaqueMessage, Error>. crates.io - Signature changed
rustls::crypto::cipher::PlainMessage::into_unencrypted_opaque
Was fn into_unencrypted_opaque(self) -> OpaqueMessage; now fn into_unencrypted_opaque(self) -> OutboundOpaqueMessage. crates.io - Signature changed
rustls::crypto::cipher::PlainMessage::payload
Was payload: Payload; now payload: Payload<'static>. crates.io - Signature changed
rustls::crypto::SharedSecret
Was struct SharedSecret(Vec<u8>); now struct SharedSecret. crates.io - Signature changed
rustls::internal::msgs::base::Payload
Was struct Payload(pub Vec<u8>); now enum Payload<'a>. crates.io - Signature changed
rustls::internal::msgs::base::Payload::empty
Was fn empty() -> Self; now fn empty() -> Self. crates.io - Signature changed
rustls::internal::msgs::base::Payload::new
Was fn new(bytes: impl Into<Vec<u8>>) -> Self; now fn new(bytes: impl Into<Vec<u8>>) -> Self. crates.io - Signature changed
rustls::internal::msgs::base::Payload::read
Was fn read(r: &mut Reader) -> Self; now fn read(r: &mut Reader<'a>) -> Self. crates.io - Signature changed
rustls::internal::msgs::codec::Codec
Was trait Codec: Debug + Sized; now trait Codec<'a>: Debug + Sized. crates.io - Signature changed
rustls::internal::msgs::codec::Codec::read
Was fn read(_: &mut Reader) -> Result<Self, InvalidMessage>; now fn read(_: &mut Reader<'a>) -> Result<Self, InvalidMessage>. crates.io - Signature changed
rustls::internal::msgs::codec::Codec::read_bytes
Was fn read_bytes(bytes: &[u8]) -> Result<Self, InvalidMessage>; now fn read_bytes(bytes: &'a [u8]) -> Result<Self, InvalidMessage>. crates.io - Signature changed
rustls::internal::msgs::codec::Reader::init
Was fn init(bytes: &[u8]) -> Reader; now fn init(bytes: &'a [u8]) -> Self. crates.io - Signature changed
rustls::internal::msgs::codec::Reader::rest
Was fn rest(&mut self) -> &[u8]; now fn rest(&mut self) -> &'a [u8]. crates.io - Signature changed
rustls::internal::msgs::codec::Reader::sub
Was fn sub(&mut self, length: usize) -> Result<Reader, InvalidMessage>; now fn sub(&mut self, length: usize) -> Result<Self, InvalidMessage>. crates.io - Signature changed
rustls::internal::msgs::codec::Reader::take
Was fn take(&mut self, length: usize) -> Option<&[u8]>; now fn take(&mut self, length: usize) -> Option<&'a [u8]>. crates.io - Signature changed
rustls::internal::msgs::deframer::MessageDeframer::pop
Was fn pop(&mut self, record_layer: &mut RecordLayer, negotiated_version: Option<ProtocolVersion>, buffer: &mut DeframerSliceBuffer) -> Result<Option<Deframed>, Error>; now fn pop<'b>(&mut self, record_layer: &mut RecordLayer... crates.io - Signature changed
rustls::internal::msgs::fragmenter::MessageFragmenter::fragment_message
Was fn fragment_message<'a>(&self, msg: &'a PlainMessage) -> impl Iterator<Item = BorrowedPlainMessage<'a>> + 'a; now fn fragment_message<'a>(&self, msg: &'a PlainMessage) -> impl Iterator<Item = OutboundPlainMessage<'a>> + 'a. crates.io - Signature changed
rustls::internal::msgs::handshake::CertificateChain
Was struct CertificateChain(pub Vec<CertificateDer<'static>>); now struct CertificateChain<'a>(pub Vec<CertificateDer<'a>>). crates.io - Signature changed
rustls::internal::msgs::handshake::HandshakeMessagePayload
Was struct HandshakeMessagePayload; now struct HandshakeMessagePayload<'a>. crates.io - Signature changed
rustls::internal::msgs::handshake::HandshakeMessagePayload::payload
Was payload: HandshakePayload; now payload: HandshakePayload<'a>. crates.io - Signature changed
rustls::internal::msgs::handshake::HandshakePayload
Was enum HandshakePayload; now enum HandshakePayload<'a>. crates.io - Signature changed
rustls::internal::msgs::handshake::HandshakePayload::Certificate
Was Certificate(CertificateChain); now Certificate(CertificateChain<'a>). crates.io - Signature changed
rustls::internal::msgs::handshake::HandshakePayload::ClientKeyExchange
Was ClientKeyExchange(Payload); now ClientKeyExchange(Payload<'a>). crates.io - Signature changed
rustls::internal::msgs::handshake::HandshakePayload::Finished
Was Finished(Payload); now Finished(Payload<'a>). crates.io - Signature changed
rustls::internal::msgs::handshake::HandshakePayload::MessageHash
Was MessageHash(Payload); now MessageHash(Payload<'a>). crates.io - Signature changed
rustls::internal::msgs::handshake::HandshakePayload::Unknown
Was Unknown(Payload); now Unknown(Payload<'a>). crates.io - Signature changed
rustls::internal::msgs::message::Message
Was struct Message; now struct Message<'a>. crates.io - Signature changed
rustls::internal::msgs::message::Message::build_alert
Was fn build_alert(level: AlertLevel, desc: AlertDescription) -> Self; now fn build_alert(level: AlertLevel, desc: AlertDescription) -> Self. crates.io - Signature changed
rustls::internal::msgs::message::Message::build_key_update_notify
Was fn build_key_update_notify() -> Self; now fn build_key_update_notify() -> Self. crates.io - Signature changed
rustls::internal::msgs::message::Message::payload
Was payload: MessagePayload; now payload: MessagePayload<'a>. crates.io - Signature changed
rustls::internal::msgs::message::MessagePayload
Was enum MessagePayload; now enum MessagePayload<'a>. crates.io - Signature changed
rustls::internal::msgs::message::MessagePayload::ApplicationData
Was ApplicationData(Payload); now ApplicationData(Payload<'a>). crates.io - Signature changed
rustls::internal::msgs::message::MessagePayload::handshake
Was fn handshake(parsed: HandshakeMessagePayload) -> Self; now fn handshake(parsed: HandshakeMessagePayload<'a>) -> Self. crates.io - Signature changed
rustls::internal::msgs::message::MessagePayload::Handshake
Was Handshake {parsed: HandshakeMessagePayload, encoded: Payload}; now Handshake {parsed: HandshakeMessagePayload<'a>, encoded: Payload<'a>}. crates.io - Signature changed
rustls::internal::msgs::message::MessagePayload::new
Was fn new(typ: ContentType, vers: ProtocolVersion, payload: Payload) -> Result<Self, InvalidMessage>; now fn new(typ: ContentType, vers: ProtocolVersion, payload: &'a [u8]) -> Result<Self, InvalidMessage>. crates.io - Signature changed
rustls::internal::msgs::message::PlainMessage::into_unencrypted_opaque
Was fn into_unencrypted_opaque(self) -> OpaqueMessage; now fn into_unencrypted_opaque(self) -> OutboundOpaqueMessage. crates.io - Signature changed
rustls::internal::msgs::message::PlainMessage::payload
Was payload: Payload; now payload: Payload<'static>. crates.io - Signature changed
rustls::OtherError
Was struct OtherError(pub Arc<dyn StdError + Send + Sync>); now struct OtherError(#[cfg(feature = "std")] pub Arc<dyn StdError + Send + Sync>). crates.io - Signature changed
rustls::server::Accepted::into_connection
Was fn into_connection(mut self, config: Arc<ServerConfig>) -> Result<ServerConnection, Error>; now fn into_connection(mut self, config: Arc<ServerConfig>) -> Result<ServerConnection, (Error, AcceptedAlert)>. crates.io - Signature changed
rustls::server::Acceptor::accept
Was fn accept(&mut self) -> Result<Option<Accepted>, Error>; now fn accept(&mut self) -> Result<Option<Accepted>, (Error, AcceptedAlert)>. crates.io
rustls 0.22.0 breaking changes
- Signature changed
rustls::CertificateError::Other
Was Other(Arc<dyn StdError + Send + Sync>); now Other(OtherError). crates.io - Signature changed
rustls::CertRevocationListError::Other
Was Other(Arc<dyn StdError + Send + Sync>); now Other(OtherError). crates.io - Signature changed
rustls::client::ClientConfig::builder
Was fn builder() -> ConfigBuilder<Self, WantsCipherSuites>; now fn builder() -> ConfigBuilder<Self, WantsVerifier>. crates.io - Signature changed
rustls::client::ClientConfig::dangerous
Was fn dangerous(&mut self) -> danger::DangerousClientConfig; now fn dangerous(&mut self) -> danger::DangerousClientConfig<'_>. crates.io - Signature changed
rustls::client::ClientConnection::new
Was fn new(config: Arc<ClientConfig>, name: ServerName) -> Result<Self, Error>; now fn new(config: Arc<ClientConfig>, name: ServerName<'static>) -> Result<Self, Error>. crates.io - Signature changed
rustls::client::ClientSessionStore
Was trait ClientSessionStore: Send + Sync; now trait ClientSessionStore: fmt::Debug + Send + Sync. crates.io - Signature changed
rustls::client::ClientSessionStore::insert_tls13_ticket
Was fn insert_tls13_ticket(&self, server_name: &ServerName, value: persist::Tls13ClientSessionValue); now fn insert_tls13_ticket(&self, server_name: ServerName<'static>, value: persist::Tls13ClientSessionValue). crates.io - Signature changed
rustls::client::ClientSessionStore::kx_hint
Was fn kx_hint(&self, server_name: &ServerName) -> Option<NamedGroup>; now fn kx_hint(&self, server_name: &ServerName<'_>) -> Option<NamedGroup>. crates.io - Signature changed
rustls::client::ClientSessionStore::remove_tls12_session
Was fn remove_tls12_session(&self, server_name: &ServerName); now fn remove_tls12_session(&self, server_name: &ServerName<'static>). crates.io - Signature changed
rustls::client::ClientSessionStore::set_kx_hint
Was fn set_kx_hint(&self, server_name: &ServerName, group: NamedGroup); now fn set_kx_hint(&self, server_name: ServerName<'static>, group: NamedGroup). crates.io
And 48 more in this version. Sign up to see every change
rustls 0.21.0 breaking changes
- Removed
rustls::client::ClientConfig::enable_tickets
rustls::client::ClientConfig::enable_tickets was removed in rustls 0.21.0 crates.io - Removed
rustls::client::ClientConfig::session_storage
rustls::client::ClientConfig::session_storage was removed in rustls 0.21.0 crates.io - Removed
rustls::client::ClientQuicExt
rustls::client::ClientQuicExt was removed in rustls 0.21.0 crates.io - Removed
rustls::client::NoClientSessionStorage
rustls::client::NoClientSessionStorage was removed in rustls 0.21.0 crates.io - Removed
rustls::client::StoresClientSessions
rustls::client::StoresClientSessions was removed in rustls 0.21.0 crates.io - Removed
rustls::ClientConfig::enable_tickets
rustls::ClientConfig::enable_tickets was removed in rustls 0.21.0 crates.io - Removed
rustls::ClientConfig::session_storage
rustls::ClientConfig::session_storage was removed in rustls 0.21.0 crates.io - Removed
rustls::CommonState::write_tls
rustls::CommonState::write_tls was removed in rustls 0.21.0 crates.io - Removed
rustls::DigitallySignedStruct::new
rustls::DigitallySignedStruct::new was removed in rustls 0.21.0 crates.io - Removed
rustls::DigitallySignedStruct::sig
Use signature instead. crates.io
And 125 more in this version. Sign up to see every change
Check your code
These are the changes. To see which of them reach your code, scan a public repository, or have your coding agent call check_code with your manifest or lockfile over MCP. The API reads every change in every version. A fix pull request opens for the changes that reach a connected repository. Nothing merges or deploys.

Put your code on continuous maintenance.
Scan a public repository now, or give your agent one line.
See how out of date your code is.
Tell your agent what changed since it was trained.
claude mcp add --transport http since https://api.since.dev/mcpCodex, Cursor and any MCP client use https://api.since.dev/mcp.