summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorShengzhuo Wei <me@cherr.cc>2026-04-25 04:29:24 +0800
committerJohannes Berg <johannes.berg@intel.com>2026-09-24 16:21:50 +0200
commitaf20aad1ddcea3e74a1c779a84a57fc9e9cbdd08 (patch)
tree090faf29fda3161a1b1e8f85da469dd76a466846 /tools/perf/scripts/python
parent9756ecdbffe61797fe1c81bc62ca48eaa27d4055 (diff)
um: mconsole: Fix out-of-bounds read in mconsole_log()
mconsole_parse() matches the 3-byte prefix "log", but mconsole_log() skips strlen("log ") = 4 bytes, advancing ptr past the NUL terminator when a client sends "log" without a trailing space. The length then comes from req->len, the raw recvfrom() count, instead of req->request.len, so printk() reads up to req->len - 4 bytes of stale data from a previous request left in the static mc_request buffer, leaking it to the kernel log. Use req->cmd->command for the actual command length, add skip_spaces(), use req->request.len, and guard against non-positive length. Signed-off-by: Shengzhuo Wei <me@cherr.cc> Link: https://patch.msgid.link/20260425-mconsole-oob-read-leak-v1-1-7d46e5892c5c@cherr.cc Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions