Summary
TypeBot versions before 3.17.0 contain an information exposure vulnerability in the OpenAI model-listing helper. A low-privilege guest workspace member may supply an attacker-controlled endpoint and cause the server to send a stored OpenAI-compatible API key to that endpoint.
Affected context
The issue occurs in TypeBot workspaces where guests can read workspace membership data and invoke the OpenAI model-listing functionality. The vulnerable flow decrypts a selected workspace credential, places the secret in the OpenAI client configuration and request headers, and uses a caller-controlled baseUrl for the outbound request.
Exploit preconditions
- Attack surface: The OpenAI model-listing helper and its outbound HTTP request path
- Required access: Low-privilege guest membership in the affected workspace
- Trigger point: A model-listing request that supplies an attacker-controlled destination URL and references an accessible credential
- Why exploitation is possible: Permission checks allow readable workspace members to reach the helper, while credential identifiers are exposed and the server forwards the decrypted secret to the supplied endpoint
Why this happens
The vulnerability results from combining insufficient authorization with attacker-controlled outbound request routing. The application treats workspace readability as sufficient authorization to use a credential and then includes the decrypted secret in a request sent to a caller-supplied URL. This behavior maps to CWE-200: Exposure of Sensitive Information to an Unauthorized Actor, because a protected API key can be disclosed outside its intended trust boundary.
Potential impact
- An attacker may obtain stored OpenAI-compatible API keys
- Exposed credentials could allow unauthorized use of external AI services
- Organizations may incur unexpected provider charges
- Attackers could use the keys to access associated models or provider resources
- Credential exposure could enable further compromise of connected systems
General mitigation guidance
Mitigation generally focuses on enforcing credential-specific authorization and preventing secrets from being sent to destinations controlled by untrusted callers.
Common defensive patterns include:
- Restricting credential use to explicitly authorized roles and workspace capabilities
- Avoiding caller-controlled base URLs for requests that contain secrets
- Allowing outbound requests only to approved provider domains or configured endpoints
- Keeping credential identifiers and secret-bearing operations inaccessible to guest members
- Redacting API keys from logs, responses, errors, and client-visible metadata
- Applying least privilege, short-lived credentials, and provider-side key scoping where supported
- Rotating potentially exposed credentials and reviewing their usage through provider audit records
How teams detect issues like this
Organizations can look for this class of issue through:
- Static analysis rules that flag secrets placed in requests whose destinations derive from user input
- Code review checks for authorization decisions based only on workspace visibility or membership
- Tests verifying that guest users cannot enumerate or invoke secret-bearing credential operations
- Egress policies restricting service requests to approved provider domains
- Monitoring for unusual API-key usage, unexpected destination hosts, and anomalous model-listing traffic
- Automated security review tools that identify credential flows crossing untrusted trust boundaries

