CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



GHSA-V2F8-6655-7GRJ

GHSA-v2f8-6655-7grj: Remote Code Execution and Authentication Bypass in vibe-trading-ai

Amit Schendel
Amit Schendel
Senior Security Researcher

Oct 3, 2026·6 min read·15 visits

Executive Summary (TL;DR)

A critical vulnerability chain in vibe-trading-ai allows unauthenticated remote attackers to execute arbitrary shell commands as root within Docker containers, access historical operational logs, and upload malicious files because of a fail-open authorization design.

The vibe-trading-ai package prior to version 0.1.7 contains multiple critical security vulnerabilities including unauthenticated remote code execution (RCE) via session message injection, missing authentication on read endpoints, unrestricted file upload, insecure CORS policies, and sensitive key disclosure. Because the application default settings failed open, ran as root within Docker, and bound to all interfaces, remote unauthenticated attackers could compromise host environments containing sensitive trading data.

Vulnerability Overview

The vibe-trading-ai software is an automated cryptocurrency and financial trading framework designed to integrate artificial intelligence agent loops into real-time trading environments. The platform relies on a backend API server built on FastAPI to process strategy commands, configure active LLMs, and track backtesting execution. This backend exposes an API surface on port 8899 that interfaces with both the local user interface and background task executors.

In versions prior to 0.1.7, the default deployment architecture exposed a highly vulnerable attack surface. The software configured a fail-open security mechanism where authorization was bypassed if an environment secret was omitted. Furthermore, the default configuration files mapped the API port to all network interfaces (0.0.0.0) without restricting external traffic.

The resulting vulnerability footprint allows unauthenticated attackers to systematically exploit the application. Attackers can execute arbitrary terminal operations, retrieve historical trading databases, and overwrite core application modules. This occurs due to the execution of the agent container as root, combined with the lack of access controls on critical endpoints.

Root Cause Analysis

The primary root cause resides within the authentication dependency implemented in agent/api_server.py. The function require_auth() was designed to inspect incoming HTTP requests for credentials. However, it evaluated the presence of the system-wide secret key before performing validation. If the API_AUTH_KEY environment variable was empty or commented out in the configuration files, the function returned None instead of raising an HTTP exception.

Because the distributed .env.example file contained a commented-out authorization key, most standard installations defaulted to an unauthenticated mode. This fail-open logic meant that any client could access routes decorated with authentication dependencies. Simultaneously, the development team implemented read endpoints (GET routes) without adding authorization controls, allowing unauthorized data access even when write operations were secured.

The ultimate mechanism for arbitrary code execution relies on the application's design as an autonomous agent. The framework exposes a BashTool within the agent loop to execute operating system commands. This tool executes raw strings using python's subprocess.run(shell=True). By sending a natural language prompt instructing the agent to run a shell command, an unauthenticated network observer can execute commands inside the host environment.

Code Analysis and Patch Review

A technical evaluation of the differences between the vulnerable code and the official patch in commit 9454d4a27a763b80e1d6eb5763b86c88e9e4e714 reveals a multi-layered security hardening strategy. The vulnerability in agent/api_server.py was remediated by rewriting the authentication verification logic to reject connections when the API key is not configured.

# Vulnerable authentication implementation (pre-0.1.7)
def require_auth(cred: HTTPAuthorizationCredentials = Security(_security)):
    api_key = _configured_api_key()
    if not api_key:
        return  # Fail-open: returns None and allows access if unset
    if not cred or cred.credentials != api_key:
        raise HTTPException(status_code=401, detail="Invalid or missing API key")
# Patched authentication implementation (0.1.7)
def _validate_api_auth(
    *,
    request: Request,
    cred: Optional[HTTPAuthorizationCredentials],
    query_api_key: Optional[str] = None,
    allow_query: bool = False,
) -> None:
    api_key = _configured_api_key()
    if not api_key:
        if _is_local_client(request):
            return  # Permits local loopback development only
        raise HTTPException(
            status_code=status.HTTP_403_FORBIDDEN,
            detail="API_AUTH_KEY is required for non-local API access",
        )
 
    token = _auth_credential_from_header_or_query(cred, query_api_key, allow_query=allow_query)
    if not token or not hmac.compare_digest(token, api_key):
        raise HTTPException(status_code=401, detail="Invalid or missing API key")

