pull/37400/head
Craig Tiller 4 months ago
parent 1514a1cf89
commit deb205faf5
  1. 11
      src/core/tsi/fake_transport_security.cc

@ -18,19 +18,21 @@
#include "src/core/tsi/fake_transport_security.h"
#include <grpc/support/alloc.h>
#include <grpc/support/port_platform.h>
#include <stdlib.h>
#include <string.h>
#include "absl/log/check.h"
#include "absl/log/log.h"
#include <grpc/support/alloc.h>
#include <grpc/support/port_platform.h>
#include "src/core/lib/gprpp/crash.h"
#include "src/core/lib/gprpp/dump_args.h"
#include "src/core/lib/gprpp/memory.h"
#include "src/core/lib/slice/slice_internal.h"
#include "src/core/tsi/transport_security_grpc.h"
#include "src/core/tsi/transport_security_interface.h"
#include "absl/log/check.h"
#include "absl/log/log.h"
// --- Constants. ---
#define TSI_FAKE_FRAME_HEADER_SIZE 4
@ -209,7 +211,6 @@ static tsi_result tsi_fake_frame_decode(const unsigned char* incoming_bytes,
frame->offset += to_read_size;
available_size -= to_read_size;
frame->size = load32_little_endian(frame->data);
LOG(INFO) << "frame->size: " << frame->size;
if (frame->size < 4) return TSI_DATA_CORRUPTED;
if (frame->size > 16 * 1024 * 1024) return TSI_DATA_CORRUPTED;
tsi_fake_frame_ensure_size(frame);

Loading…
Cancel
Save