Skip to content
Commit 7ed6c0c7 authored by Xiaoming Ni's avatar Xiaoming Ni Committed by Greg Kroah-Hartman
Browse files

nfc: fix memory leak in llcp_sock_connect()

commit 7574fcdb upstream.

In llcp_sock_connect(), use kmemdup to allocate memory for
 "llcp_sock->service_name". The memory is not released in the sock_unlink
label of the subsequent failure branch.
As a result, memory leakage occurs.

fix CVE-2020-25672

Fixes: d646960f

 ("NFC: Initial LLCP support")
Reported-by: default avatar"kiyin(尹亮)" <kiyin@tencent.com>
Link: https://www.openwall.com/lists/oss-security/2020/11/01/1


Cc: <stable@vger.kernel.org> #v3.3
Signed-off-by: default avatarXiaoming Ni <nixiaoming@huawei.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent a524eabb
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment