# GHSA-6xch-2vxx-5pvr: eZ Platform Rules to disable executable access are ignored on Platform.sh (eZ Cloud)

> Attackers can download executable files from the var directory on eZ Platform Cloud due to missing access control rules, potentially exposing sensitive code.

- **Severity:** Not scored
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 15 May 2024

## What is GHSA-6xch-2vxx-5pvr?

GHSA-6xch-2vxx-5pvr is a vulnerability in ezsystems/ezplatform, published on 15 May 2024. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

The recommended Apache/Nginx virtual host configuration for eZ Platform includes a rewrite rule for blocking access to executable files in the var directory. This rule does not work when using eZ Platform Cloud (i.e. running eZ Platform on the Platform.sh cloud service).
 
The consequence of this is that in such a setup, those executable files may be downloadable. They will not be executable, unless you have specifically configured platform.sh to allow that (which you really should not do). The severity of the download access is limited, but it's better if the platform.sh cloud setup works the same way as regular eZ Platform does. All platform.sh setups are affected.
 
The fix adds a rule to the .platform.app.yaml configuration file, with the same effect as the rewrite rule already mentioned. After applying the fix, any attempt to access such files will fail with Access Denied. This security update is distributed via Composer as ezsystems/ezplatform 1.7.9.1, and 1.13.5.1, and 2.5.4. This is the commit: https://github.com/ezsystems/ezplatform/commit/773dddc0d8fe4fda34d2153a401eeaa6cc30b1ff

## Which versions are affected by GHSA-6xch-2vxx-5pvr?

6 open source packages ship an affected version, including ezsystems/ezplatform.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `ezsystems/ezplatform` | Packagist | From 1.13.0 | 1.13.5.1 |
| `ezsystems/ezplatform` | Packagist | From 1.13.0 | 1.13.5.1 |
| `ezsystems/ezplatform` | Packagist | From 1.7.0 | 1.7.9.1 |
| `ezsystems/ezplatform` | Packagist | From 1.7.0 | 1.7.9.1 |
| `ezsystems/ezplatform` | Packagist | From 2.5.0 | 2.5.4 |
| `ezsystems/ezplatform` | Packagist | From 2.5.0 | 2.5.4 |

## How do I fix GHSA-6xch-2vxx-5pvr?

Upgrade ezsystems/ezplatform to a fixed version for your release line: 1.13.5.1, 1.7.9.1 or 2.5.4.

## Is GHSA-6xch-2vxx-5pvr being exploited?

There is no known exploitation of GHSA-6xch-2vxx-5pvr in the wild and no public exploit code.

## Fix prompt for AI coding agents

```text
Check this codebase for GHSA-6xch-2vxx-5pvr and fix it if it is affected.

What it is: GHSA-6xch-2vxx-5pvr is a vulnerability in ezsystems/ezplatform, published on 15 May 2024. An attacker can exploit it over the internet without logging in, with no action from the victim.
Exploitation: There is no known exploitation of GHSA-6xch-2vxx-5pvr in the wild and no public exploit code.

Affected packages and fixed versions:
- ezsystems/ezplatform (Packagist): affected from 1.13.0; fixed in 1.13.5.1
- ezsystems/ezplatform (Packagist): affected from 1.13.0; fixed in 1.13.5.1
- ezsystems/ezplatform (Packagist): affected from 1.7.0; fixed in 1.7.9.1
- ezsystems/ezplatform (Packagist): affected from 1.7.0; fixed in 1.7.9.1
- ezsystems/ezplatform (Packagist): affected from 2.5.0; fixed in 2.5.4
- ezsystems/ezplatform (Packagist): affected from 2.5.0; fixed in 2.5.4

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/GHSA-6xch-2vxx-5pvr/ (Markdown: https://insights.sbomify.com/GHSA-6xch-2vxx-5pvr/index.md)
```

## Sources

- OSV: https://osv.dev/vulnerability/GHSA-6xch-2vxx-5pvr

---
From sbomify Insights: https://insights.sbomify.com/GHSA-6xch-2vxx-5pvr/
Summaries are generated and may contain mistakes; the official description above is the record.
