CVE-2023-49382
📋 TL;DR
JFinalCMS v5.0.0 contains a CSRF vulnerability in the custom table deletion endpoint (/admin/div/delete). This allows attackers to trick authenticated administrators into performing unauthorized deletions of custom table data. Users running JFinalCMS v5.0.0 are affected.
💻 Affected Systems
- JFinalCMS
📦 What is this software?
Jfinalcms by Jfinalcms Project
⚠️ Risk & Real-World Impact
Worst Case
Attackers could delete critical custom table data, causing data loss and disrupting CMS functionality.
Likely Case
Attackers trick administrators into deleting custom table content, leading to data loss and potential service disruption.
If Mitigated
With proper CSRF protections, unauthorized deletions are prevented even if administrators are tricked into visiting malicious pages.
🎯 Exploit Status
CSRF attacks are well-understood and easy to implement. Requires the victim to be authenticated as an administrator.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: Unknown
Vendor Advisory: No official vendor advisory found
Restart Required: No
Instructions:
No official patch available. Implement CSRF tokens on the /admin/div/delete endpoint. Review and update JFinalCMS to a patched version if released.
🔧 Temporary Workarounds
Implement CSRF Protection
allAdd CSRF tokens to the custom table deletion form and validate them server-side.
Modify JFinalCMS source code to include CSRF tokens in forms and validate them in controllers
Use SameSite Cookies
allSet SameSite=Strict or SameSite=Lax on session cookies to prevent CSRF attacks.
Configure web server or application to set SameSite attribute on cookies
🧯 If You Can't Patch
- Implement WAF rules to detect and block CSRF attempts to /admin/div/delete
- Restrict admin panel access to trusted IP addresses only
🔍 How to Verify
Check if Vulnerable:
Check if /admin/div/delete endpoint lacks CSRF token validation. Test by creating a malicious form that submits to this endpoint without proper tokens.
Check Version:
Check JFinalCMS version in admin panel or configuration files
Verify Fix Applied:
Verify that CSRF tokens are required and validated for /admin/div/delete requests. Test that requests without valid tokens are rejected.
📡 Detection & Monitoring
Log Indicators:
- Multiple DELETE requests to /admin/div/delete from same session without corresponding form submissions
- Failed CSRF token validation attempts
Network Indicators:
- HTTP POST requests to /admin/div/delete without Referer header or with external Referer
SIEM Query:
source="web_logs" AND uri="/admin/div/delete" AND (csrf_token="" OR referer="*")