aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/util/scripting-engines/trace-event-python.c
diff options
context:
space:
mode:
authorEric Biggers <[email protected]>2018-05-13 17:01:30 -0700
committerDavid S. Miller <[email protected]>2018-05-14 16:40:45 -0400
commitd49baa7e12ee70c0a7b821d088a770c94c02e494 (patch)
tree533f8add47270500c196ce5241e8d578283a4dc6 /tools/perf/util/scripting-engines/trace-event-python.c
parent57f6f99fdad9984801cde05c1db68fe39b474a10 (diff)
net/smc: check for missing nlattrs in SMC_PNETID messages
It's possible to crash the kernel in several different ways by sending messages to the SMC_PNETID generic netlink family that are missing the expected attributes: - Missing SMC_PNETID_NAME => null pointer dereference when comparing names. - Missing SMC_PNETID_ETHNAME => null pointer dereference accessing smc_pnetentry::ndev. - Missing SMC_PNETID_IBNAME => null pointer dereference accessing smc_pnetentry::smcibdev. - Missing SMC_PNETID_IBPORT => out of bounds array access to smc_ib_device::pattr[-1]. Fix it by validating that all expected attributes are present and that SMC_PNETID_IBPORT is nonzero. Reported-by: [email protected] Fixes: 6812baabf24d ("smc: establish pnet table management") Cc: <[email protected]> # v4.11+ Signed-off-by: Eric Biggers <[email protected]> Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'tools/perf/util/scripting-engines/trace-event-python.c')
0 files changed, 0 insertions, 0 deletions