CVE-2021-4164: calibre-web is vulnerable to Cross-Site Request Forgery (CSRF)
7.6
CVSS Score
3.0
Basic Information
CVE ID
GHSA ID
EPSS Score
0.33127%
CWE
Published
1/21/2022
Updated
2/3/2023
KEV Status
No
Technology
Python
Technical Details
CVSS Vector
CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:H
| Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
|---|---|---|---|
| calibreweb | pip | < 0.6.15 | 0.6.15 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stems from state-changing operations accepting GET requests without CSRF protection. The patch migrates these routes to POST and adds CSRF token checks. Key indicators include: 1) Route decorators changed from @route('/path') to @route('/path', methods=['POST']), 2) JavaScript AJAX calls updated from GET to POST, 3) Form CSRF tokens added in templates. Functions handling destructive operations (deletion(), shutdown(), sync()) via GET in vulnerable versions are clear CSRF targets.