CVE-2022-41903
git: Heap overflow in `git archive`, `git log --format` leading to RCE
Kaynağa göre önem derecesi
Trivy'nin kendi etiketi CRITICAL. Kritik diyenler: NVD, CBL-Mariner, Photon OS. Daha düşük diyenler: Red Hat (yüksek), AlmaLinux (yüksek), Amazon (yüksek), Oracle (yüksek), Rocky Linux (yüksek), Ubuntu (orta).
Açıklama
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 writes, which may result in arbitrary 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. Users who are unable to upgrade should disable `git archive` in untrusted repositories. If you expose git archive via `git daemon`, disable it by running `git config --global daemon.uploadArch false`.
Etkilenen paketler ve düzeltilmiş sürümler
| Kaynak | Paket | Düzeltildiği sürüm |
|---|---|---|
| CBL-Mariner 1.0 | git | 0:2.33.6-1.cm1 |
| CBL-Mariner 2.0 | git | 0:2.33.8-2.cm2 |
| Photon OS 3.0 | git | 2.35.6-1.ph3 |
| Photon OS 4.0 | git, git-extras, git-lang | 2.35.6-1.ph4 |
| Photon OS 5.0 | git, git-extras, git-lang | 2.43.7-1.ph5 |
| alma 8 | git, git-all, git-core ve 12 tane daha | 2.31.1-3.el8_7 |
| alma 9 | git, git-all, git-core ve 12 tane daha | 2.31.1-3.el9_1 |
| alpine 3.14 | git | 2.32.5-r0 |
| alpine 3.15 | git | 2.34.6-r0 |
| alpine 3.16 | git | 2.36.4-r0 |
| alpine 3.17 | git | 2.38.3-r0 |
| alpine 3.18 | git | 2.39.1-r0 |
52 kaynaktaki 227 kaydın hepsini göster
| Kaynak | Paket | Düzeltildiği sürüm |
|---|---|---|
| CBL-Mariner 1.0 | git | 0:2.33.6-1.cm1 |
| CBL-Mariner 2.0 | git | 0:2.33.8-2.cm2 |
| Photon OS 3.0 | git | 2.35.6-1.ph3 |
| Photon OS 4.0 | git | 2.35.6-1.ph4 |
| Photon OS 4.0 | git-extras | 2.35.6-1.ph4 |
| Photon OS 4.0 | git-lang | 2.35.6-1.ph4 |
| Photon OS 5.0 | git | 2.43.7-1.ph5 |
| Photon OS 5.0 | git-extras | 2.43.7-1.ph5 |
| Photon OS 5.0 | git-lang | 2.43.7-1.ph5 |
| alma 8 | git | 2.31.1-3.el8_7 |
| alma 8 | git-all | 2.31.1-3.el8_7 |
| alma 8 | git-core | 2.31.1-3.el8_7 |
| alma 8 | git-core-doc | 2.31.1-3.el8_7 |
| alma 8 | git-credential-libsecret | 2.31.1-3.el8_7 |
| alma 8 | git-daemon | 2.31.1-3.el8_7 |
| alma 8 | git-email | 2.31.1-3.el8_7 |
| alma 8 | git-gui | 2.31.1-3.el8_7 |
| alma 8 | git-instaweb | 2.31.1-3.el8_7 |
| alma 8 | git-subtree | 2.31.1-3.el8_7 |
| alma 8 | git-svn | 2.31.1-3.el8_7 |
| alma 8 | gitk | 2.31.1-3.el8_7 |
| alma 8 | gitweb | 2.31.1-3.el8_7 |
| alma 8 | perl-Git | 2.31.1-3.el8_7 |
| alma 8 | perl-Git-SVN | 2.31.1-3.el8_7 |
| alma 9 | git | 2.31.1-3.el9_1 |
| alma 9 | git-all | 2.31.1-3.el9_1 |
| alma 9 | git-core | 2.31.1-3.el9_1 |
| alma 9 | git-core-doc | 2.31.1-3.el9_1 |
| alma 9 | git-credential-libsecret | 2.31.1-3.el9_1 |
| alma 9 | git-daemon | 2.31.1-3.el9_1 |
| alma 9 | git-email | 2.31.1-3.el9_1 |
| alma 9 | git-gui | 2.31.1-3.el9_1 |
| alma 9 | git-instaweb | 2.31.1-3.el9_1 |
| alma 9 | git-subtree | 2.31.1-3.el9_1 |
| alma 9 | git-svn | 2.31.1-3.el9_1 |
| alma 9 | gitk | 2.31.1-3.el9_1 |
| alma 9 | gitweb | 2.31.1-3.el9_1 |
| alma 9 | perl-Git | 2.31.1-3.el9_1 |
| alma 9 | perl-Git-SVN | 2.31.1-3.el9_1 |
| alpine 3.14 | git | 2.32.5-r0 |
| alpine 3.15 | git | 2.34.6-r0 |
| alpine 3.16 | git | 2.36.4-r0 |
| alpine 3.17 | git | 2.38.3-r0 |
| alpine 3.18 | git | 2.39.1-r0 |
| alpine 3.19 | git | 2.39.1-r0 |
| alpine 3.20 | git | 2.39.1-r0 |
| alpine 3.21 | git | 2.39.1-r0 |
| alpine 3.22 | git | 2.39.1-r0 |
| alpine 3.23 | git | 2.39.1-r0 |
| alpine 3.24 | git | 2.39.1-r0 |
| alpine edge | git | 2.39.1-r0 |
| amazon linux 1 | emacs-git | 2.38.3-1.78.amzn1 |
| amazon linux 1 | emacs-git-el | 2.38.3-1.78.amzn1 |
| amazon linux 1 | git | 2.38.3-1.78.amzn1 |
| amazon linux 1 | git-all | 2.38.3-1.78.amzn1 |
| amazon linux 1 | git-bzr | 2.38.3-1.78.amzn1 |
| amazon linux 1 | git-core | 2.38.3-1.78.amzn1 |
| amazon linux 1 | git-core-doc | 2.38.3-1.78.amzn1 |
| amazon linux 1 | git-cvs | 2.38.3-1.78.amzn1 |
| amazon linux 1 | git-daemon | 2.38.3-1.78.amzn1 |
| amazon linux 1 | git-debuginfo | 2.38.3-1.78.amzn1 |
| amazon linux 1 | git-email | 2.38.3-1.78.amzn1 |
| amazon linux 1 | git-hg | 2.38.3-1.78.amzn1 |
| amazon linux 1 | git-instaweb | 2.38.3-1.78.amzn1 |
| amazon linux 1 | git-p4 | 2.38.3-1.78.amzn1 |
| amazon linux 1 | git-subtree | 2.38.3-1.78.amzn1 |
| amazon linux 1 | git-svn | 2.38.3-1.78.amzn1 |
| amazon linux 1 | gitweb | 2.38.3-1.78.amzn1 |
| amazon linux 1 | perl-Git | 2.38.3-1.78.amzn1 |
| amazon linux 1 | perl-Git-SVN | 2.38.3-1.78.amzn1 |
| amazon linux 2 | git | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | git-all | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | git-core | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | git-core-doc | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | git-credential-libsecret | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | git-cvs | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | git-daemon | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | git-debuginfo | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | git-email | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | git-gui | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | git-instaweb | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | git-p4 | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | git-subtree | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | git-svn | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | gitk | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | gitweb | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | perl-Git | 2.39.1-1.amzn2.0.1 |
| amazon linux 2 | perl-Git-SVN | 2.39.1-1.amzn2.0.1 |
| amazon linux 2023 | git | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-all | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-core | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-core-debuginfo | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-core-doc | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-credential-libsecret | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-credential-libsecret-debuginfo | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-cvs | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-daemon | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-daemon-debuginfo | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-debuginfo | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-debugsource | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-email | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-gui | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-instaweb | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-p4 | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-subtree | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | git-svn | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | gitk | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | gitweb | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | perl-Git | 2.39.1-1.amzn2023.0.2 |
| amazon linux 2023 | perl-Git-SVN | 2.39.1-1.amzn2023.0.2 |
| chainguard | git | 2.39.1-r0 |
| debian 10 | git | 1:2.20.1-2+deb10u7 |
| debian 11 | git | 1:2.30.2-1+deb11u1 |
| debian 12 | git | 1:2.39.1-0.1 |
| debian 13 | git | 1:2.39.1-0.1 |
| debian 14 | git | 1:2.39.1-0.1 |
| echo | git | 1:2.39.1-0.1 |
| Oracle Linux 7 | emacs-git | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | emacs-git-el | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | git | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | git-all | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | git-bzr | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | git-cvs | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | git-daemon | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | git-email | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | git-gnome-keyring | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | git-gui | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | git-hg | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | git-instaweb | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | git-p4 | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | git-svn | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | gitk | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | gitweb | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | perl-Git | 1.8.3.1-24.el7_9 |
| Oracle Linux 7 | perl-Git-SVN | 1.8.3.1-24.el7_9 |
| Oracle Linux 8 | git | 2.31.1-3.el8_7 |
| Oracle Linux 8 | git-all | 2.31.1-3.el8_7 |
| Oracle Linux 8 | git-core | 2.31.1-3.el8_7 |
| Oracle Linux 8 | git-core-doc | 2.31.1-3.el8_7 |
| Oracle Linux 8 | git-credential-libsecret | 2.31.1-3.el8_7 |
| Oracle Linux 8 | git-daemon | 2.31.1-3.el8_7 |
| Oracle Linux 8 | git-email | 2.31.1-3.el8_7 |
| Oracle Linux 8 | git-gui | 2.31.1-3.el8_7 |
| Oracle Linux 8 | git-instaweb | 2.31.1-3.el8_7 |
| Oracle Linux 8 | git-subtree | 2.31.1-3.el8_7 |
| Oracle Linux 8 | git-svn | 2.31.1-3.el8_7 |
| Oracle Linux 8 | gitk | 2.31.1-3.el8_7 |
| Oracle Linux 8 | gitweb | 2.31.1-3.el8_7 |
| Oracle Linux 8 | perl-Git | 2.31.1-3.el8_7 |
| Oracle Linux 8 | perl-Git-SVN | 2.31.1-3.el8_7 |
| Oracle Linux 9 | git | 2.31.1-3.el9_1 |
| Oracle Linux 9 | git-all | 2.31.1-3.el9_1 |
| Oracle Linux 9 | git-core | 2.31.1-3.el9_1 |
| Oracle Linux 9 | git-core-doc | 2.31.1-3.el9_1 |
| Oracle Linux 9 | git-credential-libsecret | 2.31.1-3.el9_1 |
| Oracle Linux 9 | git-daemon | 2.31.1-3.el9_1 |
| Oracle Linux 9 | git-email | 2.31.1-3.el9_1 |
| Oracle Linux 9 | git-gui | 2.31.1-3.el9_1 |
| Oracle Linux 9 | git-instaweb | 2.31.1-3.el9_1 |
| Oracle Linux 9 | git-subtree | 2.31.1-3.el9_1 |
| Oracle Linux 9 | git-svn | 2.31.1-3.el9_1 |
| Oracle Linux 9 | gitk | 2.31.1-3.el9_1 |
| Oracle Linux 9 | gitweb | 2.31.1-3.el9_1 |
| Oracle Linux 9 | perl-Git | 2.31.1-3.el9_1 |
| Oracle Linux 9 | perl-Git-SVN | 2.31.1-3.el9_1 |
| rapidfort ubuntu 20.04 | git | 1:2.34.1-1ubuntu1.6 |
| rapidfort ubuntu 20.04 | rf-git | 1:2.34.1-1ubuntu1.6 |
| rapidfort ubuntu 22.04 | git | 1:2.34.1-1ubuntu1.6 |
| rapidfort ubuntu 22.04 | rf-git | 1:2.34.1-1ubuntu1.6 |
| rapidfort ubuntu 24.04 | git | 1:2.34.1-1ubuntu1.6 |
| rapidfort ubuntu 24.04 | rf-git | 1:2.34.1-1ubuntu1.6 |
| Red Hat | emacs-git | düzeltme belirtilmemiş |
| Red Hat | emacs-git-el | düzeltme belirtilmemiş |
| Red Hat | git | düzeltme belirtilmemiş |
| Red Hat | git-all | düzeltme belirtilmemiş |
| Red Hat | git-cvs | düzeltme belirtilmemiş |
| Red Hat | git-daemon | düzeltme belirtilmemiş |
| Red Hat | git-email | düzeltme belirtilmemiş |
| Red Hat | git-gui | düzeltme belirtilmemiş |
| Red Hat | git-svn | düzeltme belirtilmemiş |
| Red Hat | gitk | düzeltme belirtilmemiş |
| Red Hat | gitweb | düzeltme belirtilmemiş |
| Red Hat | perl-Git | düzeltme belirtilmemiş |
| rocky 8 | git | 2.31.1-3.el8_7 |
| rocky 8 | git-all | 2.31.1-3.el8_7 |
| rocky 8 | git-core | 2.31.1-3.el8_7 |
| rocky 8 | git-core-doc | 2.31.1-3.el8_7 |
| rocky 8 | git-credential-libsecret | 2.31.1-3.el8_7 |
| rocky 8 | git-daemon | 2.31.1-3.el8_7 |
| rocky 8 | git-email | 2.31.1-3.el8_7 |
| rocky 8 | git-gui | 2.31.1-3.el8_7 |
| rocky 8 | git-instaweb | 2.31.1-3.el8_7 |
| rocky 8 | git-subtree | 2.31.1-3.el8_7 |
| rocky 8 | git-svn | 2.31.1-3.el8_7 |
| rocky 8 | gitk | 2.31.1-3.el8_7 |
| rocky 8 | gitweb | 2.31.1-3.el8_7 |
| rocky 8 | perl-Git | 2.31.1-3.el8_7 |
| rocky 8 | perl-Git-SVN | 2.31.1-3.el8_7 |
| rocky 9 | git | 2.31.1-3.el9_1 |
| rocky 9 | git-all | 2.31.1-3.el9_1 |
| rocky 9 | git-core | 2.31.1-3.el9_1 |
| rocky 9 | git-core-doc | 2.31.1-3.el9_1 |
| rocky 9 | git-credential-libsecret | 2.31.1-3.el9_1 |
| rocky 9 | git-daemon | 2.31.1-3.el9_1 |
| rocky 9 | git-email | 2.31.1-3.el9_1 |
| rocky 9 | git-gui | 2.31.1-3.el9_1 |
| rocky 9 | git-instaweb | 2.31.1-3.el9_1 |
| rocky 9 | git-subtree | 2.31.1-3.el9_1 |
| rocky 9 | git-svn | 2.31.1-3.el9_1 |
| rocky 9 | gitk | 2.31.1-3.el9_1 |
| rocky 9 | gitweb | 2.31.1-3.el9_1 |
| rocky 9 | perl-Git | 2.31.1-3.el9_1 |
| rocky 9 | perl-Git-SVN | 2.31.1-3.el9_1 |
| root.io debian 11 | rootio-git | 1:2.30.2-1+deb11u1 |
| root.io debian 12 | rootio-git | 1:2.39.1-0.1 |
| root.io debian 13 | rootio-git | 1:2.39.1-0.1 |
| root.io ubuntu 22.04 | rootio-git | 1:2.34.1-1ubuntu1.6 |
| ubuntu 14.04-ESM | git | 1:1.9.1-1ubuntu0.10+esm1 |
| ubuntu 16.04-ESM | git | 1:2.7.4-0ubuntu1.10+esm4 |
| ubuntu 18.04 | git | 1:2.17.1-1ubuntu0.15 |
| ubuntu 18.04-ESM | git | 1:2.17.1-1ubuntu0.15 |
| ubuntu 20.04 | git | 1:2.25.1-1ubuntu3.8 |
| ubuntu 20.04-ESM | git | 1:2.25.1-1ubuntu3.8 |
| ubuntu 22.04 | git | 1:2.34.1-1ubuntu1.6 |
| ubuntu 22.10 | git | 1:2.37.2-1ubuntu1.2 |
| ubuntu 23.04 | git | 1:2.39.1-0.1ubuntu1 |
| wolfi | git | 2.39.1-r0 |
Referanslar
- https://access.redhat.com/errata/RHSA-2023:0611
- https://access.redhat.com/security/cve/CVE-2022-41903
- https://bugzilla.redhat.com/2162055
- https://bugzilla.redhat.com/2162056
- https://bugzilla.redhat.com/show_bug.cgi?id=2162055
- https://bugzilla.redhat.com/show_bug.cgi?id=2162056
- https://creativecommons.org/licenses/by/4.0/
- https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-23521
26 referansın hepsi
- https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-41903
- https://errata.almalinux.org/9/ALSA-2023-0611.html
- https://errata.rockylinux.org/RLSA-2023:0611
- https://git-scm.com/book/en/v2/Customizing-Git-Git-Attributes#_export_subst
- https://git-scm.com/docs/pretty-formats#Documentation/pretty-formats.txt-emltltNgttruncltruncmtruncem
- https://github.com/git/git/commit/508386c6c5857b4faa2c3e491f422c98cc69ae76
- https://github.com/git/git/files/10430260/X41-OSTIF-Gitlab-Git-Security-Audit-20230117-public.pdf
- https://github.com/git/git/security/advisories/GHSA-475x-2q3q-hvwq
- https://linux.oracle.com/cve/CVE-2022-41903.html
- https://linux.oracle.com/errata/ELSA-2023-0978.html
- https://nvd.nist.gov/vuln/detail/CVE-2022-41903
- https://security.gentoo.org/glsa/202312-15
- https://ubuntu.com/security/notices/USN-5810-1
- https://ubuntu.com/security/notices/USN-5810-2
- https://ubuntu.com/security/notices/USN-5810-3
- https://ubuntu.com/security/notices/USN-5810-4
- https://www.cve.org/CVERecord?id=CVE-2022-41903
- https://www.openwall.com/lists/oss-security/2023/01/17/4