{"id":"CVE-2026-100053","aliases":["CVE-2026-100053"],"related":[],"kind":"vulnerability","state":"published","title":"ublk: let STOP_DEV cancel the server's commands before its release","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nublk: let STOP_DEV cancel the server's commands before its release\n\nSTOP_DEV cancels the fetched commands after dropping ub->mutex, so\nSTART_DEV and FETCH can run in between:\n\n  STOP_DEV                          START_DEV / FETCH\n  lock ub->mutex\n    ublk_stop_dev_unlocked()        (not started: does nothing)\n  unlock ub->mutex\n                                    START_DEV goes live, schedules scan\n                                    FETCH publishes a new command\n  cancel_work_sync(scan)            cancels the new disk's scan\n  ublk_cancel_dev()                 takes the new command: NULL io->cmd\n                                    on a queue which isn't canceling\n\nA START_DEV after STOP_DEV also goes live over the canceled commands.\n\nHold a reference on the server's /dev/ublkcN while canceling:\n\n  STOP_DEV\n  lock ub->mutex\n    ublk_stop_dev_unlocked()\n    cancel_work_sync(scan)\n    server attached: take a reference on its file, set STOPPING\n  unlock ub->mutex\n  ublk_cancel_dev()\n  drop the reference\n\n - STOPPING makes FETCH and PREP get UBLK_IO_RES_ABORT and START_DEV\n   -EBUSY; a START_DEV or END_USER_RECOVERY waiting for the device\n   to get ready wakes up too; the reset in the server's release\n   clears it\n - the release can't run before the reference is dropped, so no new\n   server can attach, and the cancel only meets this server's commands\n - the cancel still runs after the unlock: io_uring_cmd_done() may take\n   uring_lock, under which FETCH takes ub->mutex\n\nublk_ch_open() saves the file in ->ch_file and ublk_ch_release() clears\nit, under cancel_mutex. The release runs after the last reference is\ngone, so take ours with file_ref_get(). Drop it with __fput_sync(): if\nit is the last one, fput() would defer the release to this task, which\nDEL_DEV then makes wait for the device to be freed.\n\nA server which opened the device but hasn't fetched is stopped too.\nDocument what a server sees after STOP_DEV in ublk.rst.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nublk: let STOP_DEV cancel the server's commands before its release\n\nSTOP_DEV cancels the fetched commands after dropping ub->mutex, so\nSTART_DEV and FETCH can run in between:\n\n  STOP_DEV                          START_DEV / FETCH\n  lock ub->mutex\n    ublk_stop_dev_unlocked()        (not started: does nothing)\n  unlock ub->mutex\n                                    START_DEV goes live, schedules scan\n                                    FETCH publishes a new command\n  cancel_work_sync(scan)            cancels the new disk's scan\n  ublk_cancel_dev()                 takes the new command: NULL io->cmd\n                                    on a queue which isn't canceling\n\nA START_DEV after STOP_DEV also goes live over the canceled commands.\n\nHold a reference on the server's /dev/ublkcN while canceling:\n\n  STOP_DEV\n  lock ub->mutex\n    ublk_stop_dev_unlocked()\n    cancel_work_sync(scan)\n    server attached: take a reference on its file, set STOPPING\n  unlock ub->mutex\n  ublk_cancel_dev()\n  drop the reference\n\n - STOPPING makes FETCH and PREP get UBLK_IO_RES_ABORT and START_DEV\n   -EBUSY; a START_DEV or END_USER_RECOVERY waiting for the device\n   to get ready wakes up too; the reset in the server's release\n   clears it\n - the release can't run before the reference is dropped, so no new\n   server can attach, and the cancel only meets this server's commands\n - the cancel still runs after the unlock: io_uring_cmd_done() may take\n   uring_lock, under which FETCH takes ub->mutex\n\nublk_ch_open() saves the file in ->ch_file and ublk_ch_release() clears\nit, under cancel_mutex. The release runs after the last reference is\ngone, so take ours with file_ref_get(). Drop it with __fput_sync(): if\nit is the last one, fput() would defer the release to this task, which\nDEL_DEV then makes wait for the device to be freed.\n\nA server which opened the device but hasn't fetched is stopped too.\nDocument what a server sees after STOP_DEV in ublk.rst.","source":"cvelist"}],"published":"2026-11-30T13:23:26.975Z","modified":"2026-12-01T06:17:21.790Z","severity":{"scorer":"Linux","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"},"severities":[{"scorer":"Linux","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"}],"cwes":[],"affected":[{"ranges":[{"type":"git","introduced":"85248d670b71d9edda9459ee14fdc85c8e9632c0","fixed":"e5d84d6ebec814039f40a0366a7272fd330678d4","status":"affected"},{"type":"git","introduced":"85248d670b71d9edda9459ee14fdc85c8e9632c0","fixed":"301e34ccf9a63705a197904ccc03e9eaaf442a37","status":"affected"},{"type":"git","introduced":"85248d670b71d9edda9459ee14fdc85c8e9632c0","fixed":"c8b349f9daf6d88ff21033028167d00e819dafb6","status":"affected"},{"type":"git","version":"a8555c86f508e0e246a2729fe0f40bdf9fc51da0","status":"affected"},{"type":"git","version":"8cb8ef0c79e3686320e2854c2ab9c9ab4df7b8e8","status":"affected"},{"type":"semver","introduced":"6.1.70","fixed":"6.2","status":"affected"},{"type":"semver","introduced":"6.6.21","fixed":"6.7","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"6.7","status":"affected"},{"type":"semver","introduced":"0","fixed":"6.7","status":"unaffected"},{"type":"semver","introduced":"6.18.66","lastAffected":"6.18.*","status":"unaffected"},{"type":"semver","introduced":"7.3.4","lastAffected":"7.3.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"7.4-rc1","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"}],"references":[{"url":"https://git.kernel.org/stable/c/e5d84d6ebec814039f40a0366a7272fd330678d4","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/301e34ccf9a63705a197904ccc03e9eaaf442a37","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/c8b349f9daf6d88ff21033028167d00e819dafb6","tags":[],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-100053","url":"https://www.cve.org/CVERecord?id=CVE-2026-100053","licence":"CVE Terms of Use","modified":"2026-12-01T05:39:58.978Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-100053","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-100053","licence":"Public domain","modified":"2026-12-01T06:17:21.790Z"}],"updatedAt":"2026-12-01T06:32:14.356Z","epss":{"score":0.00173,"percentile":0.07087,"date":"2026-12-01T12:00:22.000Z"}}