Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support PSK after receiving HelloRetryRequest (HRR) #305

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

gaukas
Copy link
Contributor

@gaukas gaukas commented Jul 16, 2024

Currently there is no proper support for PSK if server sends a Hello Retry Request asking uTLS to switch to a different Key Share that is supported but not sent by default:

if len(hs.hello.pskIdentities) > 0 {
// TODO: wait for someone who cares about PSK to implement
return errors.New("uTLS does not support reprocessing of PSK key triggered by HelloRetryRequest")
}

This pull request adds support to handle PSK after seeing HRR.

Add UpdateOnHRR to allow PSK to recalculate its state using previously transcribed Client Hello's hash and client handshake state.

Signed-off-by: Gaukas Wang <i@gaukas.wang>
Signed-off-by: Gaukas Wang <i@gaukas.wang>
Signed-off-by: Gaukas Wang <i@gaukas.wang>
@gaukas gaukas added enhancement Feature with low severity but good value help wanted Calling for community PR/volunteer labels Jul 16, 2024
@gaukas gaukas self-assigned this Jul 16, 2024
@gaukas gaukas marked this pull request as draft July 16, 2024 08:42
@gaukas
Copy link
Contributor Author

gaukas commented Jul 16, 2024

To those who have contributed to uTLS recently regarding PSK-related topics, I would appreciate it if you'd like to share your thoughts on my change included in this PR.

cc: @adotkhan, @sleeyax, @VeNoMouS, @3andne

This is just an unordered, incomplete list of uTLS contributors on PSK. If you are not mentioned but would share your thoughts, please feel free to do so!

@VeNoMouS
Copy link
Contributor

Rgr Rgr, will try find some time this weekend to investigate and test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Feature with low severity but good value help wanted Calling for community PR/volunteer
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants