Code RoomSecrets in AI chat disclosure
MediumPrep Room Coding #4167

Secrets in AI chat disclosure

Vibe & agenticSecurityMid–Senior~16 min

A teammate is debugging a flaky payment webhook and pastes the full failing request body into a chat-based AI assistant to ask why signature verification fails. The body includes a live Stripe webhook secret prefix, a customer's email, and the last4 of a card. The assistant gives a useful answer, so the teammate adds it to the team's shared 'prompt cookbook' so others can do the same. What's wrong here, and what concrete workflow would you put in its place?

Implement
find_disclosure_blockers(prompt_lines: list[str]) → list[str]
Examples
in[["POST /webhooks/stripe","whsec_9f2a1c04ab payload signature mismatch","customer jane.doe@example.com last4=4242"]]out["card_data","customer_email","live_secret"]
in[["POST /webhooks/stripe","sk_test_123 redacted_secret","customer REDACTED_EMAIL last4=XXXX","signature verification fails"]]out[]
in[["Authorization: Bearer abc123","and nothing else"]]out["auth_header"]
What a strong answer looks like

Treat the AI’s output as a draft to verify, not an answer to trust. Name the specific flaw and the input that triggers it, say how you’d catch it (tests, edge cases, reading critically), and how you’d re-prompt or decompose to get it right.

0:00 of about 16 min

Vibe & agentic: describe the solution in plain language (or narrate it) and the coach grades your approach.

Which questions mattered is sealed until you submit. Telling you now would just be handing over the edge cases.