gitconnectgit in connect.c in Git before 2.30.1 allows a repository path to contain a newline character, which may result in unexpected cross-protocol requests, as demonstrated by the git://localhost:1234/%0d%0a%0d%0aGET%20/%20HTTP/1.1 substring.
[
{
"id": "CVE-2021-40330-7f6a1f13",
"source": "https://github.com/git/git/commit/a02ea577174ab8ed18f847cf1693f213e0b9c473",
"deprecated": false,
"signature_version": "v1",
"target": {
"function": "git_connect_git",
"file": "connect.c"
},
"digest": {
"length": 710.0,
"function_hash": "230735358351763402630356967767374818080"
},
"signature_type": "Function"
},
{
"id": "CVE-2021-40330-df968e5b",
"source": "https://github.com/git/git/commit/a02ea577174ab8ed18f847cf1693f213e0b9c473",
"deprecated": false,
"signature_version": "v1",
"target": {
"file": "connect.c"
},
"digest": {
"threshold": 0.9,
"line_hashes": [
"133355785385257712963848992325578550264",
"235724189758691676970782344456206164053",
"193312243769820270394387628664609223536",
"143481889806468762248610901874244410742"
]
},
"signature_type": "Line"
}
]