stuntman / providers / secrets

Secrets

An Azure Key Vault with synthetic secrets, keys that really sign, certificates and a log of every read.

Stands in for

  • Azure Key Vault
  • Managed identity (IMDS)
  • App Service identity endpoint

Everything Secrets gives you

  1. 01

    Secrets with versions

    Synthetic values with versions, expiry, content type and tags. A new version sends SecretNewVersionCreated to subscribers.

  2. 02

    Keys that really sign

    RSA 2048, 3072 or 4096 keys that sign, verify, wrap and unwrap, so the app's crypto code runs for real.

  3. 03

    Certificates from a Test CA

    Issue, import (.pfx or PEM) and renew certificates; each shows subject, issuer, validity and days left.

  4. 04

    Who reads what

    Reads per process and per identity. A secret read on every request shows up at once: the app is not caching it.

  5. 05

    An access log

    Every operation with identity, item and answer, kept 24 h, and vault_patterns lists what looks wrong.

  6. 06

    Managed identity

    The IMDS token endpoint hands tokens to identities with roles and name scopes, like Key Vault RBAC.

  7. 07

    What a real vault refuses

    With any_token on, would_fail lists the operations a real vault would have refused for that identity.

  8. 08

    Soft delete and recover

    Deleted items stay soft-deleted: recreating the name gets 409 until recover_item.

  9. 09

    Find every reference

    secret_used_by lists the environment files that point at secret://<name>, even before the secret exists.

The screens

Each number is a control or a reading on the real screen. Everything you can click there, your agent can do with a tool.

Secrets, versions and readers

Secrets, versions and readers: the Secrets screen in Stuntman
1Read 2,140 times

Reads in the last hour per secret; a big number means the app reads it on every request.

1 of 5
2Versions

Current, disabled or expired versions, each with its own read count.

2 of 5
3Who reads it

Each process and identity, and whether it looks cached.

3 of 5
4Next reads

Make the next reads fail: 403, 404, disabled, 429 or slow.

4 of 5
5Rotate

A new version and SecretNewVersionCreated to subscribers.

5 of 5
  1. Read 2,140 times

    Reads in the last hour per secret; a big number means the app reads it on every request.

  2. Versions

    Current, disabled or expired versions, each with its own read count.

  3. Who reads it

    Each process and identity, and whether it looks cached.

  4. Next reads

    Make the next reads fail: 403, 404, disabled, 429 or slow.

  5. Rotate

    A new version and SecretNewVersionCreated to subscribers.

The access log

The access log: the Secrets screen in Stuntman
1Worth a look

A pattern found in the log: a secret read on every request, which a real vault would throttle.

1 of 5
2Refused

403 for an identity without the role for this item.

2 of 5
3Unknown caller

A request with no known identity gets 401, and is listed.

3 of 5
4The caller

Identity, object id and role of the token that made the call.

4 of 5
5Pattern

Same secret, same process, 2 ms apart: the app has no cache.

5 of 5
  1. Worth a look

    A pattern found in the log: a secret read on every request, which a real vault would throttle.

  2. Refused

    403 for an identity without the role for this item.

  3. Unknown caller

    A request with no known identity gets 401, and is listed.

  4. The caller

    Identity, object id and role of the token that made the call.

  5. Pattern

    Same secret, same process, 2 ms apart: the app has no cache.

Keys that really sign

Keys that really sign: the Secrets screen in Stuntman
1Operations

Sign, verify, wrap and unwrap in the last hour, with p95.

1 of 5
2Real crypto

Signatures verify with the public key; wrapped keys unwrap again.

2 of 5
3Next operations

Disabled, 403, 429, slow, or a wrong signature that fails verify.

3 of 5
4Versions

Rotation adds a version; signatures from the older one still verify.

4 of 5
5Public key

As JWK or PEM, to verify outside the app.

5 of 5
  1. Operations

    Sign, verify, wrap and unwrap in the last hour, with p95.

  2. Real crypto

    Signatures verify with the public key; wrapped keys unwrap again.

  3. Next operations

    Disabled, 403, 429, slow, or a wrong signature that fails verify.

  4. Versions

    Rotation adds a version; signatures from the older one still verify.

  5. Public key

    As JWK or PEM, to verify outside the app.

Break it on purpose

The failures you need to test, exactly when you ask: from the screen or by a tool call, each one shown on the timeline with who caused it.

  • Secret refused

    Next reads answer 403 or 404

    provoke_secret 403 | 404
  • Secret disabled

    Reads answer as for a disabled secret

    provoke_secret disabled or set_secret_state
  • Throttled

    Reads answer 429

    provoke_secret 429
  • Slow vault

    Reads take 3 s

    provoke_secret slow
  • Wrong signature

    sign returns a signature that fails verify

    provoke_key wrong_signature
  • Key disabled

    Key operations fail

    provoke_key disabled
  • Certificate expired

    Expired, not yet valid, missing or untrusted

    provoke_certificate
  • Wrong .pfx password

    The certificate's .pfx does not open

    provoke_certificate wrong_password
  • IMDS fails

    The token endpoint answers 500, slow or no identity

    provoke_imds
  • Soft-deleted name

    Recreating a deleted secret gets 409

    delete_secret

Why not the real sandbox

Your AI agent drives it

Claude Code, Codex or any MCP client connects to /mcp (or calls /api over plain HTTP), sets the stand-in up, breaks it on cue and reads what your app did.

you

Find out whether the app caches the HMAC signing secret or reads it on every request.

secret_reads{"name": "signing-hmac-key", "since": "1h"}
→ ok acme-api-7c9f: 2,140 reads · not cached
vault_patterns{"since": "1h"}
→ ok signing-hmac-key read on every request by acme-api
provoke_secret{"name": "signing-hmac-key", "answer": "429", "for": "5m"}

MCP tools

  • list_secretsSecrets with version, state, expiry and reads
  • set_secretA new version of a synthetic secret
  • secret_readsWho read a secret and whether it looks cached
  • provoke_secretMake the next reads fail
  • provoke_keyMake key operations fail or sign wrongly
  • provoke_certificateMissing, expired or untrusted certificates
  • provoke_imdsBreak the managed identity endpoint
  • vault_logEvery operation, newest first
  • vault_patternsFindings in the access log
  • would_failWhat a real vault would have refused

The same over HTTP

  • GET/api/keyvault/secrets
  • GET/api/keyvault/secrets/{name}/reads
  • POST/api/keyvault/secrets/{name}/provoke
  • POST/api/keyvault/keys/{name}/provoke
  • POST/api/keyvault/imds/provoke
  • GET/api/keyvault/log