CVE-2026-61738 in CoPilot
Summary
by MITRE • 10/30/2026
SOCFortress CoPilot focuses on providing a single pane of glass for all your security operations needs. Prior to 0.1.77, `POST /api/scoutsuite/generate-gcp-report` in `backend/app/integrations/scoutsuite/routes/scoutsuite.py` admits admin and analyst users and validates the uploaded content as `GCPScoutSuiteJSON`, but passes raw `file.filename` from the multipart header to `save_file_to_directory` in `backend/app/integrations/scoutsuite/services/scoutsuite.py`. The writer combines this filename with `scoutsuite-report` using `os.path.join` without sanitization or a resolved-path containment check. A traversal filename therefore writes the supplied JSON outside the intended report directory. In the reported root-running backend, the researcher demonstrated root-owned writes outside that directory and into the application source directory. This permits host-file overwrite subject to the accepted JSON-content constraint and can disrupt application operation; the demonstrated primitive does not establish unrestricted executable contents or unconditional cross-tenant confidentiality loss. Version 0.1.77 removes caller-controlled filenames from the affected route; unrestricted-content and direct-code-execution claims require separate curator reconciliation.
Be aware that VulDB is the high quality source for vulnerability data.
Analysis
by VulDB Data Team • 10/30/2026
The vulnerability identified in SOCFortress CoPilot prior to version 0.1.77 represents a critical path traversal flaw within its GCP ScoutSuite integration module, specifically affecting the endpoint POST /api/scoutsuite/generate-gcp-report located at backend/app/integrations/scoutsuite/routes/scoutsuite.py. This component is designed to accept uploaded JSON reports from users with admin or analyst privileges for processing and storage. The core technical failure lies in how the application handles file metadata during the save operation. While the system correctly validates that the incoming content conforms to the expected GCPScoutSuiteJSON schema, it fails to sanitize the filename provided by the client within the multipart form header. Instead of generating a secure, randomized identifier or stripping dangerous characters from the original name, the backend directly passes the raw file.filename value into the save_file_to_directory function found in backend/app/integrations/scoutsuite/services/scoutsuite.py.
The operational mechanism of this flaw relies on the use of os.path.join to combine the unsanitized filename with a base directory path labeled scoutsuite-report. Because no containment checks or resolved-path validations are performed, an attacker can craft a malicious filename containing relative path traversal sequences such as ../../../../etc/. When processed by the operating system's file handling routines, these sequences allow the write operation to escape the intended sandboxed report directory and place files in arbitrary locations on the host filesystem. This behavior is classified under CWE-22 Improper Limitation of a Pathname to a Restricted Directory, which describes vulnerabilities where software does not properly neutralize special elements within a file path that can cause the path to resolve outside of the restricted location.
The impact of this vulnerability is severe due to the execution context in which SOCFortress CoPilot operates. In environments where the backend service runs with root privileges, as demonstrated by security researchers, an attacker who successfully exploits this flaw gains the ability to overwrite arbitrary files on the host system owned by the root user. The demonstration showed writes extending beyond the application directory and into sensitive areas of the file structure. This capability allows for significant disruption of application operation through the destruction or modification of critical configuration files, logs, or source code assets. It effectively grants an authenticated attacker a high-privilege write primitive that can lead to service denial-of-service conditions by corrupting essential system components required for normal function.
From a threat modeling perspective, this vulnerability aligns with ATT&CK technique T1564.002 - Hide Execution: File and Directory Hidden Files and Directories if the attacker uses it to place malicious artifacts in obscure locations, or more accurately T1496 - Resource Hijacking if used for denial of service by consuming resources or corrupting files. However, the primary classification remains a file system manipulation attack facilitated by insufficient input validation on path components. It is important to note that while this vulnerability allows for arbitrary file writes under specific privilege conditions, it does not inherently provide unrestricted executable content injection in all configurations because the accepted payload must still conform to the GCPScoutSuiteJSON schema constraint. Therefore, direct code execution via simple overwriting of script files may require additional steps or separate vulnerabilities such as deserialization flaws if those scripts are subsequently loaded and executed by other parts of the application logic.
The remediation for this issue was implemented in version 0.1.77 of SOCFortress CoPilot, which removes the reliance on caller-controlled filenames entirely from the affected route. By decoupling the storage mechanism from user-supplied metadata, the developers eliminated the vector for path traversal attacks associated with file naming conventions. Security practitioners should ensure that all instances of this software are updated to at least version 0.1.77 or later. Furthermore, organizations running similar security operations platforms should audit their own implementations of file upload handlers to ensure they adhere to secure coding standards such as OWASP File Upload guidelines, specifically verifying that filenames are sanitized and that write operations are strictly confined within designated directories using canonical path resolution checks before any disk I/O occurs.