feat(dtls): add restart() for DTLS re-handshake after ICE restart#82
Open
nightness wants to merge 1 commit intowebrtc-rs:masterfrom
Open
feat(dtls): add restart() for DTLS re-handshake after ICE restart#82nightness wants to merge 1 commit intowebrtc-rs:masterfrom
nightness wants to merge 1 commit intowebrtc-rs:masterfrom
Conversation
… on ICE restart When ICE restarts the underlying path can change while the DTLS session stays alive (RFC 8842: DTLS is not required to restart on ICE restart). However, if the DTLS session was already Failed, Closed, or lost mid- handshake before ICE re-establishes, the client-side connect() will never fire again because dtls_handshake_config was consumed by the first ICESelectedCandidatePairChange. Changes: - Refactor make_handshake_config() from prepare_transport() so the config can be rebuilt without the state==New guard - Add DTLSTransport::restart(): no-ops if Connected (live session survives ICE restart transparently); replaces endpoint and restores dtls_handshake_config if state is Failed/Closed/Connecting-but-lost - Call dtls_transport_mut().restart() from set_remote_description when ICE credentials change during renegotiation Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
DTLSTransport::restart()method to trigger a full DTLS re-handshakeTest plan
cargo test -p rtc dtlsrestart()triggers a new DTLS handshake🤖 Generated with Claude Code