Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E7BCB125D6 for ; Thu, 1 May 2025 14:11:54 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1746108715; cv=none; b=CBgukefZEg/zfeoInfUROKx63ycRWPMG4GO3PYBsrViY4r2JRxFrBarLN3CRt1xHPb6UH7PY8yxvm4OFCTiDHbbmlvC9XWJzd0hLqVwPZhhK/xEpfqjNsNe7/hyiufNezajGaMyRXAGHUdxphDzADJBOJkQ9cHuaw3YkHgLtjIU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1746108715; c=relaxed/simple; bh=ZSMwXbXoHkFp75VY5UfGB5SIVJMnXSlBv6xWjZtaywg=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=dstqUr0B3cuWw/pl4fAKOPVVDJik+Yre/KKTmf9zlhxGd/KBZSf5l9yTVSZepVeH/hL1gsDjYFz8vG/zMb3Ovcczv+HUg1MhCYP/BSV92u+V6flPuuLkg/zc2oIgy9zbIjN1xM7SCVBn+m85VweQa74AoWvCP4UYpuDgmVyZdZ8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=1F7rVtC3; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="1F7rVtC3" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 56A1AC4CEE3; Thu, 1 May 2025 14:11:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1746108714; bh=ZSMwXbXoHkFp75VY5UfGB5SIVJMnXSlBv6xWjZtaywg=; h=From:To:Cc:Subject:Date:Reply-to:From; b=1F7rVtC3Ap5Ym/Cp5EWLV8Xo74lgY6Oe4uJ3ZMzE9oPqumO2Nd6xcd5clIoXR8w0a BY0VwXHW7ywF+9vkqEfa2UurhlSQGqImG/do6SUbnVBXdY+zzb3xcFJ7uBq5QPjy/n lnAcqkFSlco1/K5VhKjfQzY2BTS6CbTMueAe0QGE= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2022-49790: Input: iforce - invert valid length check when fetching device IDs Date: Thu, 1 May 2025 16:09:40 +0200 Message-ID: <2025050122-CVE-2022-49790-fb22@gregkh> X-Mailer: git-send-email 2.49.0 Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Reply-to: , X-Developer-Signature: v=1; a=openpgp-sha256; l=2865; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=K2VKNQa5wEs3m7A9CM9QBOQy/7pZwfUVL/KqHc4ztog=; b=owGbwMvMwCRo6H6F97bub03G02pJDBnCDZMavvRz3t8tL6j6fMYCaU3vXUadhkqb193wX/e3+ pzMHKUVHbEsDIJMDLJiiixftvEc3V9xSNHL0PY0zBxWJpAhDFycAjCRS68Z5tnO3Gu3uMW7kvOh Z7VTYvy6z/xFlxgWnD5prCq27cvLoPP+k+Z2rtw+mUf3MgA= X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: Input: iforce - invert valid length check when fetching device IDs syzbot is reporting uninitialized value at iforce_init_device() [1], for commit 6ac0aec6b0a6 ("Input: iforce - allow callers supply data buffer when fetching device IDs") is checking that valid length is shorter than bytes to read. Since iforce_get_id_packet() stores valid length when returning 0, the caller needs to check that valid length is longer than or equals to bytes to read. The Linux kernel CVE team has assigned CVE-2022-49790 to this issue. Affected and fixed versions =========================== Issue introduced in 5.3 with commit 6ac0aec6b0a651d64eef759fddf17d9145b51033 and fixed in 5.4.225 with commit 5d53797ce7ce8fb1d95a5bebc5efa9418c4217a3 Issue introduced in 5.3 with commit 6ac0aec6b0a651d64eef759fddf17d9145b51033 and fixed in 5.10.156 with commit 24cc679abbf31477d0cc6106ec83c2fbae6b3cdf Issue introduced in 5.3 with commit 6ac0aec6b0a651d64eef759fddf17d9145b51033 and fixed in 5.15.80 with commit fdd57c20d4408cac3c3c535c120d244e083406c9 Issue introduced in 5.3 with commit 6ac0aec6b0a651d64eef759fddf17d9145b51033 and fixed in 6.0.10 with commit 6365569d62a75ddf53fb0c2936c16587a365984c Issue introduced in 5.3 with commit 6ac0aec6b0a651d64eef759fddf17d9145b51033 and fixed in 6.1 with commit b8ebf250997c5fb253582f42bfe98673801ebebd Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2022-49790 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: drivers/input/joystick/iforce/iforce-main.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/5d53797ce7ce8fb1d95a5bebc5efa9418c4217a3 https://git.kernel.org/stable/c/24cc679abbf31477d0cc6106ec83c2fbae6b3cdf https://git.kernel.org/stable/c/fdd57c20d4408cac3c3c535c120d244e083406c9 https://git.kernel.org/stable/c/6365569d62a75ddf53fb0c2936c16587a365984c https://git.kernel.org/stable/c/b8ebf250997c5fb253582f42bfe98673801ebebd