GHSA-6mgp-v5cm-ghg5 Drupal core Remote Code Execution

Not scored Published

An attacker can execute arbitrary code on the server by exploiting unsanitized shell arguments in Drupal's email system.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is GHSA-6mgp-v5cm-ghg5?

GHSA-6mgp-v5cm-ghg5 is a command injection vulnerability in drupal/core, published on 15 May 2024. Any signed-in user can exploit it over the network, with no action from the victim.

Official description

In Drupal core, when sending email some variables were not being sanitized for shell arguments in DefaultMailSystem::mail(), which could lead to remote code execution.

Which versions are affected by GHSA-6mgp-v5cm-ghg5?

6 open source packages ship an affected version, including drupal/core.

PackageAffectedFixed in
drupal/core PackagistFrom 7.07.60
drupal/core PackagistFrom 7.07.60
drupal/core PackagistFrom 8.0.08.5.8
drupal/core PackagistFrom 8.0.08.5.8
drupal/core PackagistFrom 8.6.08.6.2
drupal/core PackagistFrom 8.6.08.6.2

How do I fix GHSA-6mgp-v5cm-ghg5?

Upgrade drupal/core to a fixed version for your release line: 7.60, 8.5.8 or 8.6.2.

Upgrade, and pass arguments to programs as a list instead of through a shell. More about Command injection.

Is GHSA-6mgp-v5cm-ghg5 being exploited?

There is no known exploitation of GHSA-6mgp-v5cm-ghg5 in the wild and no public exploit code.

Sources

Is GHSA-6mgp-v5cm-ghg5 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free