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

Legal asks for personal data in old commits to be erased entirely.

AdvancedScenarioSecrets, Signing and Security
Answer

Situation read → This is the same operation as a secret purge, with extra legal tracking.

What I'd do →

  1. Identify exact files and strings with git log -S'<value>' --all and git grep across history.
  2. Rewrite with git filter-repo (path or text replacement) on a mirror clone.
  3. Force-push all refs, invalidate caches, delete forks and old clones, rebuild CI caches and artifacts.
  4. Ask GitHub Support to remove cached references and PR refs; record each step for compliance.

Why → Anything pushed may be in forks, clones, CI logs and backups, so the process is wider than Git.

Interview tip → Prevention: never commit real personal data into test fixtures.

All Git & GitHub questions Roadmap: Git & GitHub

More on Secrets, Signing and Security