# RUSTSEC-2026-0288: cosmian_kyber: AVX2 backend skips Fujisaki-Okamoto implicit rejection, enabling chosen-ciphertext key recovery

> Enabling the AVX2 feature in cosmian_kyber breaks implicit rejection, allowing attackers to recover static secret keys via chosen-ciphertext attacks.

- **Severity:** Not scored
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** No
- **Published:** 16 Aug 2026

## What is RUSTSEC-2026-0288?

RUSTSEC-2026-0288 is a vulnerability in cosmian_kyber, published on 16 Aug 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

## Summary

`cosmian_kyber` is a fork of `Argyle-Software/kyber` and inherits a broken
constant-time conditional-move routine `cmov` in its AVX2 backend. When built
with the opt-in `avx2` feature on x86_64, `cmov` is a no-op: it never performs
the copy. That `cmov` is the step that applies the Fujisaki-Okamoto (FO) implicit
rejection during decapsulation. With it disabled, decapsulating an *invalid*
ciphertext no longer returns a key-independent pseudorandom value; it returns a
value that depends on the decrypted plaintext of the attacker-chosen ciphertext.
This restores the chosen-ciphertext decryption oracle that the FO transform
exists to remove, and yields full recovery of the static secret key.

The attack requires no timing measurement, no side channel, and no faults; only
the ability to submit ciphertexts to a decapsulation operation under a reused
key pair and observe the resulting shared secret. See the linked pull request
for the root cause and the reachable call path.

## Affected configuration

Reachable only in builds with `features = ["avx2"]` on an x86_64 target. The
default (reference) backend and all non-x86_64 targets are unaffected.

## Impact

Complete IND-CCA break. The plaintext-checking oracle drives a standard
chosen-ciphertext key-recovery attack and extracts the entire static secret key.
Any protocol reusing a Kyber key pair across decapsulations is exposed;
ephemeral-only key shares are not. The identical defect in the parent crate was
verified end to end on ML-KEM-768 (full key recovered in 4,272 decapsulation
queries).

## Maintenance status

`cosmian_kyber` is a stale fork (last published 0.1.0, January 2023) of an
unmaintained upstream, and no fixed release is expected.

## Mitigation

- If remaining on this crate, do not enable the `avx2` feature; the default
  reference backend performs implicit rejection correctly.
- Do not reuse a Kyber key pair across decapsulations.

## Credit

Reported by 007bsd.

## Which versions are affected by RUSTSEC-2026-0288?

1 open source package ship an affected version, including cosmian_kyber.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `cosmian_kyber` | crates.io | From 0.0.0-0 | None |

## How do I fix RUSTSEC-2026-0288?

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

## Is RUSTSEC-2026-0288 being exploited?

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

## Fix prompt for AI coding agents

```text
Check this codebase for RUSTSEC-2026-0288 and fix it if it is affected.

What it is: RUSTSEC-2026-0288 is a vulnerability in cosmian_kyber, published on 16 Aug 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 RUSTSEC-2026-0288 in the wild and no public exploit code.

Affected packages and fixed versions:
- cosmian_kyber (crates.io): affected from 0.0.0-0; no fix listed

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

## Sources

- OSV: https://osv.dev/vulnerability/RUSTSEC-2026-0288

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