CVE-2024-38828

5.3 MEDIUM

📋 TL;DR

Spring MVC applications with @RequestBody byte[] parameters are vulnerable to denial-of-service attacks where attackers can send specially crafted requests to consume excessive memory. This affects Spring Framework applications using Spring MVC with specific controller method signatures. The vulnerability allows resource exhaustion but not code execution.

💻 Affected Systems

Products:
  • Spring Framework
  • Spring Boot
  • Applications using Spring MVC
Versions: Spring Framework 6.1.0 - 6.1.18, 6.0.0 - 6.0.28, 5.3.0 - 5.3.33
Operating Systems: All
Default Config Vulnerable: ⚠️ Yes
Notes: Only affects applications with Spring MVC controllers using @RequestBody byte[] parameters. Other parameter types are not affected.

⚠️ Manual Verification Required

This CVE does not have specific version information in our database, so automatic vulnerability detection cannot determine if your system is affected.

Why? The CVE database entry doesn't specify which versions are vulnerable (no version ranges provided by the vendor/NVD).

🔒 Custom verification scripts are available for registered users. Sign up free to download automated test scripts.

Recommended Actions:
  1. Review the CVE details at NVD
  2. Check vendor security advisories for your specific version
  3. Test if the vulnerability is exploitable in your environment
  4. Consider updating to the latest version as a precaution

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete service unavailability due to memory exhaustion, requiring application restart and potentially affecting dependent services.

🟠

Likely Case

Degraded performance or temporary service disruption for affected endpoints, with automatic recovery after request processing fails.

🟢

If Mitigated

Minimal impact with proper request size limits and monitoring in place, potentially causing only individual request failures.

🌐 Internet-Facing: MEDIUM
🏢 Internal Only: LOW

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: UNKNOWN
Unauthenticated Exploit: ⚠️ Yes
Complexity: LOW

Exploitation requires sending HTTP requests to vulnerable endpoints. No authentication bypass is needed if endpoints are publicly accessible.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Spring Framework 6.1.19, 6.0.29, 5.3.34

Vendor Advisory: https://spring.io/security/cve-2024-38828

Restart Required: Yes

Instructions:

1. Update Spring Framework dependency to patched version. 2. Update Spring Boot if using Spring Boot Starter. 3. Rebuild and redeploy application. 4. Restart application server.

🔧 Temporary Workarounds

Request Size Limiting

all

Configure maximum request size limits in application server or Spring configuration

spring.servlet.multipart.max-file-size=10MB
spring.servlet.multipart.max-request-size=10MB

Web Application Firewall Rules

all

Implement WAF rules to block or limit large HTTP requests

🧯 If You Can't Patch

  • Implement rate limiting on affected endpoints
  • Deploy reverse proxy with request size limits before vulnerable application

🔍 How to Verify

Check if Vulnerable:

Check Spring Framework version in pom.xml or build.gradle. Review controller methods for @RequestBody byte[] parameters.

Check Version:

mvn dependency:tree | grep spring-core OR gradle dependencies | grep spring-core

Verify Fix Applied:

Verify Spring Framework version is 6.1.19+, 6.0.29+, or 5.3.34+. Test affected endpoints with large payloads.

📡 Detection & Monitoring

Log Indicators:

  • OutOfMemoryError in logs
  • Large request size warnings
  • Slow response times from affected endpoints

Network Indicators:

  • Unusually large HTTP POST requests to Spring MVC endpoints
  • Spike in memory usage correlated with requests

SIEM Query:

source="application.logs" AND ("OutOfMemoryError" OR "java.lang.OutOfMemoryError") AND "Spring"

🔗 References

📤 Share & Export