High severity · published May 5, 2022
CVE-2022-29171
Remote Code Execution in sourcegraph
7.2
CVSS
1.4%
EPSS
No
On KEV
Description
Sourcegraph is a fast and featureful code search and navigation engine. Versions before 3.38.0 are vulnerable to Remote Code Execution in the gitserver service. The Gitolite code host integration with Phabricator allows Sourcegraph site admins to specify a `callsignCommand`, which is used to obtain the Phabricator metadata for a Gitolite repository. An administrator who is able to edit or add a Gitolite code host and has administrative access to Sourcegraph’s bundled Grafana instance can change this command arbitrarily and run it remotely. This grants direct access to the infrastructure underlying the Sourcegraph installation. The attack requires: site-admin privileges on the instance of Sourcegraph, Administrative privileges on the bundled Grafana monitoring instance, Knowledge of the gitserver IP address or DNS name (if running in Kubernetes). This can be found through Grafana. The issue is patched in version 3.38.0. You may disable Gitolite code hosts. We still highly encourage upgrading regardless of workarounds.
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H
Attack vector
Network
Complexity
Low
Privileges
High
User interaction
None
Confidentiality
High
Integrity
High
Availability
High
Scope
Unchanged
Exploitation
Is it being used?
Exploit prediction (EPSS)1.4% · higher than 71% of CVEs
Exploited in the wildNo evidence yet
CISA KEVNot listed
Ransomware campaign useNot known
Affected products
Which versions
SO
sourcegraph · sourcegraph
< 3.38.0 · source: vendor, NVD
Affected product
SO
sourcegraph
sourcegraph
More from sourcegraph
8.8
CVE-2022-23642
Code Injection in Sourcegraph
7.8
CVE-2022-41942
Sourcegraph vulnerable to Comand Injection via gitserver
7.2
CVE-2022-41943
Incorrect default permissions found in Sourcegraph
6.5
CVE-2022-23643
Side-channel attack in Sourcegraph Code Monitors
6.5
CVE-2021-43823
Side-channel attack in Sourcegraph