Git · Senior · Question 12 of 76

How do you remove a leaked secret from a repository's whole history?

Explanation

filter-repo (or BFG) rewrites every commit; all collaborators must re-clone, and hosting caches and forks may keep copies. That's why rotating the secret is the step that actually matters.

Further reading

Problem with a question

Git · Senior · question 12

Test yourself

Take the Git · Senior quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz