-
Notifications
You must be signed in to change notification settings - Fork 736
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
lib, qlog: Track and Log Unknown Transport Parameters #1861
base: master
Are you sure you want to change the base?
Conversation
@LPardue Let me know what you think about the direction of this PR. If you think that it is on the right track, I will gladly do whatever you say so that it meets the high standards of the code that you have already written in this library. In re: quicwg/qlog#436 and (potentially) quicwg/qlog#176. |
13da4a9
to
7e6b807
Compare
quiche/src/lib.rs
Outdated
_ => (), | ||
// Track unknown transport parameters specially. | ||
unknown_tp_id => { | ||
tp.unknown_params.push(UnknownTransportParameter { |
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.
we probably want to put an upper bound on the number of these that we would store, because I don't think there's limit in TLS (other than the full length of the QUIC crypto stream).
I don't know what the bounds should be right now, but as inspiration we have something alongthe same lines for SETTINGS -
Line 50 in 9ea2152
const MAX_SETTINGS_PAYLOAD_SIZE: usize = 256; |
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.
Let me know if you like the latest revision. I decided against using smallvec
because I don't think that users will see unknown parameters often enough to warrant pre-allocating space for any entries.
quiche/src/lib.rs
Outdated
@@ -8952,6 +8989,7 @@ mod tests { | |||
initial_source_connection_id: Some(b"woot woot".to_vec().into()), | |||
retry_source_connection_id: Some(b"retry".to_vec().into()), | |||
max_datagram_frame_size: Some(32), | |||
unknown_params: vec![], |
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.
Its sad we can't test this, but that's because we don't allow apps to send unknown values via the quiche API. I was partly suprised to see we don't send grease TPS (https://datatracker.ietf.org/doc/html/rfc9000#name-reserved-transport-paramete) so maybe that's something we could consider. Although maybe doing it separately might be wise (and the tests could be updated if/when that happens)
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 believe that I have found a way to do at least a little testing on the new feature. Let me know what you think!
1e51a7a
to
8e69291
Compare
8e69291
to
82ec65f
Compare
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.
Overall looks like its headed in the right direction. Left a few comments to help tighten up the defensiveness of the code.
90c52bc
to
1394996
Compare
1394996
to
746c9cb
Compare
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.
Looking good, just a few minor things to harden it up a bit more.
746c9cb
to
c17adb1
Compare
Sorry it took me so long, @LPardue ! If this version looks okay, I will start in on determining how to handle FFI! |
c17adb1
to
708c724
Compare
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.
a few little nits but otherwise very close
Track (and make available to qlog for logging) transport parameters and their values that this implementation does not specifically recognize.
708c724
to
272230d
Compare
Track (and make available to qlog for logging) transport parameters and their values that this implementation does not specifically recognize.