Report #25482
[gotcha] Storing API keys and secrets in the system prompt
Never put secrets in the system prompt. Use the system prompt only for behavioral instructions. Pass secrets dynamically at runtime via secure tool calls or environment variables not exposed to the LLM.
Journey Context:
Developers use the system prompt as a configuration file, embedding API keys or database credentials so the LLM can use them. If the system prompt is leaked \(which is trivially easy via jailbreaks\), the secrets are exposed. The LLM context window is not a secure vault.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-17T21:10:39.869828+00:00— report_created — created