CVE-2022-23521

Summary

CVECVE-2022-23521
StatePUBLIC
Assigner[email protected]
Source PriorityCVE Program / NVD first with legacy fallback
Published2023-01-17 23:15:00 UTC
Updated2023-12-27 10:15:00 UTC
DescriptionGit is distributed revision control system. gitattributes are a mechanism to allow defining attributes for paths. These attributes can be defined by adding a `.gitattributes` file to the repository, which contains a set of file patterns and the attributes that should be set for paths matching this pattern. When parsing gitattributes, multiple integer overflows can occur when there is a huge number of path patterns, a huge number of attributes for a single pattern, or when the declared attribute names are huge. These overflows can be triggered via a crafted `.gitattributes` file that may be part of the commit history. Git silently splits lines longer than 2KB when parsing gitattributes from a file, but not when parsing them from the index. Consequentially, the failure mode depends on whether the file exists in the working tree, the index or both. This integer overflow can result in arbitrary heap reads and writes, which may result in remote code execution. The problem has been patched in the versions published on 2023-01-17, going back to v2.30.7. Users are advised to upgrade. There are no known workarounds for this issue.

Risk And Classification

Problem Types: CWE-190

NVD Known Affected Configurations (CPE 2.3)

TypeVendorProductVersionUpdateEditionLanguage
Application Git-scm Git 2.39.0 All All All
Application Git-scm Git All All All All
Application Git-scm Git All All All All
Application Git-scm Git All All All All
Application Git-scm Git All All All All
Application Git-scm Git All All All All
Application Git-scm Git All All All All
Application Git-scm Git All All All All
Application Git-scm Git All All All All
Application Git-scm Git All All All All

References

ReferenceSourceLinkTags
gitattributes parsing integer overflow · Advisory · git/git · GitHub MISC github.com
Sync with 2.39.1 · git/git@508386c · GitHub MISC github.com
Git: Multiple Vulnerabilities (GLSA 202312-15) — Gentoo security security.gentoo.org
CVE Program record CVE.ORG www.cve.org canonical
NVD vulnerability detail NVD nvd.nist.gov canonical, analysis

Legacy QID Mappings

  • 160443 Oracle Enterprise Linux Security Update for git (ELSA-2023-0610)
  • 160446 Oracle Enterprise Linux Security Update for git (ELSA-2023-0611)
  • 160487 Oracle Enterprise Linux Security Update for git (ELSA-2023-0978)
  • 181505 Debian Security Update for git (DLA 3282-1)
  • 181518 Debian Security Update for git (DSA 5332-1)
  • 183759 Debian Security Update for git (CVE-2022-23521)
  • 199108 Ubuntu Security Notification for Git Vulnerabilities (USN-5810-1)
  • 199516 Ubuntu Security Notification for Git Vulnerabilities (USN-5810-3)
  • 199582 Ubuntu Security Notification for Git Vulnerabilities (USN-5810-4)
  • 241158 Red Hat Update for git (RHSA-2023:0596)
  • 241161 Red Hat Update for rh-git227-git (RHSA-2023:0597)
  • 241163 Red Hat Update for git (RHSA-2023:0611)
  • 241166 Red Hat Update for git (RHSA-2023:0610)
  • 241170 Red Hat Update for git (RHSA-2023:0627)
  • 241174 Red Hat Update for git (RHSA-2023:0628)
  • 241224 Red Hat Update for git (RHSA-2023:0978)
  • 241611 Red Hat Update for git (RHSA-2023:0599)
  • 241642 Red Hat Update for git (RHSA-2023:0609)
  • 257225 CentOS Security Update for git (CESA-2023:0978)
  • 283618 Fedora Security Update for git (FEDORA-2023-9718cc6113)
  • 283619 Fedora Security Update for git (FEDORA-2023-746c4aacce)
  • 354718 Amazon Linux Security Advisory for git : ALAS-2023-1679
  • 354733 Amazon Linux Security Advisory for git : ALAS2-2023-1923
  • 355061 Amazon Linux Security Advisory for git : AL2012-2023-385
  • 355256 Amazon Linux Security Advisory for git : ALAS2023-2023-065
  • 377913 Git Multiple Security Vulnerabilities
  • 377997 Alibaba Cloud Linux Security Update for git (ALINUX3-SA-2023:0020)
  • 378118 Alibaba Cloud Linux Security Update for git (ALINUX2-SA-2023:0012)
  • 502636 Alpine Linux Security Update for git
  • 502638 Alpine Linux Security Update for git
  • 502639 Alpine Linux Security Update for git
  • 502727 Alpine Linux Security Update for git
  • 503106 Alpine Linux Security Update for git
  • 505872 Alpine Linux Security Update for git
  • 672708 EulerOS Security Update for git (EulerOS-SA-2023-1466)
  • 672737 EulerOS Security Update for git (EulerOS-SA-2023-1441)
  • 672793 EulerOS Security Update for git (EulerOS-SA-2023-1548)
  • 672811 EulerOS Security Update for git (EulerOS-SA-2023-1523)
  • 672868 EulerOS Security Update for git (EulerOS-SA-2023-1594)
  • 672898 EulerOS Security Update for git (EulerOS-SA-2023-1757)
  • 672902 EulerOS Security Update for git (EulerOS-SA-2023-1779)
  • 673069 EulerOS Security Update for git (EulerOS-SA-2023-2145)
  • 691070 Free Berkeley Software Distribution (FreeBSD) Security Update for git (8fafbef4-b1d9-11ed-b0f4-002590f2a714)
  • 710816 Gentoo Linux Git Multiple Vulnerabilities (GLSA 202312-15)
  • 753543 SUSE Enterprise Linux Security Update for git (SUSE-SU-2023:0109-1)
  • 753549 SUSE Enterprise Linux Security Update for git (SUSE-SU-2023:0110-1)
  • 753550 SUSE Enterprise Linux Security Update for git (SUSE-SU-2023:0108-1)
  • 905273 Common Base Linux Mariner (CBL-Mariner) Security Update for git (13015)
  • 905276 Common Base Linux Mariner (CBL-Mariner) Security Update for git (13024)
  • 905470 Common Base Linux Mariner (CBL-Mariner) Security Update for git (13015-1)
  • 907370 Common Base Linux Mariner (CBL-Mariner) Security Update for git (13024-1)
  • 940913 AlmaLinux Security Update for git (ALSA-2023:0610)
  • 940915 AlmaLinux Security Update for git (ALSA-2023:0611)
  • 960534 Rocky Linux Security Update for git (RLSA-2023:0611)
  • 960568 Rocky Linux Security Update for git (RLSA-2023:0610)
© CVE.report 2026 |

Use of this information constitutes acceptance for use in an AS IS condition. There are NO warranties, implied or otherwise, with regard to this information or its use. Any use of this information is at the user's risk. It is the responsibility of user to evaluate the accuracy, completeness or usefulness of any information, opinion, advice or other content. EACH USER WILL BE SOLELY RESPONSIBLE FOR ANY consequences of his or her direct or indirect use of this web site. ALL WARRANTIES OF ANY KIND ARE EXPRESSLY DISCLAIMED. This site will NOT BE LIABLE FOR ANY DIRECT, INDIRECT or any other kind of loss.

CVE, CWE, and OVAL are registred trademarks of The MITRE Corporation and the authoritative source of CVE content is MITRE's CVE web site. This site includes MITRE data granted under the following license.

Free CVE JSON API cve.report/api

CVE.report and Source URL Uptime Status status.cve.report