# CVE-2026-33942: Saloon has insecure deserialization in AccessTokenAuthenticator (object injection / RCE)

> An attacker can achieve remote code execution by supplying malicious serialized data to the OAuth token authenticator in this PHP library.

- **Severity:** High 8.1 (`CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:U`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 26 Mar 2026
- **Updated:** 28 Mar 2026
- **Also known as:** CVE-2026-33181, GHSA-rf88-776r-rcq9

## What is CVE-2026-33942?

CVE-2026-33942 is a high-severity unsafe deserialization vulnerability in saloonphp saloon, published on 26 Mar 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

Saloon is a PHP library that gives users tools to build API integrations and SDKs. Versions prior to 4.0.0 used PHP's unserialize() in AccessTokenAuthenticator::unserialize() to restore OAuth token state from cache or storage, with allowed_classes => true. An attacker who can control the serialized string (e.g. by overwriting a cached token file or via another injection) can supply a serialized "gadget" object. When unserialize() runs, PHP instantiates that object and runs its magic methods (__wakeup, __destruct, etc.), leading to object injection. In environments with common dependencies (e.g. Monolog), this can be chained to remote code execution (RCE). The fix in version 4.0.0 removes PHP serialization from the AccessTokenAuthenticator class requiring users to store and resolve the authenticator manually.

Weakness: CWE-502 (Deserialization of Untrusted Data)

## Which versions are affected by CVE-2026-33942?

2 open source packages ship an affected version, including saloonphp/saloon. It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `saloonphp/saloon` | Packagist | All versions | 4.0.0 |
| `saloonphp/saloon` | Packagist | All versions | 4.0.0 |

Products: Saloon Saloon.

## How do I fix CVE-2026-33942?

Upgrade saloonphp/saloon to 4.0.0 or later.

## Is CVE-2026-33942 being exploited?

There is no known exploitation of CVE-2026-33942 in the wild and no public exploit code.

## Other vulnerabilities in saloonphp saloon

- [CVE-2026-33183](https://insights.sbomify.com/CVE-2026-33183/): Saloon has a Fixture Name Path Traversal Vulnerability (high 8.0)
- [CVE-2026-33182](https://insights.sbomify.com/CVE-2026-33182/): Saloon is vulnerable to SSRF and credential leakage via absolute URL in endpoint overriding base URL (medium 6.6)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2026-33942 and fix it if it is affected.

What it is: CVE-2026-33942 is a high-severity unsafe deserialization vulnerability in saloonphp saloon, published on 26 Mar 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.
Exploitation: There is no known exploitation of CVE-2026-33942 in the wild and no public exploit code.

Affected packages and fixed versions:
- saloonphp/saloon (Packagist): affected all versions; fixed in 4.0.0
- saloonphp/saloon (Packagist): affected all versions; fixed in 4.0.0

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/CVE-2026-33942/ (Markdown: https://insights.sbomify.com/CVE-2026-33942/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2026-33942
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2026-33942
- OSV: https://osv.dev/vulnerability/CVE-2026-33942

---
From sbomify Insights: https://insights.sbomify.com/CVE-2026-33942/
Summaries are generated and may contain mistakes; the official description above is the record.
