November 16, 2026
AI Agent Internal System Prompt and Tool Schema Disclosure
Severity: P4 Low Vulnerability Type: Sensitive Information Disclosure / AI System Prompt Leakage Bugcrowd VRT: Sensitive Data Exposure โโฆ

By Akash motkar
3 min read
Severity: P4 Low Vulnerability Type: Sensitive Information Disclosure / AI System Prompt Leakage Bugcrowd VRT: Sensitive Data Exposure โ Disclosure of Secrets OWASP: LLM07:2025 System Prompt Leakage CWE:
- CWE-200 Exposure of Sensitive Information to an Unauthorized Actor
- CWE-668 Exposure of Resource to Wrong Sphere
- CWE-213 Exposure of Sensitive Information Due to Incompatible Policies
CVSS v3.1: 5.3 (Medium, as assessed in the source report) CVE: Not applicable
1. Description
During security testing, an information disclosure vulnerability was identified in a WebSocket-based AI Agent application.
The application exposes a dedicated WebSocket event named system_prompt, which allows clients to request the AI Agent's internal system prompt using the get action.
The system prompt is intended to remain internal to the server-side AI infrastructure and contains instructions governing the assistant's behavior, available tools, business workflows, and security restrictions.
However, the application exposes this internal configuration through a client-accessible WebSocket event.
Following completion of the application's guest-access verification process, an external client can submit a system-prompt retrieval request and receive approximately 25,223 characters of internal AI configuration.
The disclosed information includes the AI Agent's complete internal tool catalogue, knowledge-base article identifiers, business logic, escalation workflows, and security guardrails.
Particularly concerning is that the disclosed system prompt explicitly instructs the AI Agent not to reveal its internal configuration or available tool names. Despite these restrictions, the dedicated WebSocket event directly returns the configuration from the server, bypassing the conversational restrictions imposed on the AI model.
This exposes internal implementation details that should not be accessible through a publicly available client-facing interface.
2. Affected Component
Component: AI Agent WebSocket Service
Protocol: WebSocket Secure (WSS)
Affected Functionality: Internal System Prompt Retrieval
WebSocket Event: system_prompt
Action: get
Authentication: No application account required; the application's guest-access verification flow must be satisfied.
3. Steps to Reproduce
Prerequisites
- Kali Linux or another Linux environment.
- Node.js and npm.
wscatWebSocket client.- Access to the affected WebSocket service.
Install the required utility:
sudo apt update
sudo apt install nodejs npm -y
sudo npm install -g wscatsudo apt update
sudo apt install nodejs npm -y
sudo npm install -g wscatStep 1 Establish a WebSocket connection
Connect to the affected WebSocket service using:
wscat -c "wss://<affected-host>/ws?<required-connection-parameters>"wscat -c "wss://<affected-host>/ws?<required-connection-parameters>"The server establishes a WebSocket connection and returns an initialization message containing connection information and a CAPTCHA site key.
Step 2 Complete the application's guest-access verification flow
Follow the application's guest-access verification process using an authorized test session.
The source assessment also documents a CAPTCHA verification bypass, but that is a separate weakness and is not treated as the standalone root cause of this finding.
Step 3 Request the internal system prompt
Submit the following WebSocket event:
{
"event": "system_prompt",
"action": "get"
}{
"event": "system_prompt",
"action": "get"
}Step 4 Observe the server response
The server returns a response containing the internal system prompt.
The returned content is approximately 25,223 characters long and contains internal AI-agent configuration.
Step 5 Examine the disclosed tool definitions
Review the returned system prompt for internal tool definitions.
The disclosed tool catalogue includes:
list_devices
get_device_capabilities
search_feed
get_location_mode
change_location_mode
escalate_to_live_agent
check_order_status
shopify_get_product_details
shopify_search_products
shopify_get_active_promotions
kb_find_kb_article
read_kb_articlelist_devices
get_device_capabilities
search_feed
get_location_mode
change_location_mode
escalate_to_live_agent
check_order_status
shopify_get_product_details
shopify_search_products
shopify_get_active_promotions
kb_find_kb_article
read_kb_articleStep 6 Identify additional internal information
Further inspection of the returned configuration reveals:
- Internal knowledge-base article identifiers.
- Customer-support workflows.
- Order lookup and refund-related logic.
- Escalation conditions.
- Internal AI-agent instructions.
- Security guardrails and operational restrictions.
This confirms that the WebSocket interface exposes internal AI-agent configuration to external clients.
4. Security Impact
The exposure of internal system prompts and tool schemas can provide attackers with valuable information about the application's internal AI architecture.
Potential security implications include:
1. Internal Configuration Disclosure
An external user can retrieve the AI Agent's internal instructions and configuration, which are not intended to be publicly accessible.
2. Internal Tool Architecture Exposure
The disclosed tool definitions reveal the available capabilities of the AI Agent, including device-related operations, video-feed search, customer-support escalation, and product-related functionality.
3. Business Logic Disclosure
The system prompt exposes internal customer-support workflows, knowledge-base identifiers, escalation conditions, and operational instructions.
4. Increased Risk of Targeted AI Attacks
Knowledge of internal instructions, tool names, and guardrails may assist attackers in developing more targeted prompt-injection and jailbreak testing scenarios.
5. Security Control Disclosure
The exposed guardrails provide insight into the restrictions and behavioral controls implemented within the AI Agent.
The disclosure itself does not establish that those controls can be bypassed.
Impact limitation: The assessment did not demonstrate unauthorized access to customer devices, camera feeds, recordings, or account information. These impacts are not claimed as confirmed.
5. Root Cause Analysis
The root cause is the exposure of an internal system-prompt retrieval operation through a client-accessible WebSocket interface.
The application allows clients to invoke the system_prompt event with the get action and receive internal configuration directly from the server.
System prompts and internal tool definitions should be treated as server-side configuration rather than publicly accessible application resources.
Additionally, the application does not adequately restrict access to this internal diagnostic functionality.
6. Remediation
- Remove the
system_promptretrieval event from the publicly accessible WebSocket protocol. - Keep internal system prompts exclusively within the server-side AI infrastructure.
- Restrict diagnostic functionality to authenticated and explicitly authorized administrative access.
- Enforce authorization checks on all privileged WebSocket events.
- Avoid embedding sensitive internal identifiers, operational details, or confidential business logic in client-accessible configuration.
- Review all WebSocket events for unintended disclosure of internal application data.
- Implement security testing to verify that unauthenticated and unauthorized users cannot retrieve internal configuration.
7. Classification
AttributeClassificationVulnerabilityAI Agent System Prompt DisclosureSeverityP4 LowBugcrowd VRTSensitive Data Exposure โ Disclosure of SecretsOWASPLLM07:2025 โ System Prompt LeakageCWECWE-200, CWE-668, CWE-213CVSS v3.15.3 โ MediumCategoryInformation Disclosure / AI SecurityAuthenticationNo application account requiredStatusConfirmed