feat: implement 1-RTT key update management mechanism#679
Open
relaxing-more wants to merge 1 commit into
Open
Conversation
bcbd589 to
6b9f224
Compare
Signed-off-by: relaxing-more <2068804516@qq.com>
6b9f224 to
a0751f7
Compare
Codecov Report❌ Patch coverage is
... and 5 files with indirect coverage changes 🚀 New features to boost your workflow:
|
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.
根据QUIC协议标准,1rtt短包头的key phase位,每次翻转代表着密钥更新一次,结合这个机制,实现密钥更新管理。
主要变更
新增密钥更新触发控制
支持1-RTT数据包密钥更新
实现双密钥并行保留机制:接收端保留当前+下一组密钥,应对网络乱序
规范更新流程:发起方同时更新收发密钥;响应方先解密新包,再更新发送密钥,并在新包中确认
新增KEY_UPDATE_ERROR错误处理:连续未确认更新、密钥阶段错配、包号与密钥不匹配