Skip to content

Instantly share code, notes, and snippets.

@keepsimple1
Last active January 16, 2020 21:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save keepsimple1/58d2c0e2e4a0c6ddbcf4b67591274f43 to your computer and use it in GitHub Desktop.
Save keepsimple1/58d2c0e2e4a0c6ddbcf4b67591274f43 to your computer and use it in GitHub Desktop.
Chromium cronet patch to support IEFT QUIC draft-24 in iOS
diff --git a/components/cronet/url_request_context_config.cc b/components/cronet/url_request_context_config.cc
index 317c0b4126..f839485599 100644
--- a/components/cronet/url_request_context_config.cc
+++ b/components/cronet/url_request_context_config.cc
@@ -218,8 +218,11 @@ quic::ParsedQuicVersionVector ParseQuicVersions(
auto it = all_supported_versions.begin();
while (it != all_supported_versions.end()) {
if (quic::QuicVersionToString(*it) == version) {
+ quic::HandshakeProtocol handshake_protocol = quic::PROTOCOL_QUIC_CRYPTO;
+ if (*it == quic::QUIC_VERSION_99)
+ handshake_protocol = quic::PROTOCOL_TLS1_3;
supported_versions.push_back(
- quic::ParsedQuicVersion(quic::PROTOCOL_QUIC_CRYPTO, *it));
+ quic::ParsedQuicVersion(handshake_protocol, *it));
// Remove the supported version to deduplicate versions extracted from
// |quic_versions|.
all_supported_versions.erase(it);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment