Repository navigation
Sync main with pion/dtls main - #4
Merged
Merged
Conversation
Route application data through the post-handshake command queue so KeyUpdate and application records have a single ordering point. Insert required KeyUpdate responses before queued application writes and take ownership of payload buffers before they enter the queue. Remove the pause/resume gate while keeping writes on the current epoch until a KeyUpdate ACK commits the next generation. Add queue-ordering, buffer-ownership, and end-to-end KeyUpdate coverage. Closes pion#996.
Verify stored server certificate chains and run peer and connection verification callbacks before accepting a resumed connection. Fall back to a full handshake when the cached certificate no longer passes normal verification or the peer callback, allowing certificate and pin rotation to succeed on the first connection attempt. Run the peer callback once for accepted resumption and check the server's actual certificate again when falling back to a full handshake. Port of v3 commit 93a9fd1. Discovered by Anthropic's OSS Scanner pion#1228
Deduplicate cached messages and limit the cache to 1,000 entries and 8 MB of payload. Stop accepting new entries after handshake completion while preserving the transcript for retransmissions. This is more generous than OpenSSL and other libraries limits. Port of v3 commit f444d08. Discovered by Anthropic's OSS Scanner pion#1228
Export the authenticated record high-water mark and reject earlier record numbers after restoring a connection. Use an allocated atomic counter to ensure 64-bit alignment on 32-bit systems while keeping State snapshots copyable. Port of v3 commit 66a9ff3. Discovered by Anthropic's OSS Scanner pion#1228
Hold ordinary application data until DetachedHandshakeDone, using the same single-record buffer as Conn. Preserve explicitly accepted 0-RTT and reject application records protected with DTLS 1.3 handshake keys. Fix ANT-2026-4IH0RRS4. Discovered by Anthropic's OSS Scanner pion#1228
Discard recoverable read errors instead of sending them to the unread Conn channel. Stop the detached read loop after connection closure. Fatal errors continue to report the terminal event. Fix ANT-2026-WEQ2A201. Discovered by Anthropic's OSS Scanner pion#1228
Retain one queued response to repeated peer requests. Keep application writes moving with the current write keys while another KeyUpdate awaits its ACK, then send the queued response when it becomes eligible. Preserve responses when local and peer KeyUpdates cross in flight. Update the existing response serialization test for coalescing. Fix ANT-2026-TFF4Y9G4. Discovered by Anthropic's OSS Scanner pion#1228
Generated by renovateBot
Mark the fragment buffer exhausted after delivering sequence 65535. Treat subsequent input as retransmissions, and prevent AdvanceTo from reopening the buffer so sequence numbers cannot be reused with new data. Fix ANT-2026-Y6TVSPKN. Discovered by Anthropic's OSS Scanner pion#1228
Port Gerard's v3 fix from commit 9311efd. Check that the ECDHE public key length byte exists after the PSK identity and copy only the declared key length. Add regression coverage for truncated identities and public keys, valid exchanges, and trailing bytes outside the declared key. Originally reported by @vnykmshr. Anthropic's OSS Scanner pion#1228 pointed out that we missed syncing this fix to main (ANT-2026-B12K67F6). Reported-by: @vnykmshr <viks@vnykmshr.com> Co-authored-by: Gerard <213731635+GerardGao@users.noreply.github.com>
Generated by renovateBot
Fix ANT-2026-I8U1NYZQ Discovered by Anthropic's OSS Scanner pion#1228.
Add 0xCCAC from RFC 7905 section 2, pairing the existing ECDHE_PSK key exchange with ChaCha20-Poly1305 record protection. OpenSSL calls it ECDHE-PSK-CHACHA20-POLY1305. Like the other ChaCha20 suites it is excluded in FIPS mode, and it is not a default suite.
As reproted by Antrhopic's OSS scanner (pion#1228) and @sirzooro ConnectionState() => Resume can cause nonce reuse, sadly this isn't fixable with the old API, so I'll document v3 as unsafe. for v4 Resume will require ExportState. which closes the stream without close_notify, and source can't be used again after export.
anunaym14
approved these changes
Oct 23, 2026
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.
Catches
mainup to upstream pion/dtlsmain(the DTLS 1.3 development line). Ourmainwas a copy of upstream from 2026-06-30 and is 365 commits behind; it is a strict ancestor, so this is a fast-forward in git terms.Changes
The org ruleset on
mainrequires a pull request and linear history, so a direct fast-forward push was refused. Merging this with "Rebase and merge" keeps the commits one to one but gives them new SHAs; "Squash" collapses them to one. Neither keeps upstream SHAs; a true mirror needs a bypass on the rule.Tests: upstream CI covers these commits; nothing LiveKit-specific to test.
State:
warp-3.1.15(upstream v3.1.15) and the WARP port in #3 do not depend on this branch.🤖 Generated with Claude Code