How it happens

Here's a conversation that happens thousands of times a day. A developer calls an internal API from Python and gets SSLError: certificate verify failed. They paste it into the assistant and ask for a fix. The answer comes back in a second:

billing/client.pyPython
resp = requests.post(PAYMENT_API, json=charge, verify=False)

The request now goes through. The real problem was that the company uses an internal certificate authority the container doesn't trust. The right fix was one line pointing at the CA bundle. What shipped instead accepts any certificate from anyone on the network path.

The model didn't misunderstand. It answered the question it was asked, and "make this error stop" has a short answer.

ERROR verify failed PROMPT "fix this" AI CHANGE verify=False LOOKS DONE tests green What nobody sees in the diff: server identity is no longer checked
The error was the security control doing its job.

Seven patterns we see over and over

The same shape repeats across stacks. The left column is what the developer pasted. The middle is what tends to come back.

Error the developer sawTypical AI "fix"What was lost
CERTIFICATE_VERIFY_FAILEDverify=False, NODE_TLS_REJECT_UNAUTHORIZED=0Server identity. Anyone in the middle can read and change traffic.
InvalidSignatureError (JWT)options={"verify_signature": False}Authentication. Any forged token is accepted.
Django 403 CSRF verification failed@csrf_exempt on the viewCSRF protection on a state-changing endpoint.
blocked by CORS policyReflect any Origin with credentials allowedSame-origin protection. Any site can read user data.
AWS AccessDenied"Action": "*", "Resource": "*"Least privilege. One bug becomes account takeover.
Refused to execute inline script (CSP)Add 'unsafe-inline' to script-srcThe main XSS mitigation CSP provides.
new row violates row-level security policyalter table … disable row level securityTenant isolation. Every user can read every row.

The last one deserves attention. On Supabase and similar platforms, the browser talks to the database directly with a public key, and row-level security is the only thing keeping one user out of another user's data. Turning it off to get past an insert error exposes the whole table to anyone who opens DevTools.

Why your tests won't catch it

Tests check that a feature works. Removing a security check makes the feature work better: requests that used to fail now succeed. No test you'd normally write fails when TLS verification is off or when CSRF protection is gone. CI goes green and reviewers see a one-line change with a passing build.

The diff is small and the blast radius is large. A one-token change like verify=False doesn't look like a security decision, so it doesn't get treated like one.

How to catch it

This is one of the easiest classes for a scanner, because the patterns are specific and syntactic:

  • SAST rules for disabled verification (verify=False, rejectUnauthorized: false, verify_signature: False), CSRF exemptions, and reflected CORS origins.
  • IaC rules for wildcard IAM, open security groups and, where it's in migrations, disabled row-level security.
  • Diff-aware blocking. Run these on the pull request and fail the check when new code adds one. An exception should be a deliberate, reviewed decision, not a side effect.
  • A rules file for the assistant saying "fix the root cause; never disable TLS, signature, CSRF or RLS checks". It reduces how often this happens. The scanner is what makes sure it doesn't ship.

AquilaX's Vibe Code scanner treats these "error suppressions" as a first-class category in AI-written code, and explains in the finding what the original error was most likely telling you.

Stop the one-line security regressions

AquilaX flags disabled checks in every pull request, with an explanation of the real fix.

See Vibe Code scanning →