Summary
Verba RAG 2.1.3 exposes an unauthenticated server-side request forgery flaw in its WebSocket-based import feature, enabling arbitrary HTTP GETs from the backend.
By supplying attacker-controlled URLs to the HTMLReader via the /ws/import_files endpoint, an attacker can coerce the server into requesting internal services and metadata, risking credential exposure.
Affected context
This vulnerability occurs in Verba RAG deployments that expose the /ws/import_files WebSocket endpoint without strict authentication or URL validation.
It is most relevant where the backend:
- Can reach internal HTTP services (e.g., databases, admin APIs)
- Has network access to cloud instance metadata endpoints
- Uses the HTMLReader configuration to fetch remote content based on user-supplied URLs
Exploit preconditions
- Attack surface: Publicly accessible
/ws/import_filesWebSocket endpoint - Required access: Network access to the Verba RAG application (no authentication required)
- Trigger point: Sending a WebSocket message that configures HTMLReader with attacker-controlled URLs
- Why exploitation is possible: The backend trusts and forwards user-supplied URLs directly to the HTTP client without sufficient validation or segmentation, allowing indirect access to internal network resources
Why this happens
The underlying bug stems from treating user-supplied URLs as fully trusted targets for server-side HTTP requests within the HTMLReader configuration.
This maps to CWE-918: Server-Side Request Forgery (SSRF), where an attacker leverages a server's network position to reach resources that would otherwise be inaccessible from the outside.
In abstract terms, any backend component that performs outbound requests based on unvalidated, unauthenticated input and shares a network with sensitive services can become an SSRF primitive.
Potential impact
- Access to internal HTTP-based services that are not exposed publicly
- Retrieval of cloud instance metadata, including access tokens or keys
- Exposure of database endpoints, configuration APIs, or debug interfaces
- Use of recovered credentials to pivot into other infrastructure components
- Potential escalation from data exposure to full environment compromise, depending on available internal targets
General mitigation guidance
Effective mitigation focuses on breaking the trust chain between user input and server-initiated network calls.
Common defensive patterns include:
- Restricting outbound requests to an allowlist of known-safe domains or hosts
- Blocking requests to private, link-local, and metadata IP ranges at the application and network layer
- Enforcing authentication and authorization on endpoints that trigger server-side fetches
- Normalizing and validating URLs before use, rejecting opaque or suspicious targets
- Segregating services so that components that process external URLs do not share direct network access with sensitive internal systems
How teams detect issues like this
SSRF risks can be identified through:
- Static analysis rules that flag direct use of user-supplied URLs in HTTP client calls
- Code review focusing on WebSocket handlers, import mechanisms, and any components that perform outbound requests
- Logging and monitoring of unusual outbound HTTP patterns, including requests to cloud metadata IPs or internal ranges
- Policy-based controls that enforce outbound network restrictions for services handling untrusted input
- Periodic security testing, such as penetration tests, that explicitly probe for SSRF behavior in import and integration features

