# GHSA-6h2x-4gjf-jc5w: autogluon.multimodal vulnerable to unsafe YAML deserialization

> An unsafe YAML deserialization flaw in autogluon.multimodal allows attackers to execute arbitrary code or cause denial of service by providing malicious YAML files.

- **Severity:** Not scored
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** A user has to click or open something
- **Fix available:** Yes
- **Published:** 21 Sep 2022

## What is GHSA-6h2x-4gjf-jc5w?

GHSA-6h2x-4gjf-jc5w is an unsafe deserialization vulnerability in autogluon-multimodal, published on 21 Sep 2022. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.

### Official description

### Impact

A potential unsafe deserialization issue exists within the `autogluon.multimodal` module, where YAML files are loaded via `yaml.load()` instead of `yaml.safe_load()`. The deserialization of untrusted data may allow an unprivileged third party to cause remote code execution, denial of service, and impact to both confidentiality and integrity.

Impacted versions: `>=0.4.0;<0.4.3`, `>=0.5.0;<0.5.2`.

### Patches
The patches are included in `autogluon.multimodal==0.4.3`, `autogluon.multimodal==0.5.2` and Deep Learning Containers `0.4.3` and `0.5.2`.

### Workarounds
Do not load data which originated from an untrusted source, or that could have been tampered with. **Only load data you trust.**

### References
* https://cwe.mitre.org/data/definitions/502.html
* https://www.cvedetails.com/cve/CVE-2017-18342/

## Which versions are affected by GHSA-6h2x-4gjf-jc5w?

4 open source packages ship an affected version, including autogluon-multimodal and autogluon.multimodal.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `autogluon-multimodal` | PyPI | From 0.4.0 | 0.4.3 |
| `autogluon-multimodal` | PyPI | From 0.5.0 | 0.5.2 |
| `autogluon.multimodal` | PyPI | From 0.4.0 | 0.4.3 |
| `autogluon.multimodal` | PyPI | From 0.5.0 | 0.5.2 |

## How do I fix GHSA-6h2x-4gjf-jc5w?

Upgrade autogluon-multimodal to a fixed version for your release line: 0.4.3 or 0.5.2.

## Is GHSA-6h2x-4gjf-jc5w being exploited?

There is no known exploitation of GHSA-6h2x-4gjf-jc5w in the wild and no public exploit code.

## Fix prompt for AI coding agents

```text
Check this codebase for GHSA-6h2x-4gjf-jc5w and fix it if it is affected.

What it is: GHSA-6h2x-4gjf-jc5w is an unsafe deserialization vulnerability in autogluon-multimodal, published on 21 Sep 2022. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Exploitation: There is no known exploitation of GHSA-6h2x-4gjf-jc5w in the wild and no public exploit code.

Affected packages and fixed versions:
- autogluon-multimodal (PyPI): affected from 0.4.0; fixed in 0.4.3
- autogluon-multimodal (PyPI): affected from 0.5.0; fixed in 0.5.2
- autogluon.multimodal (PyPI): affected from 0.4.0; fixed in 0.4.3
- autogluon.multimodal (PyPI): affected from 0.5.0; fixed in 0.5.2

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-6h2x-4gjf-jc5w/ (Markdown: https://insights.sbomify.com/GHSA-6h2x-4gjf-jc5w/index.md)
```

## Sources

- OSV: https://osv.dev/vulnerability/GHSA-6h2x-4gjf-jc5w

---
From sbomify Insights: https://insights.sbomify.com/GHSA-6h2x-4gjf-jc5w/
Summaries are generated and may contain mistakes; the official description above is the record.
