Skip to content
Monitor usage

Monitor usage

A trust policy declares what’s allowed. Metrics and the audit log show what actually happened. The gap between the two is where you’ll catch a misconfigured policy or a compromised identity.

Prometheus metrics

Every exchange is counted at GET /metrics. The two to watch first:

# Exchange attempts by app, scope, identity, issuer, result
githubsts_token_exchanges_total

# JTI replay attempts: investigate immediately, this means a token was reused
rate(githubsts_jti_replay_attempts_total[5m]) > 0

See Metrics for the complete list: HTTP, exchange, JTI, policy, GitHub API, and reachability metrics, plus recommended alert queries.

Audit log

Every token exchange produces a structured audit log entry:

FieldMeaning
trace_idCorrelates a response error code to the server-side reason
issuer, subjectThe OIDC token claims presented
scope, app, identityThe exchange parameters requested
jtiThe token’s JWT ID
resultsuccess, policy_denied, oidc_invalid, etc.
error_reasonWhy a rejected exchange was rejected
duration_msExchange latency

Grep result!=success to find denied or invalid attempts; a spike is either a broken workflow or someone probing your policies.

Next

You’ve covered the full kickstart. From here:

  • OIDC Issuers: configure additional identity providers
  • Policy Recipes: copy-and-paste trust policy patterns
  • Helm Chart: run github-sts in Kubernetes for real workloads
  • Kubernetes: probes, secret mounting, TLS, and multi-replica behavior