Local File Inclusion

Affecting pimcore/pimcore package, versions <6.8.8

Report new vulnerabilities
Do your applications use this vulnerable package? Test your applications

Overview

pimcore/pimcore is a content & product management framework (CMS/PIM/E-Commerce).

Affected versions of this package are vulnerable to Local File Inclusion. A Local FIle Inclusion vulnerability exists in the downloadCsvAction function of the CustomReportController class (bundles/AdminBundle/Controller/Reports/CustomReportController.php). An authenticated user can reach this function with a GET request at the following endpoint: /admin/reports/custom-report/download-csv?exportFile=&#91;filename]. Since exportFile variable is not sanitized, an attacker can exploit a local file inclusion vulnerability.

PoC

* Login in Pimcore
* Send a GET request to the endpoint: /admin/reports/custom-report/download-csv?exportFile=../../../../../../../../../../../../../../../etc/passwd to retrieve del passwd file of the Linux system. (Inside the request insert the header X-pimcore-csrf-token).

Remediation

Upgrade pimcore/pimcore to version 6.8.8 or higher.

References

CVSS Score

7.1
high severity
  • Attack Vector
    Network
  • Attack Complexity
    Low
  • Privileges Required
    Low
  • User Interaction
    None
  • Scope
    Unchanged
  • Confidentiality
    High
  • Integrity
    Low
  • Availability
    None
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:N/E:F/RL:O/RC:C
Credit
Daniele Scanu
CVE
CVE-2021-23340
CWE
CWE-23
Snyk ID
SNYK-PHP-PIMCOREPIMCORE-1070132
Disclosed
18 Feb, 2021
Published
18 Feb, 2021