Interview Prep/Git & GitHub/Secrets, Signing and Security

You removed a secret from branches, but the old commit still opens through a PR link.

AdvancedScenarioSecrets, Signing and Security
Answer

Situation read → GitHub retains refs/pull/* and cached commit views even after history is rewritten.

What I'd do →

  1. Confirm the secret is rotated; that is the real fix.
  2. Contact GitHub Support with the commit SHAs to remove cached views and PR refs, as the refs are read-only to you.
  3. Check forks and ask owners to delete them.
  4. Record the incident and stop reusing the old repo state.

Why → You cannot delete refs/pull/* yourself, so rotation is the dependable control.

Interview tip → If a secret was public for any time, treat it as burned regardless.

All Git & GitHub questions Roadmap: Git & GitHub

More on Secrets, Signing and Security