Description
In the Linux kernel, the following vulnerability has been resolved:

misc: nsm: only unlock nsm_dev on post-lock error paths

nsm_dev_ioctl() jumps to the common out label even when the initial
copy_from_user() fails before nsm->lock has been taken. The error path
then blindly unlocks a mutex that was never acquired.

This issue was found by our static analysis tool and then manually
reviewed against the current tree.

The grounded PoC kept the miscdevice ioctl entry and the pre-lock
copy_from_user(&raw, argp, _IOC_SIZE(cmd)) failure path by issuing
NSM_IOCTL_RAW with an invalid user pointer. That failure reaches the
shared out label before mutex_lock(&nsm->lock). Lockdep reported:

WARNING: bad unlock balance detected!
exploit/193 is trying to release lock (&global_nsm.lock) at:
nsm_dev_ioctl+0x5f/0xcf [vuln_msv]
but there are no more locks to release!
no locks held by exploit/193.

Return immediately on the pre-lock copy_from_user() failure and keep the
common unlock label for the post-lock paths only.
Published: 2026-08-10
Score: 8.4 High
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

The Linux kernel’s nsm character device contains a locking flaw that occurs when an ioctl fails before the mutex is acquired. The code flow jumps to a common unlock label even though the mutex was never locked, resulting in a bad unlock balance detected by lockdep and potentially a kernel panic that effectively terminates the host. Based on the description, the vulnerability can only be triggered through the misc device ioctl interface, indicating that the attack vector is local and requires an attacker to be able to invoke that ioctl.

Affected Systems

All Linux kernel releases that lack the commit fixing the nsm_dev_ioctl unlock bug are affected. The precise affected version range is not specified, so any kernel built before the remediation commit remains vulnerable.

Risk and Exploitability

The CVSS score is 8.4, the EPSS score of <1% indicates a very low probability of exploitation, and the vulnerability does not appear in the CISA KEV catalog. The flaw is rooted in an uncontrolled unlock (CWE‑832). Even though a kernel crash would cause significant disruption, the risk of an active exploit is modest because the vector is local and there is no public evidence of exploitation.

Generated by OpenCVE AI on August 13, 2026 at 23:44 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Apply a kernel update that contains the commit correcting the nsm_dev_ioctl unlock bug.
  • Reboot the system to ensure the patched kernel is running.
  • Verify that no unpatched kernel modules are loaded that could reintroduce the flaw.

Generated by OpenCVE AI on August 13, 2026 at 23:44 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Debian DLA Debian DLA DLA-4745-1 linux-6.12 security update
History

Thu, 13 Aug 2026 22:45:00 +0000

Type Values Removed Values Added
Metrics cvssV3_1

{'score': 8.4, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H'}


Thu, 13 Aug 2026 08:15:00 +0000

Type Values Removed Values Added
Weaknesses CWE-362

Wed, 12 Aug 2026 00:15:00 +0000


Mon, 10 Aug 2026 15:00:00 +0000

Type Values Removed Values Added
Weaknesses CWE-362

Mon, 10 Aug 2026 12:30:00 +0000

Type Values Removed Values Added
Description In the Linux kernel, the following vulnerability has been resolved: misc: nsm: only unlock nsm_dev on post-lock error paths nsm_dev_ioctl() jumps to the common out label even when the initial copy_from_user() fails before nsm->lock has been taken. The error path then blindly unlocks a mutex that was never acquired. This issue was found by our static analysis tool and then manually reviewed against the current tree. The grounded PoC kept the miscdevice ioctl entry and the pre-lock copy_from_user(&raw, argp, _IOC_SIZE(cmd)) failure path by issuing NSM_IOCTL_RAW with an invalid user pointer. That failure reaches the shared out label before mutex_lock(&nsm->lock). Lockdep reported: WARNING: bad unlock balance detected! exploit/193 is trying to release lock (&global_nsm.lock) at: nsm_dev_ioctl+0x5f/0xcf [vuln_msv] but there are no more locks to release! no locks held by exploit/193. Return immediately on the pre-lock copy_from_user() failure and keep the common unlock label for the post-lock paths only.
Title misc: nsm: only unlock nsm_dev on post-lock error paths
First Time appeared Linux
Linux linux Kernel
CPEs cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
Vendors & Products Linux
Linux linux Kernel
References

Subscriptions

Linux Linux Kernel
cve-icon MITRE

Status: PUBLISHED

Assigner: Linux

Published:

Updated: 2026-08-17T05:00:20.666Z

Reserved: 2026-07-30T09:28:09.373Z

Link: CVE-2026-68179

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-08-10T13:20:04.847

Modified: 2026-08-17T05:18:19.590

Link: CVE-2026-68179

cve-icon Redhat

Severity :

Publid Date: 2026-08-10T00:00:00Z

Links: CVE-2026-68179 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-08-13T23:45:16Z

Weaknesses
  • CWE-832

    Unlock of a Resource that is not Locked