-
-
Notifications
You must be signed in to change notification settings - Fork 10.4k
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
Augment RETRY validation token #26048
Conversation
d4170c8
to
e74f02d
Compare
I believe the failing coding style check is a known issue. It complains whether or not I have a if (hdr.token == NULL) {
port_send_retry(port, &e->peer, &hdr);
goto undesirable;
} else if (port_validate_token(&hdr, port, &e->peer, &odcid, &scid) != 1)
goto undesirable; |
e74f02d
to
dbdeac8
Compare
a482921
to
aaff6d4
Compare
The failure is because of the lack of braces around the else clause. Coding style has a rule that says, in an of/else pair, if you need curly braces around either branch, you should add them around both |
118bae4
to
19d4fc7
Compare
@nhorman The style check fails whether or not I have the curly braces around the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think changes are heading in right direction. Some of my suggestion can be done in follow-up PR.
8fa470c
to
13e67c2
Compare
021ca36
to
25e99da
Compare
@mattcaswell @nhorman please reconfirm |
ack, approval holds |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this should go in. looks good to me.
This pull request is ready to merge |
Squashed and merged to the feature branch. Thank you. |
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid. Also adds functionality to validate the token once returned by the client. Note that this does not encrypt the token yet. Also check that the RSCID stored in the RETRY validation token matches the DCID in the header. Reviewed-by: Neil Horman <[email protected]> Reviewed-by: Saša Nedvědický <[email protected]> Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Tomas Mraz <[email protected]> (Merged from #26048)
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid. Also adds functionality to validate the token once returned by the client. Note that this does not encrypt the token yet. Also check that the RSCID stored in the RETRY validation token matches the DCID in the header. Reviewed-by: Neil Horman <[email protected]> Reviewed-by: Saša Nedvědický <[email protected]> Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Tomas Mraz <[email protected]> (Merged from openssl#26048)
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid. Also adds functionality to validate the token once returned by the client. Note that this does not encrypt the token yet. Also check that the RSCID stored in the RETRY validation token matches the DCID in the header. Reviewed-by: Neil Horman <[email protected]> Reviewed-by: Saša Nedvědický <[email protected]> Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Tomas Mraz <[email protected]> (Merged from openssl#26048)
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid. Also adds functionality to validate the token once returned by the client. Note that this does not encrypt the token yet. Also check that the RSCID stored in the RETRY validation token matches the DCID in the header. Reviewed-by: Neil Horman <[email protected]> Reviewed-by: Saša Nedvědický <[email protected]> Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Tomas Mraz <[email protected]> (Merged from openssl#26048)
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid. Also adds functionality to validate the token once returned by the client. Note that this does not encrypt the token yet. Also check that the RSCID stored in the RETRY validation token matches the DCID in the header. Reviewed-by: Neil Horman <[email protected]> Reviewed-by: Saša Nedvědický <[email protected]> Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Tomas Mraz <[email protected]> (Merged from openssl#26048)
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid. Also adds functionality to validate the token once returned by the client. Note that this does not encrypt the token yet. Also check that the RSCID stored in the RETRY validation token matches the DCID in the header. Reviewed-by: Neil Horman <[email protected]> Reviewed-by: Saša Nedvědický <[email protected]> Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Tomas Mraz <[email protected]> (Merged from #26048)
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid. Also adds functionality to validate the token once returned by the client. Note that this does not encrypt the token yet. Also check that the RSCID stored in the RETRY validation token matches the DCID in the header. Reviewed-by: Neil Horman <[email protected]> Reviewed-by: Saša Nedvědický <[email protected]> Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Tomas Mraz <[email protected]> (Merged from openssl#26048)
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid. Also adds functionality to validate the token once returned by the client. Note that this does not encrypt the token yet. Also check that the RSCID stored in the RETRY validation token matches the DCID in the header. Reviewed-by: Neil Horman <[email protected]> Reviewed-by: Saša Nedvědický <[email protected]> Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Tomas Mraz <[email protected]> (Merged from openssl#26048)
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid. Also adds functionality to validate the token once returned by the client. Note that this does not encrypt the token yet. Also check that the RSCID stored in the RETRY validation token matches the DCID in the header. Reviewed-by: Neil Horman <[email protected]> Reviewed-by: Saša Nedvědický <[email protected]> Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Tomas Mraz <[email protected]> (Merged from openssl#26048)
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid. Also adds functionality to validate the token once returned by the client. Note that this does not encrypt the token yet. Also check that the RSCID stored in the RETRY validation token matches the DCID in the header. Reviewed-by: Neil Horman <[email protected]> Reviewed-by: Saša Nedvědický <[email protected]> Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Tomas Mraz <[email protected]> (Merged from #26048)
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid. Also adds functionality to validate the token once returned by the client. Note that this does not encrypt the token yet. Also check that the RSCID stored in the RETRY validation token matches the DCID in the header. Reviewed-by: Neil Horman <[email protected]> Reviewed-by: Saša Nedvědický <[email protected]> Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Tomas Mraz <[email protected]> (Merged from openssl#26048)
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid. Also adds functionality to validate the token once returned by the client. Note that this does not encrypt the token yet. Also check that the RSCID stored in the RETRY validation token matches the DCID in the header. Reviewed-by: Neil Horman <[email protected]> Reviewed-by: Saša Nedvědický <[email protected]> Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Tomas Mraz <[email protected]> (Merged from openssl#26048)
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid. Also adds functionality to validate the token once returned by the client. Note that this does not encrypt the token yet. Also check that the RSCID stored in the RETRY validation token matches the DCID in the header. Reviewed-by: Neil Horman <[email protected]> Reviewed-by: Saša Nedvědický <[email protected]> Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Tomas Mraz <[email protected]> (Merged from openssl#26048)
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid. Also adds functionality to validate the token once returned by the client. Note that this does not encrypt the token yet. Also check that the RSCID stored in the RETRY validation token matches the DCID in the header. Reviewed-by: Neil Horman <[email protected]> Reviewed-by: Saša Nedvědický <[email protected]> Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Tomas Mraz <[email protected]> (Merged from openssl#26048)
Adds fields to the QUIC RETRY packet validation token: timestamp, remote_addr, odcid, & rscid.
Also adds functionality to validate the token once returned by the client. Checks that the client address matches and that the token isn't expired (10 seconds for tokens from RETRY packets and 60 minutes for tokens from NEW_TOKEN packets, which may be configurable in the future).
Loosely based on quic-go: https://github.com/quic-go/quic-go/blob/master/internal/handshake/token_generator.go
Currently, a few tests never complete because the server receives the initial request but is unable to fetch the remote address of the client to create the RETRY token (the remote address of the peer is always NULL, which I'm assuming is an issue with the test itself). I'm currently working on resolving this: openssl/project#933
Note that this does not encrypt the token yet (openssl/project#928). Also, NEW_TOKEN_packets aren't sent by the server yet (openssl/project#929).
Fixes openssl/project#912
Checklist