TL;DR
AI editors hardcode API keys, tokens, and JWT secrets straight into source because their training data is full of tutorials that do exactly that.
A hardcoded secret in a public repo is compromised the moment it is pushed, not when someone finds it.
Scan for secrets before every commit and move them to environment variables. It takes 30 seconds.
I asked Cursor to wire up Stripe billing for a side project last week. It gave me working code in about ten seconds. It also gave me this:








