Skip to content

More perf.data header validation

Arnaldo Carvalho de Melo linux-perf-users lkml sashiko 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest5 patches 7 repliesIn review
  2. v14 patches 1 replySuperseded

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5perf header: Add section bounds checking to the fd read pathtools/perf/util/header.c+11 -61 reply
2/5perf header: Validate string length before allocating in do_read_string()tools/perf/util/header.c+3 -00 replies
3/5perf header: Sanity check HEADER_EVENT_DESCtools/perf/util/header.c+10 -01 reply
4/5perf header: Validate bitmap size before allocating in do_read_bitmap()tools/perf/util/header.c+5 -01 reply
5/5perf header: Fix 32-bit incompatibility in bitmap serializationtools/perf/util/header.c+20 -40 replies

Reviews trailers per patch

None of the 5 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchJames Clark
SeriesR-b
1/5
2/5
3/5
4/5
5/5

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCHES 0/5 v2] More perf.data header validation

Hi,

This is picking up from what was reported in the previous
series, pre-existing lack of perf.data file validation, processing files and buffers in header.c in a similar fashion.

There is more to process in the trace data, but that is a
different can of worms that needs to be dealt with in a similar, upcoming patch series,

This is probably 7.2 material, but if feeling this can still
sneak into 7.1, feel free to do it :-)

Now lets see what Sashiko discovers while I still don't have it
running locally right after Claude, before submitting it publicly, which will soon happen :-)

- Arnaldo

v2: Addressed sashiko comments, adding a patch to the series.

Arnaldo Carvalho de Melo (5):
perf header: Add section bounds checking to the fd read path perf header: Validate string length before allocating in do_read_string() perf header: Sanity check HEADER_EVENT_DESC
perf header: Validate bitmap size before allocating in do_read_bitmap() perf header: Fix 32-bit incompatibility in bitmap serialization

 tools/perf/util/header.c | 57 +++++++++++++++++++++++++++++++++-------
 1 file changed, 48 insertions(+), 9 deletions(-)
Signature · 1 line
2.53.0