🛡️ GHSA-3vwr-jj4f-h98x — ezpublish-kernel
Description
eZ Publish Remote code execution in file uploads
This Security Advisory is about a vulnerability in the way eZ Platform and eZ Publish Legacy handles file uploads, which can in the worst case lead to remote code execution (RCE), a very serious threat. An attacker would need access to uploading files to be able to exploit the vulnerability, so if you have strict controls on this and trust all who have this permission, you're not affected. On the basis of the tests we have made, we also believe the vulnerability cannot be exploited as long as our recommended vhost configuration is used. Here is the v2.5 recommendation for Nginx, as an example:
https://github.com/ezsystems/ezplatform/blob/2.5/doc/nginx/vhost.template#L31
This vhost template specifies that only the file app.php in the web root is executed, while vulnerable configurations allow execution of any php file. Apache is affected in the same way as Nginx, and is also protected by using the recommended configuration. The build-in webserver in PHP stays vulnerable, as it doesn't use this type of configuration (this webserver should only be used for development, never for production). We cannot be 100% certain our configuration is not vulnerable. We also do not know if all our users use the recommended configuration, so we send out this fix to be on the safe side.
The fix includes a blacklist feature for uploaded filenames, such as ".php". The file types on the blacklist cannot be uploaded. The blacklist is configurable. In eZ Platform you will find it as ezsettings.default.io.file_storage.file_type_blacklist in eZ/Bundle/EzPublishCoreBundle/Resources/config/default_settings.yml in vendors/ezsystems/ezpublish-kernel. In eZ Publish Legacy you will find it as FileExtensionBlackList in settings/file.ini. By default it blocks these file types: php, php3, phar, phpt, pht, phtml, pgif. The fix also inclues a new block against path traversal attacks, though this kind of attack was not reproducible in our tests.
Weakness class
GHSA-3vwr-jj4f-h98x is classified as CWE-94: Code Injection. Input is incorporated into code that the runtime evaluates, so an attacker can have their own code executed.
Affected software
GHSA-3vwr-jj4f-h98x is recorded against 1 package.
- ezsystems/ezpublish-kernel (from 5.4.0 up to 5.4.14.1)
Timeline and source
Published on 15 May 2024 and last revised on 29 November 2024. No public exploit is currently recorded for this entry. Record sourced from OSV.
References
ezplatform.com (Web)
github.com (Web)
github.com (Package)
web.archive.org (Web)
Details
Affected Packages
| Software | From version | Fixed in |
|---|---|---|
| ezsystems/ezpublish-kernel | 5.4.0 | 5.4.14.1 |
References
Similar Threats
- High GHSA-64vj-933f-6pm3
- Unknown GHSA-9wwx-c723-vm8x
- Low GHSA-946c-f9w6-2c25
- Unknown CVE-2021-46876
- High CVE-2022-48365
Site Security Check
Is ezpublish-kernel part of your stack?
GHSA-3vwr-jj4f-h98x is rated CVSS 8.0 High. BotEraser scans your installation against known CVE records and tells you whether this vulnerability applies to the versions you actually run.
Scan My Site Free →No credit card required · Results in minutes
ⓘ Data Notice: The information presented above has been compiled from publicly available internet sources. Boteraser aggregates this data solely for informational purposes and does not independently classify, evaluate, or endorse any findings about the vulnerabilities listed. The accuracy and completeness of this information is the sole responsibility of the original publishers. Boteraser and its operators accept no liability for any decisions made based on this data.