Additionally, the developers implemented an Abstract Syntax Tree (AST) validation checker inside agent/backtest/runner.py via _validate_signal_engine_source. This mechanism parses Python files prior to import to confirm they do not contain top-level execution statements. This mitigates the risk of running unauthorized actions through backtesting modules. Finally, the Dockerfile was updated to run under a non-root system user named vibe instead of defaulting to root root permissions.

Exploitation Methodology

To execute commands on a vulnerable instance, an attacker must first locate an exposed endpoint on port 8899. Because of the open port binding configuration, this can be achieved using a standard network scanner. Once a host is identified, the attacker initiates a stateful session and triggers the execution chain through the agent's interactive interfaces.

First, the attacker creates an active session using the /sessions route:

curl -s -X POST http://<target>:8899/sessions \
  -H 'Content-Type: application/json' \
  -d '{}'

The server responds with a JSON payload containing a unique session identifier (session_id). The attacker uses this identifier to send a malicious instructions object to the agent loop via the message endpoint. The instructions request that the agent process a command using the system terminal:

curl -s -X POST "http://<target>:8899/sessions/<session_id>/messages" \
  -H 'Content-Type: application/json' \
  -d '{"content":"Please use the shell execution tool to run the command: id && cat /etc/passwd"}'

Because the agent executes inside a Docker container configured without a designated USER field, the payload runs with root administrative rights. The attacker can then request the resulting terminal output by querying the messages log endpoint GET /sessions/<session_id>/messages after a brief processing interval.

Impact Assessment

The impact of this vulnerability is critical. Successful exploitation gives an unauthenticated remote attacker complete administrative control over the host running the application. Attackers can execute commands, steal credentials, and compromise downstream services connected to the container.

Since the software is used for algorithmic trading, the target container typically stores high-value assets. These assets include API secret keys for exchanges, active private keys for web3 wallets, and database records containing historical transaction records. Access to these resources allows attackers to steal funds or disrupt automated trading systems.

The vulnerability also exposes host networks to further compromise. Attackers can leverage the compromised container as a pivot point to map, scan, and attack other systems within the private internal network. The high risk is reflected in the perfect CVSS base score of 10.0.

Remediation and Defense-in-Depth

Securing a deployment requires updating the installation packages and hardening network configurations. Users should upgrade the application package to version 0.1.7 or later to implement the authentication and filesystem controls. This can be accomplished through standard pip upgrade processes.

pip install --upgrade vibe-trading-ai

In addition to the software upgrade, developers must modify deployment configurations. The docker-compose.yml file should be updated to restrict access to port 8899. Binding the port explicitly to the local loopback address (127.0.0.1:8899:8899) prevents external systems from communicating with the API endpoint.

Finally, users must configure a strong API key in the environment variables. Setting the API_AUTH_KEY variable with a high-entropy secret ensures the API validates authorization headers for all external requests. If shell execution features are not required, administrators should disable them by setting VIBE_TRADING_ENABLE_SHELL_TOOLS=0 in the environment configuration.

Fix Analysis (1)

Technical Appendix

CVSS Score
10.0/ 10
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H

Affected Systems

vibe-trading-ai pip package deploymentsHKUDS Vibe-Trading local and container installations

Affected Versions Detail

Product
Affected Versions
Fixed Version
vibe-trading-ai
HKUDS
>= 0.1.0, < 0.1.70.1.7
AttributeDetail
CWE IDCWE-306, CWE-862, CWE-434, CWE-346, CWE-200
Attack VectorNetwork (Unauthenticated API Request)
CVSS v3.1 Score10.0 (Critical)
ImpactRemote Code Execution (RCE) / Full System Compromise
Exploit StatusProof of Concept (PoC) documented in research
Docker Default Userroot (pre-0.1.7)

