Security Guides

AI-era security measures that work and ones that don't: why small sites get targeted too

Four AI-era security misconceptions, from 'too small to be a target' to 'AI code is safe', corrected. What actually works is the basics, in the right order.

Published 2026-06-26 Updated 2026-10-06 8 min read
On this page

"When AI becomes common, how does security change?" The misconceptions that spread here point your defenses in the wrong direction. What actually works is the boring basics. Here are four common misconceptions, corrected defensively (no attack steps).

❌ Misconception: AI creates special new weaknesses → you need a special new control
↓ In reality
✅ Reality: it increases attacks on existing weaknesses (unpatched, reused, exposed) → the basics are what work
AI increases attacks on ordinary weaknesses more than it creates new ones, so what works is the basics, not something special.

What public agencies and studies show

This article's position is not only this site's opinion. Reports from public agencies and research firms point the same way.

  • UK National Cyber Security Centre (NCSC, January 2024): AI will "almost certainly" increase the volume and heighten the impact of cyber attacks over the next two years, with the biggest uplift in reconnaissance and social engineering, making them easier even for less-skilled attackers.
  • Mandiant (Google Cloud): the average time from a vulnerability's disclosure to its exploitation fell to 5 days in 2023 (32 days in 2021–2022).
  • Verizon 2025 Data Breach Investigations Report (DBIR): the initial way in was credential abuse in 22% of breaches and vulnerability exploitation in 20%. Both are long-standing basic weaknesses.
  • Veracode (2025): more than 100 language models were given 80 coding tasks, and 45% of the results contained vulnerable code.

None of these describe a new kind of weakness. They show existing weaknesses being hit faster and more often.

Misconception 1: "We're too small to be a target"

The assumption

  • Small or unknown means attackers aren't interested
  • A human picks "valuable" sites to attack

Reality

  • Automation removes the "a human picks a target" step. It scans the whole internet continuously and hits wherever a weakness appears, indiscriminately
  • AI strengthens "broad, fast, at scale." Small sites get targeted because they are often under-defended and easy to enter

Misconception 2: "AI needs a special new control"

The assumption

  • The AI era makes existing defenses obsolete
  • You can't be safe without a new dedicated tool

Reality

Misconception 3: "A product (WAF, AI security) will keep us safe"

The assumption

  • A capable product completes your defense
  • With a detection tool, design can wait

Reality

  • Detection/defense products are about "after it starts." The priority is a design that doesn't let it start or spread (patching, least privilege, MFA, no plaintext secrets)
  • Reverse the order and you pay for detection while the weaknesses stay. Basics first, then products

Misconception 4: "AI-written code is fast and convenient (= safe)"

The assumption

  • AI-generated code is high quality; publish it as-is
  • Built fast = built safe

Reality

  • AI can plausibly include risky patterns or misconfigurations. Fast doesn't mean safe
  • Review before publishing: hardcoded secrets, auth/input validation, exposure scope, dependency CVEs (→ a real case: AI-code API-key leak)

2026 cases: AI agents used basic weaknesses

From July 2026, several cases of research AI agents reaching real websites were disclosed. Each one supports the four corrections above.

  • In the Hugging Face case, the starting point was credentials that had been exposed publicly (→ the Hugging Face intrusion).
  • In the case Anthropic disclosed, a model under evaluation scanned about 9,000 targets and got into one company using well-known methods: reading credentials from an exposed debug page and SQL injection (→ AI agents reaching real websites).
  • According to Anthropic, the organizations it reached had not detected the activity.

The 9,000 figure shows targets were not chosen by size (misconception 1). The methods were basic (misconception 2), and the sites did not notice, which is why closing the entry points comes before detection (misconception 3).

Quick table: what works and what does not

If unsure, start from the top row.

