cbcvebase.
CVE-2016-2315
published 2016-04-08

CVE-2016-2315: revision.c in git before 2.7.4 uses an incorrect integer data type, which allows remote attackers to execute arbitrary code via a (1) long filename or (2) many…

PriorityP262critical9.8CVSS 3.1
AVNACLPRNUINSUCHIHAH
EPSS
17.98%
96.9th percentile
revision.c in git before 2.7.4 uses an incorrect integer data type, which allows remote attackers to execute arbitrary code via a (1) long filename or (2) many nested trees, leading to a heap-based buffer overflow.

Affected

16 ranges
VendorProductVersion rangeFixed in
debiancgit< git 1:2.7.0-1 (bookworm)git 1:2.7.0-1 (bookworm)
debiangit< git 1:2.7.0-1 (bookworm)git 1:2.7.0-1 (bookworm)
git-scmgit
gitgit>= 0 < 1:2.7.0-11:2.7.0-1
gitgit>= 0 < 1:2.7.0-11:2.7.0-1
gitgit>= 0 < 1:2.7.0-11:2.7.0-1
gitgit>= 0 < 1:2.7.0-11:2.7.0-1
gitgit>= 0 < 1:1.9.1-1ubuntu0.31:1.9.1-1ubuntu0.3
opensuseleap
opensuseopensuse
suselinux_enterprise_debuginfo
suselinux_enterprise_server
suselinux_enterprise_software_development_kit
suselinux_enterprise_software_development_kit
suseopenstack_cloud
susesuse_linux_enterprise_server

Detection & IOCsextracted from sources · hover to see the quote

  • The vulnerability exists in the `path_name()` function in `revision.c`. Both CVE-2016-2315 and CVE-2016-2324 affect this function — monitor for exploitation attempts targeting Git push/clone operations involving large filenames or deeply nested trees.
  • Attack vector is via a specially crafted packfile delivered during a Git push (attacker must authenticate to server) or Git clone (client clones from malicious repository). Detect anomalous Git clone/push operations from untrusted sources.
  • Client-side attack vector: a user is tricked into cloning from a malicious Git repository. Alert on Git clone operations from unknown/untrusted remote URLs, especially those with unusually long path components or deeply nested tree structures.
  • The triggering conditions are (1) a long filename or (2) many nested trees in a Git repository. Inspect incoming Git repositories/packfiles for excessively long filenames or abnormally deep directory tree nesting as a detection heuristic.
  • The vulnerable code path uses `int` for length/size values (`nlen`, `len`) in `path_name()` in `revision.c`, leading to integer truncation/overflow on 64-bit systems. Flag Git versions prior to 2.4.11, 2.5.5, 2.6.6, or 2.7.4 as vulnerable in asset inventory.
  • ·Server-side exploitation requires the attacker to have push access (authentication) to a repository. Unauthenticated remote exploitation is only possible against Git clients performing clone operations.
  • ·Exploitation most likely results in a crash (denial of service), but arbitrary code execution cannot be ruled out. Detection/response should account for both outcomes.

CVSS provenance

nvdv3.19.8CRITICALCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
nvdv2.010.0CRITICALAV:N/AC:L/Au:N/C:C/I:C/A:C
osv9.8CRITICAL
vendor_debian9.8LOW
vendor_redhat9.8CRITICAL
vendor_ubuntu9.8CRITICAL
Stop checking back — get the weekly exploitation signal.

Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.