# Muhammara NULL pointer dereference in LZWDecode filter

Source: https://junglewise.ai/threats/muhammara-null-pointer-dereference-in-lzwdecode-filter-ec14f183  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-06-26. Updated: 2026-09-25  
License: CC BY 4.0 with a link back

Severity: low · CVSS 3.1 · Published 2026-06-26

Muhammara is a PDF processing library used to parse and extract data from PDF documents. A specially crafted PDF file can cause the application to crash due to a NULL pointer dereference when processing LZW-compressed streams with missing optional parameters. This results in denial of service against any application using the library to read untrusted PDFs.

Technologies: [muhammara (npm)](https://junglewise.ai/threats/technologies/muhammara). Vendors: [npm](https://junglewise.ai/threats/vendors/npm).

## Quick answers

**Is This vulnerability exploited in the wild?** No. Junglewise Threat Intelligence has no report of This vulnerability being exploited in the wild.

**How severe is This vulnerability?** Low severity, with a CVSS score of 3.1, published 26 June 2026.

**Which products and versions are affected?** muhammara (npm) SEMVER:introduced=0,fixed=6.0.5.

**Is there a fix for This vulnerability?** Yes. muhammara (npm): upgrade to 6.0.5 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is This vulnerability attacked?** It is attacked over the network.

**Am I affected?** Check whether you run muhammara (npm) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- muhammara (npm): upgrade to 6.0.5 or later

  ```sh
  npm install muhammara@6.0.5
  ```


## Technical details

The vulnerability is a NULL pointer dereference (CWE-476) in PDFParser::CreateFilterForStream() at src/deps/PDFWriter/PDFParser.cpp line 2107. When processing a PDF stream with /Filter /LZWDecode and a /DecodeParms dictionary lacking the EarlyChange key, the code calls QueryDictionaryObject() which returns NULL, then immediately dereferences it via PDFObjectCastPtr::GetValue() without a null check, triggering an access violation (0xC0000005). The attack vector is network-based with no authentication or user interaction required. Any application accepting untrusted PDFs and parsing their streams is vulnerable to denial of service. The fix adds a null pointer check before dereferencing. A 460-byte proof-of-concept PDF triggers the crash.

## Affected products

- Muhammara Muhammara 6.0.4 and earlier

## Timeline

- 2026-06-26: disclosed: Advisory GHSA-fhp4-pr5j-46m5 published
- 2026-06-22: patched: Fix committed; patch released in version 6.0.5 or later

## References

- [https://github.com/julianhille/MuhammaraJS/security/advisories/GHSA-fhp4-pr5j-46m5](https://github.com/julianhille/MuhammaraJS/security/advisories/GHSA-fhp4-pr5j-46m5)
- [https://github.com/julianhille/MuhammaraJS/commit/a98c07780241353334eb65bfca1df025f14be70b](https://github.com/julianhille/MuhammaraJS/commit/a98c07780241353334eb65bfca1df025f14be70b)

## Related threats

- [Muhammara null pointer dereference in PDF append](https://junglewise.ai/threats/cve-2022-39381-muhammara-null-pointer-dereference-in-pdf-append)
- [muhammara and hummus null pointer dereference in PDFStreamForResponse](https://junglewise.ai/threats/cve-2022-25885-muhammara-and-hummus-null-pointer-dereference-in)
- [muhammara and Hummus NULL pointer dereference denial of service](https://junglewise.ai/threats/cve-2022-25892-muhammara-and-hummus-null-pointer-dereference-denial-of-service)
