summaryrefslogtreecommitdiff
path: root/chromium/net/third_party/quiche/src/quic/core/quic_versions.h
diff options
context:
space:
mode:
Diffstat (limited to 'chromium/net/third_party/quiche/src/quic/core/quic_versions.h')
-rw-r--r--chromium/net/third_party/quiche/src/quic/core/quic_versions.h31
1 files changed, 20 insertions, 11 deletions
diff --git a/chromium/net/third_party/quiche/src/quic/core/quic_versions.h b/chromium/net/third_party/quiche/src/quic/core/quic_versions.h
index de5bbea167c..0a4022e2006 100644
--- a/chromium/net/third_party/quiche/src/quic/core/quic_versions.h
+++ b/chromium/net/third_party/quiche/src/quic/core/quic_versions.h
@@ -82,10 +82,9 @@ enum QuicTransportVersion {
// Version 38 switched to IETF padding frame format and support for NSTP (no
// stop waiting frame) connection option.
- QUIC_VERSION_39 = 39, // Integers and floating numbers are written in big
- // endian. Dot not ack acks. Send a connection level
- // WINDOW_UPDATE every 20 sent packets which do not
- // contain retransmittable frames.
+ // Version 39 writes integers and floating numbers in big endian, stops acking
+ // acks, sends a connection level WINDOW_UPDATE every 20 sent packets which do
+ // not contain retransmittable frames.
// Version 40 was an attempt to convert QUIC to IETF frame format; it was
// never shipped due to a bug.
@@ -103,7 +102,7 @@ enum QuicTransportVersion {
QUIC_VERSION_46 = 46, // Use IETF draft-17 header format with demultiplexing
// bit.
- QUIC_VERSION_47 = 47, // Allow variable-length QUIC connection IDs.
+ // Version 47 added variable-length QUIC server connection IDs.
QUIC_VERSION_48 = 48, // Use CRYPTO frames for the handshake.
QUIC_VERSION_49 = 49, // Client connection IDs, long header lengths, IETF
// header format from draft-ietf-quic-invariants-06.
@@ -120,7 +119,7 @@ enum QuicTransportVersion {
};
// IETF draft version most closely approximated by TLS + v99.
-static const int kQuicIetfDraftVersion = 23;
+static const int kQuicIetfDraftVersion = 24;
// The crypto handshake protocols that can be used with QUIC.
enum HandshakeProtocol {
@@ -135,10 +134,12 @@ struct QUIC_EXPORT_PRIVATE ParsedQuicVersion {
HandshakeProtocol handshake_protocol;
QuicTransportVersion transport_version;
- ParsedQuicVersion(HandshakeProtocol handshake_protocol,
- QuicTransportVersion transport_version);
+ constexpr ParsedQuicVersion(HandshakeProtocol handshake_protocol,
+ QuicTransportVersion transport_version)
+ : handshake_protocol(handshake_protocol),
+ transport_version(transport_version) {}
- ParsedQuicVersion(const ParsedQuicVersion& other)
+ constexpr ParsedQuicVersion(const ParsedQuicVersion& other)
: handshake_protocol(other.handshake_protocol),
transport_version(other.transport_version) {}
@@ -192,6 +193,9 @@ struct QUIC_EXPORT_PRIVATE ParsedQuicVersion {
// i.e., server will send no more than FLAGS_quic_anti_amplification_factor
// times received bytes until address can be validated.
bool SupportsAntiAmplificationLimit() const;
+
+ // Returns true if this version can send coalesced packets.
+ bool CanSendCoalescedPackets() const;
};
QUIC_EXPORT_PRIVATE ParsedQuicVersion UnsupportedQuicVersion();
@@ -215,8 +219,8 @@ using QuicVersionLabelVector = std::vector<QuicVersionLabel>;
//
// See go/new-quic-version for more details on how to roll out new versions.
static const QuicTransportVersion kSupportedTransportVersions[] = {
- QUIC_VERSION_99, QUIC_VERSION_50, QUIC_VERSION_49, QUIC_VERSION_48,
- QUIC_VERSION_47, QUIC_VERSION_46, QUIC_VERSION_43, QUIC_VERSION_39,
+ QUIC_VERSION_99, QUIC_VERSION_50, QUIC_VERSION_49,
+ QUIC_VERSION_48, QUIC_VERSION_46, QUIC_VERSION_43,
};
// This vector contains all crypto handshake protocols that are supported.
@@ -416,6 +420,11 @@ QUIC_EXPORT_PRIVATE inline bool VersionHasIetfQuicFrames(
QUIC_EXPORT_PRIVATE bool VersionHasLengthPrefixedConnectionIds(
QuicTransportVersion transport_version);
+// Returns true if this version supports the old Google-style Alt-Svc
+// advertisement format.
+QUIC_EXPORT_PRIVATE bool VersionSupportsGoogleAltSvcFormat(
+ QuicTransportVersion transport_version);
+
// Returns whether this version label supports long header 4-bit encoded
// connection ID lengths as described in draft-ietf-quic-invariants-05 and
// draft-ietf-quic-transport-21.