Skip to main content

CVE-2022-40690: Cross-site scripting in BookStack BookStack

Medium
VulnerabilityCVE-2022-40690cvecve-2022-40690
Published: Mon Oct 24 2022 (10/24/2022, 00:00:00 UTC)
Source: CVE
Vendor/Project: BookStack
Product: BookStack

Description

Cross-site scripting vulnerability in BookStack versions prior to v22.09 allows a remote authenticated attacker to inject an arbitrary script.

AI-Powered Analysis

AILast updated: 07/05/2025, 13:54:36 UTC

Technical Analysis

CVE-2022-40690 is a cross-site scripting (XSS) vulnerability identified in BookStack, an open-source platform designed for creating documentation and wikis. This vulnerability affects all versions of BookStack prior to v22.09. The flaw allows a remote attacker with authenticated access to inject arbitrary scripts into the application. Specifically, the vulnerability is classified under CWE-79, indicating improper neutralization of input during web page generation. Exploitation requires the attacker to have valid user credentials (authenticated access) and involves user interaction, such as a victim clicking a crafted link or viewing malicious content within the application. The CVSS v3.1 base score is 5.4 (medium severity), with vector AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N, indicating network attack vector, low attack complexity, privileges required, user interaction required, scope changed, and low impact on confidentiality and integrity, with no impact on availability. The vulnerability can lead to the execution of malicious scripts in the context of the victim's browser session, potentially resulting in session hijacking, unauthorized actions, or data theft within the BookStack environment. No known exploits in the wild have been reported as of the published date. The vulnerability was publicly disclosed on October 24, 2022, and affects versions prior to v22.09, for which patches or updates should be applied to remediate the issue.

Potential Impact

For European organizations using BookStack for internal documentation, knowledge management, or collaborative content creation, this vulnerability poses a moderate risk. Successful exploitation could allow attackers to execute malicious scripts in the context of legitimate users, potentially leading to unauthorized access to sensitive documentation, session hijacking, or manipulation of stored content. Given that BookStack is often used for internal knowledge bases, exposure of confidential business information or intellectual property is a concern. The requirement for authenticated access limits the attack surface to insiders or compromised accounts, but the risk remains significant in environments with weak access controls or where user credentials may be phished or leaked. Additionally, the scope change in the CVSS vector suggests that exploitation could affect resources beyond the vulnerable component, increasing potential impact. The absence of known exploits in the wild reduces immediate urgency but does not eliminate the risk, especially as attackers may develop exploits over time. European organizations with regulatory obligations under GDPR must consider the confidentiality impact, as unauthorized data exposure could lead to compliance violations and reputational damage.

Mitigation Recommendations

1. Immediate upgrade: Organizations should upgrade BookStack installations to version 22.09 or later, where the vulnerability is fixed. 2. Access control review: Enforce strong authentication mechanisms, including multi-factor authentication (MFA), to reduce the risk of credential compromise. 3. Input validation and sanitization: Although this is primarily a vendor-side fix, administrators should verify that any custom plugins or integrations also properly sanitize user input. 4. User awareness: Train users to recognize phishing attempts and suspicious links that could trigger XSS attacks. 5. Session management: Implement strict session timeout policies and monitor for unusual session activity to detect potential hijacking. 6. Network segmentation: Limit access to BookStack instances to trusted internal networks or VPNs to reduce exposure. 7. Monitoring and logging: Enable detailed logging of user actions and monitor for anomalous behavior indicative of exploitation attempts. 8. Incident response planning: Prepare procedures to respond to potential XSS exploitation, including forensic analysis and user notification.

Need more detailed analysis?Get Pro

Technical Details

Data Version
5.1
Assigner Short Name
jpcert
Date Reserved
2022-09-26T00:00:00.000Z
Cisa Enriched
true
Cvss Version
3.1
State
PUBLISHED

Threat ID: 682d981bc4522896dcbd9894

Added to database: 5/21/2025, 9:08:43 AM

Last enriched: 7/5/2025, 1:54:36 PM

Last updated: 7/26/2025, 9:27:41 AM

Views: 11

Actions

PRO

Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.

Please log in to the Console to use AI analysis features.

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats