Skip to content

Commit

Permalink
x
Browse files Browse the repository at this point in the history
  • Loading branch information
ctiller committed Jan 26, 2025
1 parent 581e7bc commit a71b5e6
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/core/tsi/fake_transport_security.cc
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,10 @@ static tsi_result tsi_fake_frame_decode(const unsigned char* incoming_bytes,
frame->allocated_size = TSI_FAKE_FRAME_INITIAL_ALLOCATED_SIZE;
frame->data =
static_cast<unsigned char*>(gpr_malloc(frame->allocated_size));
// Initialize `data` to some recognizably bad values.
// There's some debug code paths where we stringify the entire buffer, and
// doing so leads to ubsan failures on those code paths -- which are
// commonly hit using fuzzers.
memset(frame->data, 0xab, frame->allocated_size);
}

Expand Down

0 comments on commit a71b5e6

Please sign in to comment.