cvedb.io
CVE-2022-41903
CRITICAL · CVSS 9.8
EPSS exploitation probability: 0%
Published 2023-01-17T23:15:15.690 · Last modified 2026-06-17T05:04:01.900

Summary

Git is distributed revision control system. `git log` can display commits in an arbitrary format using its `--format` specifiers. This functionality is also exposed to `git archive` via the `export-subst` gitattribute. When processing the padding operators, there is a integer overflow in `pretty.c::format_and_pad_commit()` where a `size_t` is stored improperly as an `int`, and then added as an offset to a `memcpy()`. This overflow can be triggered directly by a user running a command which invokes the commit formatting machinery (e.g., `git log --format=...`). It may also be triggered indirectly through git archive via the export-subst mechanism, which expands format specifiers inside of files within the repository during a git archive. This integer overflow can result in arbitrary heap wr

Affected products

git-scm — git

Does this affect you?

Add your gear to cvedb and we'll alert you only when git-scm ships something exploited.

Check my exposure →

References

This product uses data from the NVD API but is not endorsed or certified by the NVD. Informational only; not professional security advice.