CVE-2019-12521 Memory corruption in n/a
An off-by-one error in Squid's ESI parser causes a heap overflow, leading to a crash and denial of service.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2019-12521?
CVE-2019-12521 is a medium-severity memory corruption vulnerability in Canonical Ubuntu Linux, published on 15 Apr 2020. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
An issue was discovered in Squid through 4.7. When Squid is parsing ESI, it keeps the ESI elements in ESIContext. ESIContext contains a buffer for holding a stack of ESIElements. When a new ESIElement is parsed, it is added via addStackElement. addStackElement has a check for the number of elements in this buffer, but it's off by 1, leading to a Heap Overflow of 1 element. The overflow is within the same structure so it can't affect adjacent memory blocks, and thus just leads to a crash while processing.
Which versions are affected by CVE-2019-12521?
It affects 4 products.
Products include Canonical Ubuntu Linux, Debian Debian Linux, Opensuse Leap, Squid-Cache Squid.
How do I fix CVE-2019-12521?
Upgrade to a fixed version.
Upgrade to the fixed version. Memory-safe languages, compiler hardening and fuzzing prevent most new cases. More about Memory corruption.
Is CVE-2019-12521 being exploited?
There is no known exploitation of CVE-2019-12521 in the wild and no public exploit code.
Other vulnerabilities in Canonical Ubuntu Linux
Sources
Also known as ALPINE-CVE-2019-12521, DEBIAN-CVE-2019-12521, GHSA-7mv4-9v7r-5gq3, OESA-2022-1851, UBUNTU-CVE-2019-12521.