libcss through 0.9.2 NULL Pointer Dereference via Media-Query Parser
Impact
libcss through 0.9.2 contains a NULL pointer dereference vulnerability in mq_parse_media_query() that allows remote attackers to crash consumers by supplying media lists ending in a comma. Attackers can serve a stylesheet whose @media or @import media list has a trailing comma, causing NetSurf or other parsers to crash.
Source excerpt · VulnCheckAffected packages
Affected products
Vendor version evidence. Product records are separate from automatic dependency matching.
netsurf-browser · libcss
Other versions: unaffected
| Version / range | Source status |
|---|---|
| 0 through 0.9.2 (inclusive) | affected |
Original source description
libcss through 0.9.2 contains a NULL pointer dereference vulnerability in mq_parse_media_query() that allows remote attackers to crash consumers by supplying media lists ending in a comma. Attackers can serve a stylesheet whose @media or @import media list has a trailing comma, causing NetSurf or other parsers to crash.
References
- Patch github.com/netsurf-browser/libcss/commit/006ffc4096040da13690abc380e5f828ec08284d
- Source reference github.com/netsurf-browser/libcss
- Source reference github.com/netsurf-browser/libcss/blob/release/0.9.2/src/parse/mq.c
- Source reference hackmd.io/@haindpwn/libcss-media-list-null-deref
- Security advisory www.vulncheck.com/advisories/libcss-through-0.9.2-null-pointer-dereference-via-media-query-parser