# CVE-2025-31161: CrushFTP Authentication Bypass

> Attackers can bypass authentication to gain administrative access and compromise the system via a race condition in the AWS4-HMAC authorization method.

- **Severity:** Critical 9.8 (`CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`)
- **Exploited in the wild:** Yes, since 7 Apr 2025 (CISA KEV), used in ransomware
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** No
- **Published:** 3 Apr 2025
- **Updated:** 21 Oct 2025
- **Also known as:** CVE-2025-2825, GHSA-c57h-rx24-vf52

## What is CVE-2025-31161?

CVE-2025-31161 is a critical authentication bypass vulnerability in CrushFTP, published on 3 Apr 2025. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

CrushFTP 10 before 10.8.4 and 11 before 11.3.1 allows authentication bypass and takeover of the crushadmin account (unless a DMZ proxy instance is used), as exploited in the wild in March and April 2025, aka "Unauthenticated HTTP(S) port access." A race condition exists in the AWS4-HMAC (compatible with S3) authorization method of the HTTP component of the FTP server. The server first verifies the existence of the user by performing a call to login_user_pass() with no password requirement. This will authenticate the session through the HMAC verification process and up until the server checks for user verification once more. The vulnerability can be further stabilized, eliminating the need for successfully triggering a race condition, by sending a mangled AWS4-HMAC header. By providing only the username and a following slash (/), the server will successfully find a username, which triggers the successful anypass authentication process, but the server will fail to find the expected SignedHeaders entry, resulting in an index-out-of-bounds error that stops the code from reaching the session cleanup. Together, these issues make it trivial to authenticate as any known or guessable user (e.g., crushadmin), and can lead to a full compromise of the system by obtaining an administrative account.

Weakness: CWE-305 (Authentication Bypass by Primary Weakness)

## Which versions are affected by CVE-2025-31161?

It affects 1 product.


Products: Crushftp Crushftp.

## How do I fix CVE-2025-31161?

No fix has been published for CVE-2025-31161 yet. Limit exposure of the affected software until one is available. US federal agencies must fix it by 28 Apr 2025.

## Is CVE-2025-31161 being exploited?

Yes. Attackers have exploited CVE-2025-31161 in the wild since at least 7 Apr 2025, including in ransomware campaigns.

Public exploit code:

- Proof of Concept for CVE-2025-31161 / CVE-2025-2825 (github_poc): https://github.com/Immersive-Labs-Sec/CVE-2025-31161
- 🛡️ CVE-2025-31161 - CrushFTP User Creation Authentication Bypass Exploit (github_poc): https://github.com/0xgh057r3c0n/CVE-2025-31161
- CrushFTP CVE-2025-31161 Exploit Tool 🔓 (github_poc): https://github.com/TX-One/CVE-2025-31161
- PoC CVE-2025-31161 - Authentication Bypass CrushFTP (github_poc): https://github.com/f4dee-backup/CVE-2025-31161
- https://github.com/c4bsec/CVE-2025-31161 (github_poc): https://github.com/c4bsec/CVE-2025-31161
- Official Nuclei template for CVE-2025-31161 (formerly CVE-2025-2825) (github_poc): https://github.com/SUPRAAA-1337/Nuclei_CVE-2025-31161_CVE-2025-2825

## Other vulnerabilities in CrushFTP

- [CVE-2024-4040](https://insights.sbomify.com/CVE-2024-4040/): CrushFTP VFS Sandbox Escape (critical 9.8, exploited in the wild)
- [CVE-2025-54309](https://insights.sbomify.com/CVE-2025-54309/): CrushFTP Unprotected Alternate Channel (critical 9.0, exploited in the wild)
- [CVE-2024-53552](https://insights.sbomify.com/CVE-2024-53552/): Auth bypass in n/a (critical 9.8)
- [CVE-2023-43177](https://insights.sbomify.com/CVE-2023-43177/): Deserialization in n/a (critical 9.8)
- [CVE-2017-14035](https://insights.sbomify.com/CVE-2017-14035/): Deserialization in n/a (critical 9.8)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2025-31161 and fix it if it is affected.

What it is: CVE-2025-31161 is a critical authentication bypass vulnerability in CrushFTP, published on 3 Apr 2025. An attacker can exploit it over the internet without logging in, with no action from the victim.
Exploitation: Yes. Attackers have exploited CVE-2025-31161 in the wild since at least 7 Apr 2025, including in ransomware campaigns.

Affected product: CrushFTP. No package-level version data is available, so check the vendor advisory linked from the reference page.

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

## Sources

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

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