{"id":"CVE-2022-49870","aliases":["CVE-2022-49870"],"related":[],"kind":"vulnerability","state":"published","title":"capabilities: fix undefined behavior in bit shift for CAP_TO_MASK","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\ncapabilities: fix undefined behavior in bit shift for CAP_TO_MASK\n\nShifting signed 32-bit value by 31 bits is undefined, so changing\nsignificant bit to unsigned. The UBSAN warning calltrace like below:\n\nUBSAN: shift-out-of-bounds in security/commoncap.c:1252:2\nleft shift of 1 by 31 places cannot be represented in type 'int'\nCall Trace:\n <TASK>\n dump_stack_lvl+0x7d/0xa5\n dump_stack+0x15/0x1b\n ubsan_epilogue+0xe/0x4e\n __ubsan_handle_shift_out_of_bounds+0x1e7/0x20c\n cap_task_prctl+0x561/0x6f0\n security_task_prctl+0x5a/0xb0\n __x64_sys_prctl+0x61/0x8f0\n do_syscall_64+0x58/0x80\n entry_SYSCALL_64_after_hwframe+0x63/0xcd\n </TASK>","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\ncapabilities: fix undefined behavior in bit shift for CAP_TO_MASK\n\nShifting signed 32-bit value by 31 bits is undefined, so changing\nsignificant bit to unsigned. The UBSAN warning calltrace like below:\n\nUBSAN: shift-out-of-bounds in security/commoncap.c:1252:2\nleft shift of 1 by 31 places cannot be represented in type 'int'\nCall Trace:\n <TASK>\n dump_stack_lvl+0x7d/0xa5\n dump_stack+0x15/0x1b\n ubsan_epilogue+0xe/0x4e\n __ubsan_handle_shift_out_of_bounds+0x1e7/0x20c\n cap_task_prctl+0x561/0x6f0\n security_task_prctl+0x5a/0xb0\n __x64_sys_prctl+0x61/0x8f0\n do_syscall_64+0x58/0x80\n entry_SYSCALL_64_after_hwframe+0x63/0xcd\n </TASK>","source":"cvelist"},{"lang":"es","text":"En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: capacidades: corregir comportamiento indefinido en el cambio de bits para CAP_TO_MASK El cambio de un valor con signo de 32 bits por 31 bits no está definido, por lo que se cambia el bit significativo a sin signo. El seguimiento de llamadas de advertencia de UBSAN como se muestra a continuación: UBSAN: desplazamiento fuera de los límites en security/commoncap.c:1252:2 El desplazamiento a la izquierda de 1 por 31 lugares no se puede representar en el tipo 'int' Seguimiento de llamadas: dump_stack_lvl+0x7d/0xa5 dump_stack+0x15/0x1b ubsan_epilogue+0xe/0x4e __ubsan_handle_shift_out_of_bounds+0x1e7/0x20c cap_task_prctl+0x561/0x6f0 security_task_prctl+0x5a/0xb0 __x64_sys_prctl+0x61/0x8f0 do_syscall_64+0x58/0x80 entry_SYSCALL_64_after_hwframe+0x63/0xcd","source":"nvd"}],"published":"2025-05-01T14:10:21.134Z","modified":"2026-11-05T20:17:16.543Z","severity":{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:H","score":7.1,"rating":"HIGH"},"severities":[{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:H","score":7.1,"rating":"HIGH"}],"cwes":["CWE-125"],"affected":[{"ranges":[{"type":"git","introduced":"e338d263a76af78fe8f38a72131188b58fceb591","fixed":"5b79fa628e2ab789e629a83cd211ef9b4c1a593e","status":"affected"},{"type":"git","introduced":"e338d263a76af78fe8f38a72131188b58fceb591","fixed":"65b0bc7a0690861812ade523d19f82688ab819dc","status":"affected"},{"type":"git","introduced":"e338d263a76af78fe8f38a72131188b58fceb591","fixed":"dbaab08c8677d598244d21afb7818e44e1c5d826","status":"affected"},{"type":"git","introduced":"e338d263a76af78fe8f38a72131188b58fceb591","fixed":"5661f111a1616ac105ec8cec81bff99b60f847ac","status":"affected"},{"type":"git","introduced":"e338d263a76af78fe8f38a72131188b58fceb591","fixed":"fcbd2b336834bd24e1d9454ad5737856470c10d7","status":"affected"},{"type":"git","introduced":"e338d263a76af78fe8f38a72131188b58fceb591","fixed":"151dc8087b5609e53b069c068e3f3ee100efa586","status":"affected"},{"type":"git","introduced":"e338d263a76af78fe8f38a72131188b58fceb591","fixed":"27bdb134c043ff32c459d98f16550d0ffa0b3c34","status":"affected"},{"type":"git","introduced":"e338d263a76af78fe8f38a72131188b58fceb591","fixed":"46653972e3ea64f79e7f8ae3aa41a4d3fdb70a13","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"2.6.25","status":"affected"},{"type":"semver","introduced":"0","fixed":"2.6.25","status":"unaffected"},{"type":"semver","introduced":"4.9.334","lastAffected":"4.9.*","status":"unaffected"},{"type":"semver","introduced":"4.14.300","lastAffected":"4.14.*","status":"unaffected"},{"type":"semver","introduced":"4.19.267","lastAffected":"4.19.*","status":"unaffected"},{"type":"semver","introduced":"5.4.225","lastAffected":"5.4.*","status":"unaffected"},{"type":"semver","introduced":"5.10.155","lastAffected":"5.10.*","status":"unaffected"},{"type":"semver","introduced":"5.15.79","lastAffected":"5.15.*","status":"unaffected"},{"type":"semver","introduced":"6.0.9","lastAffected":"6.0.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"6.1","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"status":"affected","introduced":"2.6.25","fixed":"4.9.334"},{"status":"affected","introduced":"4.10","fixed":"4.14.300"},{"status":"affected","introduced":"4.15","fixed":"4.19.267"},{"status":"affected","introduced":"4.20","fixed":"5.4.225"},{"status":"affected","introduced":"5.5","fixed":"5.10.155"},{"status":"affected","introduced":"5.11","fixed":"5.15.79"},{"status":"affected","introduced":"5.16","fixed":"6.0.9"},{"status":"affected","version":"6.1"},{"status":"affected","version":"6.1"},{"status":"affected","version":"6.1"},{"status":"affected","version":"6.1"}],"vendor":"linux","product":"linux_kernel","cpe":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://git.kernel.org/stable/c/5b79fa628e2ab789e629a83cd211ef9b4c1a593e","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/65b0bc7a0690861812ade523d19f82688ab819dc","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/dbaab08c8677d598244d21afb7818e44e1c5d826","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/5661f111a1616ac105ec8cec81bff99b60f847ac","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/fcbd2b336834bd24e1d9454ad5737856470c10d7","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/151dc8087b5609e53b069c068e3f3ee100efa586","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/27bdb134c043ff32c459d98f16550d0ffa0b3c34","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/46653972e3ea64f79e7f8ae3aa41a4d3fdb70a13","tags":["patch"],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2026-11-05T19:50:57.705Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2022-49870","url":"https://www.cve.org/CVERecord?id=CVE-2022-49870","licence":"CVE Terms of Use","modified":"2026-11-05T20:00:10.236Z"},{"source":"nvd","name":"NVD","id":"CVE-2022-49870","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-49870","licence":"Public domain","modified":"2026-11-05T20:17:16.543Z"}],"updatedAt":"2026-11-25T22:58:20.911Z","epss":{"score":0.00292,"percentile":0.14323,"date":"2026-11-30T12:00:22.000Z"}}