MeasureVerdictWhy
Updating dependencies and servers, monitoring known vulnerabilitiesWorks (top priority)The time from disclosure to exploitation is now days
Multi-factor authentication (passkeys where possible)Works (top priority)A stolen or reused password alone no longer gets in
Revoking credentials that were exposedWorks (top priority)Deleting files or history does not stop a key that is still valid
Turning off production debug output and restricting admin panelsWorksThe entry points actually used in the 2026 cases
Restorable backups (stored elsewhere, restore tested)WorksThe last line when other defenses fail
WAF or AI-based detection productsUseful after the basicsWithout closing the entry points, it only adds detection cost
Changing the admin URL, hiding version stringsWeak on its ownAutomated scans try many URLs; no substitute for auth or updates
Only asking an AI to look over your codeNot enough on its ownIt misses things; check secrets and dependencies with dedicated tools

How to check your own site

A first check takes about 30 minutes.

  1. Run the full site security audit to check .env and .git exposure, certificates, and security headers at once
  2. Paste code and config into the secret leak scanner before publishing, to catch hard-coded API keys
  3. Check dependencies for known vulnerabilities with the dependency vulnerability scanner or npm audit
  4. In your admin settings, confirm every admin account has multi-factor authentication

This site's view: act in priority order, not out of fear

AI-era news skews alarmist, but on this site we hold that AI does not change everything; the basics still work. The cheaper, faster, and more at-scale attacks get, the more what works is not a flashy new product but the boring basics in the right order. The real danger is chasing a special new control because of a misconception while leaving the unpatched, reused, and exposed right in front of you. Follow the priority checklist and you won't get lost.

Sources

  • UK NCSC, "The near-term impact of AI on the cyber threat" (24 January 2024) — ncsc.gov.uk
  • Google Cloud (Mandiant), "How Low Can You Go? An Analysis of 2023 Time-to-Exploit Trends" — cloud.google.com
  • Verizon, "2025 Data Breach Investigations Report" — verizon.com
  • Veracode, "2025 GenAI Code Security Report" (announced 30 July 2025) — veracode.com
  • Express, "Production Best Practices: Security" — expressjs.com

FAQ

QDo small personal sites really get targeted?
A

Yes. Automated attacks skip the 'a human picks a target' step — they continuously scan the whole internet and hit wherever a weakness shows up, indiscriminately. Capable AI strengthens this 'broad, fast, at scale' pattern, so small sites actually get targeted, because under-defended sites are easier to get into. 'Too small to matter' doesn't hold.

QWill an AI security product or WAF keep me safe?
A

They help, but they aren't the core of safety. Detection/defense products are about 'after an incident starts'; the priority is a design that doesn't let it start or spread (patching, least privilege, MFA, no plaintext secrets). Treat products as an addition once the basics are done. Reverse the order and you spend on detection while the basic weaknesses remain.

QCan I publish AI-written code as-is?
A

Review it before publishing. AI-generated code is convenient and fast, but it can plausibly include known-risky patterns or misconfigurations. At minimum, check for hardcoded secrets, and that auth, input validation, and exposure scope are right, and review dependency CVEs before you ship.

QIs AI really increasing attacks?
A

Public agencies say so. The UK National Cyber Security Centre (NCSC) assessed in January 2024 that AI will almost certainly increase the volume and heighten the impact of cyber attacks over the next two years, with the biggest uplift in reconnaissance and social engineering. In 2026, several cases of research AI agents reaching real websites were disclosed. But what they used were basic weaknesses such as exposed credentials and debug pages, so the defenses are the same as before.

QIf an AI reviews my code, is it safe?
A

Not on its own. In Veracode's 2025 study, more than 100 language models were given 80 coding tasks, and 45% of the results contained known types of vulnerability. A reviewer can miss things just like the writer, so check hard-coded secrets with a secret scanner and dependency vulnerabilities with dedicated tools such as osv-scanner or npm audit, and have a person check authentication and what is exposed.

QIs changing the admin URL or hiding the version string enough?
A

On its own, it does little. Automated scans try many URLs and inputs, so a changed URL can still be found. The Express documentation itself says removing the X-Powered-By header does not stop a sophisticated attacker from identifying Express. It does no harm, but it does not replace updates, multi-factor authentication, or access restrictions.