CVE-2022-0185: Detecting Linux Kernel vulnerability causing container escape
A heap overflow in the Linux kernel's Filesystem Context system allows a local attacker to write out of bounds by sending more than 4095 bytes to a legacy parameter parsing function. This can cause a denial of service, privilege escalation, or container escape, potentially giving full control of the host.
sysdig.com
Published on sysdig.com
Subscribe to Threat Research
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely an integer underflow in the legacy_parse_param function causes a length check to be bypassed, leading to an out-of-bounds write.
Impact
An attacker could cause a denial of service, escalate privileges, or escape a container to gain full control of the host and other containers, though seccomp may block the required capability acquisition.
What the attacker needed
Local access to the system; ability to run code (e.g., in a container); seccomp not blocking unshare
The fix
The vulnerability was fixed by installing the Linux kernel patch; if patching is not possible, disabling unprivileged user namespaces can mitigate it.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
A part of the Linux kernel that handles filesystem settings has a bug: it doesn't check the length of input properly, so a large input can overflow a buffer. This lets an attacker who can run code on the machine write to memory they shouldn't, which can crash the system or let them take control. In containers, this can be used to break out and control the host.
What is Memory corruption?
Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.