CVE-2024-37902

10.0 CRITICAL

📋 TL;DR

This vulnerability in DeepJavaLibrary (DJL) allows attackers to overwrite system files by exploiting improper path validation when extracting archived artifacts. Attackers can insert malicious files with absolute paths that overwrite critical system files. All users running DJL versions 0.1.0 through 0.27.0 are affected.

💻 Affected Systems

Products:
  • DeepJavaLibrary (DJL)
Versions: 0.1.0 through 0.27.0
Operating Systems: All operating systems running Java
Default Config Vulnerable: ⚠️ Yes
Notes: Vulnerability exists in the archive extraction functionality when processing untrusted archives.

⚠️ 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 system compromise through arbitrary file overwrite, potentially leading to remote code execution, data destruction, or persistent backdoor installation.

🟠

Likely Case

Local file overwrite leading to privilege escalation, service disruption, or data corruption.

🟢

If Mitigated

Limited impact if proper file permissions and sandboxing prevent writing to critical system locations.

🌐 Internet-Facing: MEDIUM - Requires user interaction or specific conditions to trigger archive extraction from untrusted sources.
🏢 Internal Only: MEDIUM - Internal users with access to upload archives could exploit this for privilege escalation.

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: UNKNOWN
Unauthenticated Exploit: ✅ No
Complexity: LOW

Exploitation requires the ability to provide a malicious archive file to the vulnerable DJL application.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 0.28.0

Vendor Advisory: https://github.com/deepjavalibrary/djl/security/advisories/GHSA-w877-jfw7-46rj

Restart Required: Yes

Instructions:

1. Update DJL to version 0.28.0 or later. 2. For DJL Large Model Inference containers, update to version 0.27.0 or later. 3. Restart all applications using DJL.

🔧 Temporary Workarounds

Restrict archive sources

all

Only allow archive extraction from trusted, validated sources

Run with limited permissions

all

Run DJL applications with minimal file system write permissions

🧯 If You Can't Patch

  • Implement strict input validation for archive files before processing
  • Run DJL in a container or sandbox with restricted file system access

🔍 How to Verify

Check if Vulnerable:

Check DJL version in your application dependencies or build configuration

Check Version:

Check your build.gradle, pom.xml, or dependency manifest for DJL version

Verify Fix Applied:

Confirm DJL version is 0.28.0 or later, or for containers, version 0.27.0 or later

📡 Detection & Monitoring

Log Indicators:

  • Unexpected file write operations to system directories
  • Archive extraction errors or warnings

Network Indicators:

  • Downloads of archive files from untrusted sources to DJL applications

SIEM Query:

File creation events in system directories from DJL processes

🔗 References

📤 Share & Export