Plainmend

Notes

Deleted the key from git? It's still leaked

If an API key ever lands in a git commit, deleting the file doesn't help. The key lives on in your history, and bots scan public repos for keys within minutes.

AI coding tools make this easy to do. A key pasted into a prompt, a .env file that wasn't in .gitignore, a "temporary" hardcoded token.

Do this today:

  1. Rotate any key that was ever committed. Treat it as public.
  2. Add .env* to .gitignore before your first commit.
  3. Keep secrets in your host's environment settings, not in code.

Example (illustrative, not real data): an app has STRIPE_SECRET_KEY=sk_live_... in a first commit, removed the next day. The key still works until you rotate it.

Want a quick check of what your live app exposes? Run a free Plainmend scan.