MITRE ATT&CK Mapping

T1190Exploit Public-Facing Application
Initial Access
T1505.003Server Software Component: Web Shell
Persistence
T1059Command and Scripting Interpreter
Execution
CWE-306
Missing Authentication for Critical Function

The application fails to authenticate critical pathways when specific environment secrets are not configured, and fails to authenticate read endpoints entirely, leading to exposure of administrative interfaces and unauthenticated command execution via integrated agent scripts.

Vulnerability Timeline

Vulnerability identified in API authorization structure and default Docker configuration profiles.
2025-01-20
Mitigation commit 9454d4a27a763b80e1d6eb5763b86c88e9e4e714 checked in to repository.
2025-01-22
Official release of version 0.1.7 containing full remediation patches.
2025-01-22
GitHub Security Advisory published detailing the vulnerability chain.
2025-01-23

References & Sources

  • [1]Vibe-Trading Source Code Repository
  • [2]GitHub Security Advisory GHSA-v2f8-6655-7grj
  • [3]Vibe-Trading Release v0.1.7 Changes

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•1 day ago•CVE-2026-107844
5.3

CVE-2026-107844: Path Traversal Vulnerability in Contao ImagesController

A path traversal vulnerability (CWE-22) in Contao CMS allows unauthenticated remote attackers to bypass directory boundary restrictions in ImagesController and access files within the project directory.

Amit Schendel
Amit Schendel
8 views•5 min read
•1 day ago•CVE-2026-107848
3.5

CVE-2026-107848: Cross-Site Request Forgery (CSRF) in Contao Backend Actions via GET Requests

Contao Open Source CMS versions 4.0.0 through 5.3.49 and 5.4.0-RC1 through 5.7.11 contain a Cross-Site Request Forgery (CSRF) vulnerability in backend parameter handling. The `RequestTokenListener` component validates anti-CSRF tokens solely for HTTP POST requests, while GET-based declarative guards run only when an `act` parameter is present in the query string. Consequently, custom backend actions dispatched via alternative parameters such as `key=` can execute without CSRF token verification when triggered by an authenticated user.

Amit Schendel
Amit Schendel
7 views•5 min read
•1 day ago•CVE-2026-107843
5.3

CVE-2026-107843: Unthrottled Activation Email Resend and Account Enumeration in Contao CMS

Contao CMS versions 4.1.0 through 5.3.49 and 5.4.0-RC1 through 5.7.11 fail to validate form submission tokens and enforce rate limiting when processing activation email resend requests via HTTP POST, enabling resource exhaustion and account state enumeration.

Amit Schendel
Amit Schendel
8 views•4 min read
•1 day ago•CVE-2026-107842
5.3

CVE-2026-107842: Information Disclosure via Stale Indexing in Contao Search Module

An information disclosure vulnerability in Contao CMS allows unauthenticated site visitors to view protected page titles, URLs, and text excerpts through search queries when protected page indexing is disabled after previously being enabled.

Amit Schendel
Amit Schendel
10 views•4 min read
•1 day ago•GHSA-G38J-7V97-X298
6.5

GHSA-G38J-7V97-X298: Missing Authorization Check in Vikunja CalDAV Task Relation Creation

In Vikunja prior to version 2.6.0, relation creation via the CalDAV endpoint fails to invoke the TaskRelation.CanCreate authorization check. This missing access control allows an authenticated user to establish unauthorized relationships and perform write operations against any task, provided its unique identifier (UID) is known.

Alon Barad
Alon Barad
12 views•5 min read
•1 day ago•GHSA-3HC7-R24J-RPWC
6.8

GHSA-3hc7-r24j-rpwc: Cross-Project Task Disclosure via Subtask Expansion in Vikunja

A cross-project information disclosure vulnerability in Vikunja allows authenticated users with read access to one project to view private task details from unauthorized projects via subtask expansion parameters.

Alon Barad
Alon Barad
9 views•5 min read