Description
sourcegraph is a code intelligence platform. As a site admin it was possible to execute arbitrary commands on Gitserver when the experimental `customGitFetch` feature was enabled. This experimental feature has now been disabled by default. This issue has been patched in version 4.1.0.
Affected Software
Related
{"id": "CVE-2022-41943", "vendorId": null, "type": "cve", "bulletinFamily": "NVD", "title": "CVE-2022-41943", "description": "sourcegraph is a code intelligence platform. As a site admin it was possible to execute arbitrary commands on Gitserver when the experimental `customGitFetch` feature was enabled. This experimental feature has now been disabled by default. This issue has been patched in version 4.1.0.", "published": "2022-11-22T19:15:00", "modified": "2022-11-26T03:31:00", "cvss": {"score": 0.0, "vector": "NONE"}, "cvss2": {}, "cvss3": {"cvssV3": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "HIGH", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "HIGH", "availabilityImpact": "HIGH", "baseScore": 7.2, "baseSeverity": "HIGH"}, "exploitabilityScore": 1.2, "impactScore": 5.9}, "href": "https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2022-41943", "reporter": "security-advisories@github.com", "references": ["https://github.com/sourcegraph/sourcegraph/pull/42704", "https://github.com/sourcegraph/sourcegraph/security/advisories/GHSA-4qhq-4x4h-fxm8"], "cvelist": ["CVE-2022-41943"], "immutableFields": [], "lastseen": "2022-11-26T06:10:32", "viewCount": 10, "enchantments": {"score": {"value": 4.9, "vector": "NONE"}, "twitter": {"counter": 4, "tweets": [{"link": "https://twitter.com/www_sesin_at/status/1595168045231706133", "text": "New post from https://t.co/9KYxtdZjkl (CVE-2022-41943) has been published on https://t.co/lINOKeHFOw", "author": "www_sesin_at", "author_photo": "https://pbs.twimg.com/profile_images/958100963822329858/fb_N8h5n_400x400.jpg"}, {"link": "https://twitter.com/WolfgangSesin/status/1595168042895478802", "text": "New post from https://t.co/uXvPWJy6tj (CVE-2022-41943) has been published on https://t.co/o990EXYBhL", "author": "WolfgangSesin", "author_photo": "https://pbs.twimg.com/profile_images/957011635369054208/Om3jbj7z_400x400.jpg"}]}, "affected_software": {"major_version": [{"name": "sourcegraph", "version": 4}]}, "vulnersScore": 4.9}, "_state": {"dependencies": 1669443932, "score": 1669443990, "twitter": 0, "affected_software_major_version": 1671611801}, "_internal": {"score_hash": "50adc8773c56535df980b184c2c71a29"}, "cna_cvss": {"cna": "GitHub, Inc.", "cvss": {"3": {"vector": "CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:C/C:H/I:H/A:L", "score": 9.0}}}, "cpe": [], "cpe23": [], "cwe": ["CWE-276"], "affectedSoftware": [{"cpeName": "sourcegraph:sourcegraph", "version": "4.1.0", "operator": "lt", "name": "sourcegraph"}], "affectedConfiguration": [], "cpeConfiguration": {"CVE_data_version": "4.0", "nodes": [{"operator": "OR", "children": [], "cpe_match": [{"vulnerable": true, "cpe23Uri": "cpe:2.3:a:sourcegraph:sourcegraph:4.1.0:*:*:*:*:*:*:*", "versionEndExcluding": "4.1.0", "cpe_name": []}]}]}, "extraReferences": [{"url": "https://github.com/sourcegraph/sourcegraph/pull/42704", "name": "https://github.com/sourcegraph/sourcegraph/pull/42704", "refsource": "MISC", "tags": ["Issue Tracking", "Patch", "Third Party Advisory"]}, {"url": "https://github.com/sourcegraph/sourcegraph/security/advisories/GHSA-4qhq-4x4h-fxm8", "name": "https://github.com/sourcegraph/sourcegraph/security/advisories/GHSA-4qhq-4x4h-fxm8", "refsource": "CONFIRM", "tags": ["Third Party Advisory"]}]}
{"veracode": [{"lastseen": "2022-11-30T12:30:57", "description": "github.com/sourcegraph/sourcegraph is vulnerable to arbitrary code execution. The vulnerability exists in the `buildCustomFetchMappings` function in `customfetch.go` due to an experimental feature which if enabled on the gitserver which allows an attacker to inject and execute arbitrary commands. \n", "cvss3": {"exploitabilityScore": 1.2, "cvssV3": {"baseSeverity": "HIGH", "confidentialityImpact": "HIGH", "attackComplexity": "LOW", "scope": "UNCHANGED", "attackVector": "NETWORK", "availabilityImpact": "HIGH", "integrityImpact": "HIGH", "privilegesRequired": "HIGH", "baseScore": 7.2, "vectorString": "CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H", "version": "3.1", "userInteraction": "NONE"}, "impactScore": 5.9}, "published": "2022-11-24T11:49:12", "type": "veracode", "title": "Arbitrary Code Execution", "bulletinFamily": "software", "cvss2": {}, "cvelist": ["CVE-2022-41943"], "modified": "2022-11-30T00:05:02", "id": "VERACODE:38239", "href": "https://sca.analysiscenter.veracode.com/vulnerability-database/security/1/1/sid-38239/summary", "cvss": {"score": 0.0, "vector": "NONE"}}]}