Skip to content
Heist/ feed
Back to feed
Critical

Security advisory

Type: advisorySources: OSVCVE: CVE-2020-12278

An issue was discovered in libgit2 before 0.28.4 and 0.9x before 0.99.0. path.c mishandles equivalent filenames that exist because of NTFS Alternate Data Streams. This may allow remote code execution when cloning a repository. This issue is similar to CVE-2019-1352.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2020-12278
Confirmed fixed CVEs
Not specified
Updated in this feed
31 Oct 2026, 12:29 UTC · Revision 1

Source evidence

CVE-2020-12278

core-osv · Original source

Published 27 Apr 2020, 17:15 UTC

An issue was discovered in libgit2 before 0.28.4 and 0.9x before 0.99.0. path.c mishandles equivalent filenames that exist because of NTFS Alternate Data Streams. This may allow remote code execution when cloning a repository. This issue is similar to CVE-2019-1352.

osv:CVE-2020-12278
Complete source record
{
  "id": "864ab61c43e2f9f3fd6bd52e9151d4044099e02a84d2b790559ff928802444e4",
  "url": "https://osv.dev/vulnerability/CVE-2020-12278",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "CVE-2020-12278",
    "summary": "An issue was discovered in libgit2 before 0.28.4 and 0.9x before 0.99.0. path.c mishandles equivalent filenames that exist because of NTFS Alternate Data Streams. This may allow remote code execution when cloning a repository. This issue is similar to CVE-2019-1352.",
    "evidence": "osv:CVE-2020-12278",
    "products": [],
    "severity": "critical",
    "structured": {
      "id": "CVE-2020-12278",
      "aliases": [
        "CVE-2020-12278",
        "GHSA-5wph-8frv-58vj"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/libgit2/libgit2",
              "type": "GIT",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "106a5f27586504ea371528191f0ea3aac2ad432b"
                },
                {
                  "fixed": "3f7851eadca36a99627ad78cbe56a40d3776ed01"
                },
                {
                  "fixed": "e1832eb20a7089f6383cfce474f213157f5300cb"
                },
                {
                  "fixed": "172239021f7ba04fe7327647b213799853a9eb89"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "cpe": "cpe:2.3:a:libgit2:libgit2:*:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "fixed": "0.28.4"
                      }
                    ],
                    "source": "CPE_RANGE"
                  },
                  {
                    "range": [
                      {
                        "fixed": "3f7851eadca36a99627ad78cbe56a40d3776ed01"
                      }
                    ],
                    "source": "REFERENCES_COMMIT"
                  },
                  {
                    "range": [
                      {
                        "fixed": "e1832eb20a7089f6383cfce474f213157f5300cb"
                      }
                    ],
                    "source": "REFERENCES_COMMIT"
                  },
                  {
                    "range": [
                      {
                        "fixed": "106a5f27586504ea371528191f0ea3aac2ad432b"
                      }
                    ],
                    "source": "REFERENCES_TAG",
                    "original_tag": "v0.28.4"
                  },
                  {
                    "range": [
                      {
                        "fixed": "172239021f7ba04fe7327647b213799853a9eb89"
                      }
                    ],
                    "source": "REFERENCES_TAG",
                    "original_tag": "v0.99.0"
                  }
                ]
              }
            }
          ],
          "versions": [
            "v0.28.3",
            "v0.28.2",
            "v0.28.1",
            "v0.28.0-rc1",
            "v0.28.0",
            "v0.27.0",
            "v0.27.0-rc3",
            "v0.26.0-rc2",
            "v0.26.0",
            "v0.27.0-rc1",
            "v0.27.0-rc2",
            "v0.26.0-rc1",
            "v0.24.0",
            "v0.24.0-rc1",
            "v0.23.0",
            "v0.23.0-rc2",
            "v0.23.0-rc1",
            "v0.22.0",
            "v0.22.0-rc2",
            "v0.22.0-rc1",
            "v0.21.0",
            "v0.18.0",
            "v0.17.0",
            "v0.16.0",
            "v0.15.0",
            "v0.14.0",
            "v0.13.0",
            "v0.12.0",
            "v0.11.0",
            "v0.10.0",
            "v0.8.0",
            "v0.3.0",
            "v0.2.0",
            "v0.1.0"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2020-12278.json",
            "vanir_signatures": [
              {
                "id": "CVE-2020-12278-77fe0a52",
                "digest": {
                  "threshold": 0.9,
                  "line_hashes": [
                    "108193159272336527294922498355120781778",
                    "168696676604906338760080497384714187929"
                  ]
                },
                "source": "https://github.com/libgit2/libgit2/commit/e1832eb20a7089f6383cfce474f213157f5300cb",
                "target": {
                  "file": "tests/path/dotgit.c"
                },
                "deprecated": false,
                "signature_type": "Line",
                "signature_version": "v1"
              },
              {
                "id": "CVE-2020-12278-bc8b0a39",
                "digest": {
                  "threshold": 0.9,
                  "line_hashes": [
                    "67643414561346827047252582287335553368",
                    "161775868457229572254969846233468835126",
                    "300749777448919314626617997008976429146"
                  ]
                },
                "source": "https://github.com/libgit2/libgit2/commit/3f7851eadca36a99627ad78cbe56a40d3776ed01",
                "target": {
                  "file": "tests/checkout/nasty.c"
                },
                "deprecated": false,
                "signature_type": "Line",
                "signature_version": "v1"
              },
              {
                "id": "CVE-2020-12278-bf7ab8fe",
                "digest": {
                  "length": 635,
                  "function_hash": "138464184776582813693965786405820629166"
                },
                "source": "https://github.com/libgit2/libgit2/commit/3f7851eadca36a99627ad78cbe56a40d3776ed01",
                "target": {
                  "file": "src/path.c",
                  "function": "verify_dotgit_ntfs"
                },
                "deprecated": false,
                "signature_type": "Function",
                "signature_version": "v1"
              },
              {
                "id": "CVE-2020-12278-c12fb24b",
                "digest": {
                  "length": 344,
                  "function_hash": "215952766853611671430221167949782745440"
                },
                "source": "https://github.com/libgit2/libgit2/commit/e1832eb20a7089f6383cfce474f213157f5300cb",
                "target": {
                  "file": "tests/path/dotgit.c",
                  "function": "test_path_dotgit__dotgit_modules_symlink"
                },
                "deprecated": false,
                "signature_type": "Function",
                "signature_version": "v1"
              },
              {
                "id": "CVE-2020-12278-d524c03b",
                "digest": {
                  "threshold": 0.9,
                  "line_hashes": [
                    "207333267718056996405747804506618814446",
                    "232915964967517859136355871988975093200",
                    "206563144425427101112601160652327453230",
                    "278549392676235406755515526898783769056"
                  ]
                },
                "source": "https://github.com/libgit2/libgit2/commit/3f7851eadca36a99627ad78cbe56a40d3776ed01",
                "target": {
                  "file": "src/path.c"
                },
                "deprecated": false,
                "signature_type": "Line",
                "signature_version": "v1"
              }
            ],
            "vanir_signatures_modified": "2026-10-20T13:43:59Z"
          }
        }
      ],
      "modified": "2026-10-20T13:43:59.976259912Z",
      "provider": "osv",
      "references": [
        "https://lists.debian.org/debian-lts-announce/2023/02/msg00034.html",
        "https://github.com/git/git/security/advisories/GHSA-5wph-8frv-58vj",
        "https://github.com/libgit2/libgit2/releases/tag/v0.28.4",
        "https://github.com/libgit2/libgit2/releases/tag/v0.99.0",
        "https://lists.debian.org/debian-lts-announce/2022/03/msg00031.html",
        "https://github.com/libgit2/libgit2/commit/3f7851eadca36a99627ad78cbe56a40d3776ed01",
        "https://github.com/libgit2/libgit2/commit/e1832eb20a7089f6383cfce474f213157f5300cb"
      ],
      "provider_metadata": {
        "unresolved_ranges": [
          {
            "cpes": [
              "cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*"
            ],
            "vendor_product": "debian:debian_linux",
            "extracted_events": [
              {
                "range": [
                  {
                    "introduced": "9.0"
                  },
                  {
                    "last_affected": "9.0"
                  }
                ],
                "source": "CPE_STRING"
              }
            ]
          }
        ]
      }
    },
    "related_cves": [
      {
        "value": "CVE-2020-12278",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 388002,
  "published_at": "2020-04-27T17:15:13.407+00:00"
}