# CVE-2026-84897: Denial of service in wolfSSH

> An unauthenticated remote attacker can cause CPU exhaustion in wolfSSH servers by sending malformed Diffie-Hellman key exchange messages, leading to denial of service.

- **Severity:** Medium 6.9 (`CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/AU:Y`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** No
- **Published:** 7 Oct 2026
- **Updated:** 7 Oct 2026
- **Also known as:** GHSA-39q2-5h5r-39p7

## What is CVE-2026-84897?

CVE-2026-84897 is a medium-severity denial of service vulnerability in wolfSSL Inc. wolfSSH, published on 7 Oct 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

src/internal.c in wolfSSL wolfSSH through 1.5.0 admits the server-to-client Diffie-Hellman group exchange messages SSH_MSG_KEX_DH_GEX_GROUP (31) and SSH_MSG_KEX_DH_GEX_REPLY (33) when a server receives them from an unauthenticated client. IsMessageAllowedServer() applies no direction check to the key exchange message range: when the peer is keying and no particular message is expected, which is the state a server is in for the whole window after it processes the client's KEXINIT because nothing sets handshake->expectMsgId there, the function falls out of its expectation branch without a verdict and reaches a numeric bound that admits every message id from 30 through 34. A client that negotiates diffie-hellman-group-exchange-sha256 and then sends message 31 makes the server run the client-side handler DoKexDhGexGroup(), which validates the attacker-supplied group with two 8-round Miller-Rabin primality tests, one on p and one on (p-1)/2, on a value of up to 8192 bits. The handler then returns success: the server stores the attacker's prime and generator, generates a Diffie-Hellman key pair in the attacker's group, and sends the client-role message SSH_MSG_KEX_DH_GEX_INIT (32) back to the attacker. Published RFC 3526 safe primes are the worst-case input and cost the attacker nothing to obtain. The primality validation was added in 1.5.0; versions from 1.2.0 through 1.4.22 admit the same message and enter the same client-role path without the primality cost. Message 33 is admitted as well, but on a server it is rejected before any cryptography because no public key check callback is registered, so it carries no comparable cost. Builds that define WOLFSSH_NO_DH_GEX_SHA256, which is implied by WOLFSSH_NO_DH or NO_SHA256, are unaffected.

Weakness: CWE-400 (Uncontrolled Resource Consumption), CWE-405 (Asymmetric Resource Consumption (Amplification)), CWE-372 (Incomplete Internal State Distinction)

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

It affects 1 product.


Products: Wolfssh Wolfssh.

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

No fix has been published for CVE-2026-84897 yet. Limit exposure of the affected software until one is available.

## Is CVE-2026-84897 being exploited?

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

## Other vulnerabilities in wolfSSL Inc. wolfSSH

- [CVE-2022-32073](https://insights.sbomify.com/CVE-2022-32073/): Integer overflow in n/a (critical 9.8)
- [CVE-2025-14942](https://insights.sbomify.com/CVE-2025-14942/): Authentication Bypass (critical 9.4)
- [CVE-2025-11625](https://insights.sbomify.com/CVE-2025-11625/): Host verification bypass and credential leak (critical 9.4)
- [CVE-2024-2873](https://insights.sbomify.com/CVE-2024-2873/): User authentication bypass in wolfSSH server (critical 9.1)
- [CVE-2026-16516](https://insights.sbomify.com/CVE-2026-16516/): wolfSSH ECDSA host key curve not validated against negotiated algorithm (critical 9.0)

## Fix prompt for AI coding agents

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

What it is: CVE-2026-84897 is a medium-severity denial of service vulnerability in wolfSSL Inc. wolfSSH, published on 7 Oct 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-84897 in the wild and no public exploit code.

Affected product: wolfSSL Inc. wolfSSH. 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-2026-84897/ (Markdown: https://insights.sbomify.com/CVE-2026-84897/index.md)
```

## Sources

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

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