Free and open · new CVEs checked every 20 minutesStatusRSSOpen dataContact

CVE-2026-40991: When using spring-restdocs-webtestclient or spring-restdocs-restassured to document a remote API accessed over

24
Routine
MEDIUM 5.9UPGRADE

CVE-2026-40991 is a medium-severity flaw (CVSS 5.9) affecting spring rest docs. Below: why it ranks where it does, which versions are affected, what to do, and the exact commands.

When using spring-restdocs-webtestclient or spring-restdocs-restassured to document a remote API accessed over HTTP, an attacker who compromises the API or tricks the user into documenting a malicious API can perform an XXE injection attack when the documentation-generating tests are next executed. Affected versions: Spring REST Docs 4.0.0; 3.0.0 through 3.0.5; 2.0.0.RELEASE through 2.0.8.RELEASE.

Why this priority

  • No elevated risk signals yet

A fixed release or distro patch exists.

Risk facts

CVSS score5.9 (Medium)
Attack vectorNetwork (remote)
Attack complexityHigh
Privileges neededNone
User interactionRequired
EPSS exploit chance0.2% (top 87%)
CISA exploited listNo
WeaknessCWE-611
Published2026-06-10
Last modified2026-07-23
Publisher (CNA): VMware · Vendor: broadcom

Share: LinkedIn · X · Reddit

Last updated 2026-07-23 · Sources: CVE Program, NVD, CISA KEV, EPSS and vendor advisories · How we score

Am I affected?

Timeline

broadcom spring rest docs UPGRADE
Affected: >= 2.0.0 and < 2.0.9 · >= 3.0.0 and < 3.0.5.1 · 4.0.0
Fixed in: 2.0.9, 3.0.5.1
Safe to downgrade to: a release before 2.0.0
1. Check installed version
apt-cache policy spring-rest-docs || rpm -q spring-rest-docs || spring-rest-docs --version
2. UPGRADE to 2.0.9 (Debian / Ubuntu)
sudo apt update && sudo apt install --only-upgrade spring-rest-docs
2. UPGRADE (RHEL / Amazon Linux / Fedora)
sudo dnf upgrade spring-rest-docs
Note
Distros often backport fixes without changing the version number. Confirm with the distro advisory or changelog.
3. If no update is available yet, DOWNGRADE to a release before 2.0.0 (Debian / Ubuntu)
apt-cache madison spring-rest-docs sudo apt install spring-rest-docs=<VERSION_BEFORE_2.0.0> sudo apt-mark hold spring-rest-docs
3. If no update is available yet, DOWNGRADE (RHEL / Amazon Linux / Fedora)
dnf --showduplicates list spring-rest-docs sudo dnf downgrade spring-rest-docs-<VERSION_BEFORE_2.0.0> sudo dnf versionlock add spring-rest-docs
Downgrade risk
Downgrading can break dependent software and may reopen older bugs. Read the distro advisory first and test on a non-production host.
After downgrade
Restart the service, and keep the package held until a fixed release ships.
Verify at the official source NVD · CVE Program · Report a problem with this page
Scores and fixes here are computed automatically from those and other public sources. Confirm with the vendor advisory before changing production systems.

Quick answers

How do I fix CVE-2026-40991?

spring rest docs: upgrade to 2.0.9, 3.0.5.1. Exact commands for each OS are on this page.

Is CVE-2026-40991 being exploited?

CVE-2026-40991 is not on the CISA Known Exploited Vulnerabilities list at the time of the last update. Check again, as this can change.

What does CVE-2026-40991 affect?

CVE-2026-40991 affects spring rest docs. Severity is medium (CVSS 5.9). When using spring-restdocs-webtestclient or spring-restdocs-restassured to document a remote API accessed over HTTP, an attacker who compromises the API or tricks the user into documenting a malicious API can perform an XXE injection attack

How urgent is CVE-2026-40991?

Priority 24/100. No elevated risk signals yet.

References

← Back to latest CVEs

Get the weekly exploited-CVE digest by emailThe CVEs being attacked this week and how to fix them. No spam, unsubscribe any time.