summaryrefslogtreecommitdiff
path: root/tools/lib/python/kdoc/python_version.py
diff options
context:
space:
mode:
authorYoungsung Ahn <ays511.kr@gmail.com>2026-10-03 01:45:52 +0900
committerLeon Romanovsky <leon@kernel.org>2026-10-15 09:59:29 -0400
commitc887e53e1c852b88bd5442d1bf4717ee3e7aadda (patch)
treeb223d8a3cd76e5d1af1f807c8bad8d9bd8f1e9f9 /tools/lib/python/kdoc/python_version.py
parent56a27df6cedd4f3918969d61c7b9d3cc177b2d1b (diff)
RDMA/rxe: bound the WQE opcode before indexing rxe_wr_opcode_info[]
wr_opcode_mask() indexes the global rxe_wr_opcode_info[] array with a caller-supplied opcode and no bounds check. For a user QP the WQE comes from an mmap'd SQ ring, so wqe->wr.opcode is an attacker-controlled __u32 read back by the requester (req_next_wqe() -> rxe_requester()); rxe_post_send() takes the qp->is_user branch and never runs validate_send_wr(), whose only opcode check is itself !wr_opcode_mask() (it indexes before it checks). rxe_wr_opcode_info[] has entries only up to IB_WR_REG_MR, so an out-of-range opcode reads out of bounds and the result is used as a mask and dereferenced; observed as a KASAN global-out-of-bounds "Read of size 4" and a wild-pointer oops. Return a zero mask for an out-of-range opcode, matching how validate_send_wr() already treats a zero mask (an invalid WR), so no path indexes the array out of bounds. Fixes: 8700e3e7c485 ("Soft RoCE driver") Signed-off-by: Youngsung Ahn <ays511.kr@gmail.com> Link: https://patch.msgid.link/20261002164552.294749-1-ays511.kr@gmail.com Signed-off-by: Leon Romanovsky <leon@kernel.org>
Diffstat (limited to 'tools/lib/python/kdoc/python_version.py')
0 files changed, 0 insertions, 0 deletions