]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
Input: yealink - validate number of endpoints before using them
authorJohan Hovold <johan@kernel.org>
Thu, 16 Mar 2017 18:37:01 +0000 (11:37 -0700)
committerJiri Slaby <jslaby@suse.cz>
Fri, 7 Apr 2017 08:38:24 +0000 (10:38 +0200)
commit8d729b51992462516eb1aa784bd5ff54c3f940c2
treefc1b6efde52cdb0e760c0a1e6de58ffb54c45e67
parent006c02072edb31b1a0668946a93d425fffba61c9
Input: yealink - validate number of endpoints before using them

commit 5cc4a1a9f5c179795c8a1f2b0f4361829d6a070e upstream.

Make sure to check the number of endpoints to avoid dereferencing a
NULL-pointer should a malicious device lack endpoints.

Fixes: aca951a22a1d ("[PATCH] input-driver-yealink-P1K-usb-phone")
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
drivers/input/misc/yealink.c