Pass PATH_CHALLENGE payload to QuicPacketCreator::SendPathChallenge() instead of getting it populated by this interface.
This changes the behavior in the old implementation of IETF connection migration. But it is not used in production.
PiperOrigin-RevId: 342098354
Change-Id: I8b719738184c49907e313d53bee0281546ca0fae
diff --git a/quic/core/quic_packet_creator.h b/quic/core/quic_packet_creator.h
index 54da59c..f1ace67 100644
--- a/quic/core/quic_packet_creator.h
+++ b/quic/core/quic_packet_creator.h
@@ -239,7 +239,8 @@
// SerializePathChallengeConnectivityProbingPacket will pad the packet to be
// MTU bytes long.
std::unique_ptr<SerializedPacket>
- SerializePathChallengeConnectivityProbingPacket(QuicPathFrameBuffer* payload);
+ SerializePathChallengeConnectivityProbingPacket(
+ const QuicPathFrameBuffer& payload);
// If |is_padded| is true then SerializePathResponseConnectivityProbingPacket
// will pad the packet to be MTU bytes long, else it will not pad the packet.
@@ -255,7 +256,7 @@
// Add PATH_CHALLENGE to current packet, flush before or afterwards if needed.
// This is a best effort adding. It may fail becasue of delegate state, but
// it's okay because of path validation retry mechanism.
- void AddPathChallengeFrame(QuicPathFrameBuffer* payload);
+ void AddPathChallengeFrame(const QuicPathFrameBuffer& payload);
// Returns a dummy packet that is valid but contains no useful information.
static SerializedPacket NoPacket();
@@ -432,8 +433,7 @@
size_t BuildPaddedPathChallengePacket(const QuicPacketHeader& header,
char* buffer,
size_t packet_length,
- QuicPathFrameBuffer* payload,
- QuicRandom* randomizer,
+ const QuicPathFrameBuffer& payload,
EncryptionLevel level);
// Serialize a probing response packet that uses IETF QUIC's PATH RESPONSE