CVE-2023-22742 (GCVE-0-2023-22742)
Vulnerability from cvelistv5
Published
2023-01-20 22:49
Modified
2025-03-10 21:21
CWE
  • CWE-347 - Improper Verification of Cryptographic Signature
Summary
libgit2 is a cross-platform, linkable library implementation of Git. When using an SSH remote with the optional libssh2 backend, libgit2 does not perform certificate checking by default. Prior versions of libgit2 require the caller to set the `certificate_check` field of libgit2's `git_remote_callbacks` structure - if a certificate check callback is not set, libgit2 does not perform any certificate checking. This means that by default - without configuring a certificate check callback, clients will not perform validation on the server SSH keys and may be subject to a man-in-the-middle attack. Users are encouraged to upgrade to v1.4.5 or v1.5.1. Users unable to upgrade should ensure that all relevant certificates are manually checked.
Impacted products
Vendor Product Version
libgit2 libgit2 Version: < 1.4.5
Version: = 1.5.0
Create a notification for this product.
Show details on NVD website


{
  "containers": {
    "adp": [
      {
        "providerMetadata": {
          "dateUpdated": "2024-08-02T10:20:30.067Z",
          "orgId": "af854a3a-2127-422b-91ae-364da2661108",
          "shortName": "CVE"
        },
        "references": [
          {
            "name": "https://github.com/libgit2/libgit2/security/advisories/GHSA-8643-3wh5-rmjq",
            "tags": [
              "x_refsource_CONFIRM",
              "x_transferred"
            ],
            "url": "https://github.com/libgit2/libgit2/security/advisories/GHSA-8643-3wh5-rmjq"
          },
          {
            "name": "https://github.com/libgit2/libgit2/commit/42e5db98b963ae503229c63e44e06e439df50e56",
            "tags": [
              "x_refsource_MISC",
              "x_transferred"
            ],
            "url": "https://github.com/libgit2/libgit2/commit/42e5db98b963ae503229c63e44e06e439df50e56"
          },
          {
            "name": "https://github.com/libgit2/libgit2/commit/cd6f679af401eda1f172402006ef8265f8bd58ea",
            "tags": [
              "x_refsource_MISC",
              "x_transferred"
            ],
            "url": "https://github.com/libgit2/libgit2/commit/cd6f679af401eda1f172402006ef8265f8bd58ea"
          },
          {
            "name": "https://github.com/libgit2/libgit2/releases/tag/v1.4.5",
            "tags": [
              "x_refsource_MISC",
              "x_transferred"
            ],
            "url": "https://github.com/libgit2/libgit2/releases/tag/v1.4.5"
          },
          {
            "name": "https://github.com/libgit2/libgit2/releases/tag/v1.5.1",
            "tags": [
              "x_refsource_MISC",
              "x_transferred"
            ],
            "url": "https://github.com/libgit2/libgit2/releases/tag/v1.5.1"
          },
          {
            "name": "https://www.libssh2.org",
            "tags": [
              "x_refsource_MISC",
              "x_transferred"
            ],
            "url": "https://www.libssh2.org"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "http://www.openwall.com/lists/oss-security/2023/11/06/5"
          }
        ],
        "title": "CVE Program Container"
      },
      {
        "metrics": [
          {
            "other": {
              "content": {
                "id": "CVE-2023-22742",
                "options": [
                  {
                    "Exploitation": "none"
                  },
                  {
                    "Automatable": "no"
                  },
                  {
                    "Technical Impact": "partial"
                  }
                ],
                "role": "CISA Coordinator",
                "timestamp": "2025-03-10T20:59:36.699887Z",
                "version": "2.0.3"
              },
              "type": "ssvc"
            }
          }
        ],
        "providerMetadata": {
          "dateUpdated": "2025-03-10T21:21:08.962Z",
          "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
          "shortName": "CISA-ADP"
        },
        "title": "CISA ADP Vulnrichment"
      }
    ],
    "cna": {
      "affected": [
        {
          "product": "libgit2",
          "vendor": "libgit2",
          "versions": [
            {
              "status": "affected",
              "version": "\u003c 1.4.5"
            },
            {
              "status": "affected",
              "version": "= 1.5.0"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "libgit2 is a cross-platform, linkable library implementation of Git. When using an SSH remote with the optional libssh2 backend, libgit2 does not perform certificate checking by default. Prior versions of libgit2 require the caller to set the `certificate_check` field of libgit2\u0027s `git_remote_callbacks` structure - if a certificate check callback is not set, libgit2 does not perform any certificate checking. This means that by default - without configuring a certificate check callback, clients will not perform validation on the server SSH keys and may be subject to a man-in-the-middle attack. Users are encouraged to upgrade to v1.4.5 or v1.5.1. Users unable to upgrade should ensure that all relevant certificates are manually checked."
        }
      ],
      "metrics": [
        {
          "cvssV3_1": {
            "attackComplexity": "HIGH",
            "attackVector": "NETWORK",
            "availabilityImpact": "NONE",
            "baseScore": 5.3,
            "baseSeverity": "MEDIUM",
            "confidentialityImpact": "NONE",
            "integrityImpact": "HIGH",
            "privilegesRequired": "NONE",
            "scope": "UNCHANGED",
            "userInteraction": "REQUIRED",
            "vectorString": "CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:H/A:N",
            "version": "3.1"
          }
        }
      ],
      "problemTypes": [
        {
          "descriptions": [
            {
              "cweId": "CWE-347",
              "description": "CWE-347: Improper Verification of Cryptographic Signature",
              "lang": "en",
              "type": "CWE"
            }
          ]
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2023-11-07T00:06:32.714Z",
        "orgId": "a0819718-46f1-4df5-94e2-005712e83aaa",
        "shortName": "GitHub_M"
      },
      "references": [
        {
          "name": "https://github.com/libgit2/libgit2/security/advisories/GHSA-8643-3wh5-rmjq",
          "tags": [
            "x_refsource_CONFIRM"
          ],
          "url": "https://github.com/libgit2/libgit2/security/advisories/GHSA-8643-3wh5-rmjq"
        },
        {
          "name": "https://github.com/libgit2/libgit2/commit/42e5db98b963ae503229c63e44e06e439df50e56",
          "tags": [
            "x_refsource_MISC"
          ],
          "url": "https://github.com/libgit2/libgit2/commit/42e5db98b963ae503229c63e44e06e439df50e56"
        },
        {
          "name": "https://github.com/libgit2/libgit2/commit/cd6f679af401eda1f172402006ef8265f8bd58ea",
          "tags": [
            "x_refsource_MISC"
          ],
          "url": "https://github.com/libgit2/libgit2/commit/cd6f679af401eda1f172402006ef8265f8bd58ea"
        },
        {
          "name": "https://github.com/libgit2/libgit2/releases/tag/v1.4.5",
          "tags": [
            "x_refsource_MISC"
          ],
          "url": "https://github.com/libgit2/libgit2/releases/tag/v1.4.5"
        },
        {
          "name": "https://github.com/libgit2/libgit2/releases/tag/v1.5.1",
          "tags": [
            "x_refsource_MISC"
          ],
          "url": "https://github.com/libgit2/libgit2/releases/tag/v1.5.1"
        },
        {
          "name": "https://www.libssh2.org",
          "tags": [
            "x_refsource_MISC"
          ],
          "url": "https://www.libssh2.org"
        },
        {
          "url": "http://www.openwall.com/lists/oss-security/2023/11/06/5"
        }
      ],
      "source": {
        "advisory": "GHSA-8643-3wh5-rmjq",
        "discovery": "UNKNOWN"
      },
      "title": "libgit2 fails to verify SSH keys by default"
    }
  },
  "cveMetadata": {
    "assignerOrgId": "a0819718-46f1-4df5-94e2-005712e83aaa",
    "assignerShortName": "GitHub_M",
    "cveId": "CVE-2023-22742",
    "datePublished": "2023-01-20T22:49:06.378Z",
    "dateReserved": "2023-01-06T14:21:05.892Z",
    "dateUpdated": "2025-03-10T21:21:08.962Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.1",
  "vulnerability-lookup:meta": {
    "vulnrichment": {
      "containers": "{\"adp\": [{\"title\": \"CVE Program Container\", \"references\": [{\"url\": \"https://github.com/libgit2/libgit2/security/advisories/GHSA-8643-3wh5-rmjq\", \"name\": \"https://github.com/libgit2/libgit2/security/advisories/GHSA-8643-3wh5-rmjq\", \"tags\": [\"x_refsource_CONFIRM\", \"x_transferred\"]}, {\"url\": \"https://github.com/libgit2/libgit2/commit/42e5db98b963ae503229c63e44e06e439df50e56\", \"name\": \"https://github.com/libgit2/libgit2/commit/42e5db98b963ae503229c63e44e06e439df50e56\", \"tags\": [\"x_refsource_MISC\", \"x_transferred\"]}, {\"url\": \"https://github.com/libgit2/libgit2/commit/cd6f679af401eda1f172402006ef8265f8bd58ea\", \"name\": \"https://github.com/libgit2/libgit2/commit/cd6f679af401eda1f172402006ef8265f8bd58ea\", \"tags\": [\"x_refsource_MISC\", \"x_transferred\"]}, {\"url\": \"https://github.com/libgit2/libgit2/releases/tag/v1.4.5\", \"name\": \"https://github.com/libgit2/libgit2/releases/tag/v1.4.5\", \"tags\": [\"x_refsource_MISC\", \"x_transferred\"]}, {\"url\": \"https://github.com/libgit2/libgit2/releases/tag/v1.5.1\", \"name\": \"https://github.com/libgit2/libgit2/releases/tag/v1.5.1\", \"tags\": [\"x_refsource_MISC\", \"x_transferred\"]}, {\"url\": \"https://www.libssh2.org\", \"name\": \"https://www.libssh2.org\", \"tags\": [\"x_refsource_MISC\", \"x_transferred\"]}, {\"url\": \"http://www.openwall.com/lists/oss-security/2023/11/06/5\", \"tags\": [\"x_transferred\"]}], \"providerMetadata\": {\"orgId\": \"af854a3a-2127-422b-91ae-364da2661108\", \"shortName\": \"CVE\", \"dateUpdated\": \"2024-08-02T10:20:30.067Z\"}}, {\"title\": \"CISA ADP Vulnrichment\", \"metrics\": [{\"other\": {\"type\": \"ssvc\", \"content\": {\"id\": \"CVE-2023-22742\", \"role\": \"CISA Coordinator\", \"options\": [{\"Exploitation\": \"none\"}, {\"Automatable\": \"no\"}, {\"Technical Impact\": \"partial\"}], \"version\": \"2.0.3\", \"timestamp\": \"2025-03-10T20:59:36.699887Z\"}}}], \"providerMetadata\": {\"orgId\": \"134c704f-9b21-4f2e-91b3-4a467353bcc0\", \"shortName\": \"CISA-ADP\", \"dateUpdated\": \"2025-03-10T20:59:38.223Z\"}}], \"cna\": {\"title\": \"libgit2 fails to verify SSH keys by default\", \"source\": {\"advisory\": \"GHSA-8643-3wh5-rmjq\", \"discovery\": \"UNKNOWN\"}, \"metrics\": [{\"cvssV3_1\": {\"scope\": \"UNCHANGED\", \"version\": \"3.1\", \"baseScore\": 5.3, \"attackVector\": \"NETWORK\", \"baseSeverity\": \"MEDIUM\", \"vectorString\": \"CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:H/A:N\", \"integrityImpact\": \"HIGH\", \"userInteraction\": \"REQUIRED\", \"attackComplexity\": \"HIGH\", \"availabilityImpact\": \"NONE\", \"privilegesRequired\": \"NONE\", \"confidentialityImpact\": \"NONE\"}}], \"affected\": [{\"vendor\": \"libgit2\", \"product\": \"libgit2\", \"versions\": [{\"status\": \"affected\", \"version\": \"\u003c 1.4.5\"}, {\"status\": \"affected\", \"version\": \"= 1.5.0\"}]}], \"references\": [{\"url\": \"https://github.com/libgit2/libgit2/security/advisories/GHSA-8643-3wh5-rmjq\", \"name\": \"https://github.com/libgit2/libgit2/security/advisories/GHSA-8643-3wh5-rmjq\", \"tags\": [\"x_refsource_CONFIRM\"]}, {\"url\": \"https://github.com/libgit2/libgit2/commit/42e5db98b963ae503229c63e44e06e439df50e56\", \"name\": \"https://github.com/libgit2/libgit2/commit/42e5db98b963ae503229c63e44e06e439df50e56\", \"tags\": [\"x_refsource_MISC\"]}, {\"url\": \"https://github.com/libgit2/libgit2/commit/cd6f679af401eda1f172402006ef8265f8bd58ea\", \"name\": \"https://github.com/libgit2/libgit2/commit/cd6f679af401eda1f172402006ef8265f8bd58ea\", \"tags\": [\"x_refsource_MISC\"]}, {\"url\": \"https://github.com/libgit2/libgit2/releases/tag/v1.4.5\", \"name\": \"https://github.com/libgit2/libgit2/releases/tag/v1.4.5\", \"tags\": [\"x_refsource_MISC\"]}, {\"url\": \"https://github.com/libgit2/libgit2/releases/tag/v1.5.1\", \"name\": \"https://github.com/libgit2/libgit2/releases/tag/v1.5.1\", \"tags\": [\"x_refsource_MISC\"]}, {\"url\": \"https://www.libssh2.org\", \"name\": \"https://www.libssh2.org\", \"tags\": [\"x_refsource_MISC\"]}, {\"url\": \"http://www.openwall.com/lists/oss-security/2023/11/06/5\"}], \"descriptions\": [{\"lang\": \"en\", \"value\": \"libgit2 is a cross-platform, linkable library implementation of Git. When using an SSH remote with the optional libssh2 backend, libgit2 does not perform certificate checking by default. Prior versions of libgit2 require the caller to set the `certificate_check` field of libgit2\u0027s `git_remote_callbacks` structure - if a certificate check callback is not set, libgit2 does not perform any certificate checking. This means that by default - without configuring a certificate check callback, clients will not perform validation on the server SSH keys and may be subject to a man-in-the-middle attack. Users are encouraged to upgrade to v1.4.5 or v1.5.1. Users unable to upgrade should ensure that all relevant certificates are manually checked.\"}], \"problemTypes\": [{\"descriptions\": [{\"lang\": \"en\", \"type\": \"CWE\", \"cweId\": \"CWE-347\", \"description\": \"CWE-347: Improper Verification of Cryptographic Signature\"}]}], \"providerMetadata\": {\"orgId\": \"a0819718-46f1-4df5-94e2-005712e83aaa\", \"shortName\": \"GitHub_M\", \"dateUpdated\": \"2023-11-07T00:06:32.714Z\"}}}",
      "cveMetadata": "{\"cveId\": \"CVE-2023-22742\", \"state\": \"PUBLISHED\", \"dateUpdated\": \"2025-03-10T21:21:08.962Z\", \"dateReserved\": \"2023-01-06T14:21:05.892Z\", \"assignerOrgId\": \"a0819718-46f1-4df5-94e2-005712e83aaa\", \"datePublished\": \"2023-01-20T22:49:06.378Z\", \"assignerShortName\": \"GitHub_M\"}",
      "dataType": "CVE_RECORD",
      "dataVersion": "5.1"
    }
  }
}


Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Sightings

Author Source Type Date

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or seen somewhere by the user.
  • Confirmed: The vulnerability is confirmed from an analyst perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: This vulnerability was exploited and seen by the user reporting the sighting.
  • Patched: This vulnerability was successfully patched by the user reporting the sighting.
  • Not exploited: This vulnerability was not exploited or seen by the user reporting the sighting.
  • Not confirmed: The user expresses doubt about the veracity of the vulnerability.
  • Not patched: This vulnerability was not successfully patched by the user reporting the sighting.


Loading…

Loading…