summaryrefslogtreecommitdiff
path: root/chromium/net/quic/core/crypto/crypto_framer.h
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2018-05-03 13:42:47 +0200
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2018-05-15 10:27:51 +0000
commit8c5c43c7b138c9b4b0bf56d946e61d3bbc111bec (patch)
treed29d987c4d7b173cf853279b79a51598f104b403 /chromium/net/quic/core/crypto/crypto_framer.h
parent830c9e163d31a9180fadca926b3e1d7dfffb5021 (diff)
downloadqtwebengine-chromium-8c5c43c7b138c9b4b0bf56d946e61d3bbc111bec.tar.gz
BASELINE: Update Chromium to 66.0.3359.156
Change-Id: I0c9831ad39911a086b6377b16f995ad75a51e441 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
Diffstat (limited to 'chromium/net/quic/core/crypto/crypto_framer.h')
-rw-r--r--chromium/net/quic/core/crypto/crypto_framer.h17
1 files changed, 14 insertions, 3 deletions
diff --git a/chromium/net/quic/core/crypto/crypto_framer.h b/chromium/net/quic/core/crypto/crypto_framer.h
index 9ff70361959..a3c3d091494 100644
--- a/chromium/net/quic/core/crypto/crypto_framer.h
+++ b/chromium/net/quic/core/crypto/crypto_framer.h
@@ -15,6 +15,8 @@
#include "net/quic/core/crypto/crypto_message_parser.h"
#include "net/quic/core/quic_packets.h"
#include "net/quic/platform/api/quic_export.h"
+#include "net/quic/platform/api/quic_string.h"
+#include "net/quic/platform/api/quic_string_piece.h"
namespace net {
@@ -57,7 +59,7 @@ class QUIC_EXPORT_PRIVATE CryptoFramer : public CryptoMessageParser {
}
QuicErrorCode error() const override;
- const std::string& error_detail() const override;
+ const QuicString& error_detail() const override;
// Processes input data, which must be delivered in order. Returns
// false if there was an error, and true otherwise.
@@ -67,6 +69,15 @@ class QUIC_EXPORT_PRIVATE CryptoFramer : public CryptoMessageParser {
// parsed.
size_t InputBytesRemaining() const override;
+ // Checks if the specified tag has been seen. Returns |true| if it
+ // has, and |false| if it has not or a CHLO has not been seen.
+ bool HasTag(QuicTag tag) const;
+
+ // Even if the CHLO has not been fully received, force processing of
+ // the handshake message. This is dangerous and should not be used
+ // except as a mechanism of last resort.
+ void ForceHandshake();
+
// Returns a new QuicData owned by the caller that contains a serialized
// |message|, or nullptr if there was an error.
static QuicData* ConstructHandshakeMessage(
@@ -98,13 +109,13 @@ class QUIC_EXPORT_PRIVATE CryptoFramer : public CryptoMessageParser {
// Last error.
QuicErrorCode error_;
// Remaining unparsed data.
- std::string buffer_;
+ QuicString buffer_;
// Current state of the parsing.
CryptoFramerState state_;
// The message currently being parsed.
CryptoHandshakeMessage message_;
// The issue which caused |error_|
- std::string error_detail_;
+ QuicString error_detail_;
// Number of entires in the message currently being parsed.
uint16_t num_entries_;
// tags_and_lengths_ contains the tags that are currently being parsed and