]> git.ipfire.org Git - thirdparty/linux.git/commit
cifs: Fix use-after-free in SMB2_read
authorZhangXiaoxu <zhangxiaoxu5@huawei.com>
Sat, 6 Apr 2019 07:47:39 +0000 (15:47 +0800)
committerSteve French <stfrench@microsoft.com>
Tue, 16 Apr 2019 14:38:21 +0000 (09:38 -0500)
commit088aaf17aa79300cab14dbee2569c58cfafd7d6e
tree2df560323e5b037a268ada67ab3cc84fb7b35eb3
parent6a3eb3360667170988f8a6477f6686242061488a
cifs: Fix use-after-free in SMB2_read

There is a KASAN use-after-free:
BUG: KASAN: use-after-free in SMB2_read+0x1136/0x1190
Read of size 8 at addr ffff8880b4e45e50 by task ln/1009

Should not release the 'req' because it will use in the trace.

Fixes: eccb4422cf97 ("smb3: Add ftrace tracepoints for improved SMB3 debugging")
Signed-off-by: ZhangXiaoxu <zhangxiaoxu5@huawei.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
CC: Stable <stable@vger.kernel.org> 4.18+
Reviewed-by: Pavel Shilovsky <pshilov@microsoft.com>
fs/cifs/smb2pdu.c