Vibe-code security audit vs penetration test: which first?

AI-built app before launch: start with a vibe-code security audit. Contract, PCI DSS or a regulator asks for a pentest: you need one. Many teams need both.

· Comparison · · 8 min read

If your app was built fast with Lovable, Cursor, Bolt or Supabase and you want to find what's wrong in the code before launch or due diligence, start with a vibe-code security audit. If a contract, a payment standard or a regulator asks for a penetration test, you need a pentest, and an audit doesn't replace it. Many teams need both, in that order: fix the obvious first, then prove what an attacker can and can't do.

I've done both kinds of work for most of my career, from application security and digital forensics to talks on pen-testing. The two get confused because both end in a list of vulnerabilities. They answer different questions, and buying the wrong one costs you either money or a deal.

What does each one actually test?

A vibe-code security audit reads the inside of your app. In our Vibe-Code Security Audit we get read-only access to the repository, the database policies and the infrastructure configuration, and check them against more than 60 checks mapped to OWASP. Automated tools find the candidates: a secrets scan (Gitleaks), dependency and container scanning (Trivy), static analysis (Semgrep), Supabase policy checks, a scan of the JavaScript bundle and a dynamic scan of the running app (Nuclei). Then a senior engineer reviews the code by hand, confirms each finding and writes the fix. The audit also covers architecture, performance and GDPR, which a pentest normally leaves out.

A penetration test attacks the outside of your system. Testers act like an attacker, within rules of engagement you sign: which targets, which accounts, what's off-limits, which dates. They try to exploit what they find and chain small weaknesses into a real breach. Depending on scope, that can include your network, cloud setup, mobile app or internal systems. What you get back is evidence of what an attacker could actually do, and usually a report or letter you can show a customer or an auditor.

Put simply, the audit tells you what's wrong and how to fix it. The pentest tells you what someone could do with it, and gives you proof that a third party checked.

How do they compare?

VibeSec quick scan Vibe-Code Security Audit Penetration test
What it looks at The public site, from the browser alone: 40+ passive checks Code, database policies, dependencies, secrets, bundle and infrastructure config, plus architecture, performance and GDPR The running system, attacked within an agreed scope; can include network, cloud and mobile
Access needed A URL. No code, no credentials Read-only access to code and infrastructure. We never write or deploy Targets and test accounts defined in signed rules of engagement
Cost model Free Fixed price per audit. Remediation sprint priced separately Priced per scope, usually by targets and days of testing
Time to start and duration About 60 seconds 5-10 business days, readout within 48 hours; optional remediation sprint adds a week Depends on scope and the tester's calendar
Commitment None One audit; remediation optional One test; often repeated yearly or after major changes
What you own at the end An A-F grade, top findings with evidence, a PDF Severity-ranked report, remediation checklist, threat model, architecture brief, and the fixes if you take the sprint A findings report with proof of exploitation, and often an attestation for third parties
Who is accountable Nobody beyond the scan: a clean result is not an audit We answer for the findings and, in the sprint, for fixes that are reviewed and regression-tested The testing firm, for the scope it signed
Best fit A first look before you decide anything AI-built apps before launch, due diligence or enterprise onboarding A contract, regulator or payment standard requires it; validating fixes independently
Poor fit Anything beyond what the browser sees When a third-party pentest report is what the customer or regulator asked for Code that has never been reviewed: you'd pay testers to find what a scan finds in minutes

How does the audit map to OWASP?

Every check in the audit maps to a category of the OWASP Top 10:2025 or, for AI features, the OWASP Top 10 for LLM Applications. The categories we see most in AI-built apps:

  • A01 Broken Access Control. Supabase Row Level Security switched off or written wrong. We read every policy and test it with real requests.
  • A02 Security Misconfiguration. Missing security headers, open CORS, public storage buckets, source maps served in production.
  • A03 Software Supply Chain Failures. Dependencies and containers with known vulnerabilities, found by the dependency scan.
  • A05 Injection. Unvalidated inputs, found by static analysis and confirmed by hand.
  • A06 Insecure Design and A07 Authentication Failures. Checks enforced only in the browser, authentication flows that trust the client. The threat model covers these.
  • LLM01 Prompt Injection, LLM02 Sensitive Information Disclosure, LLM06 Excessive Agency. For apps with AI features: what a user can make the model do, what it can leak, and what the agent is allowed to touch without a person approving.

Exposed API keys don't sit neatly in one category. We treat them as critical wherever they appear.

A web pentest usually follows the OWASP Web Security Testing Guide, so both reports speak the same language. The difference is depth of evidence: the audit says "this policy lets any logged-in user read every row", the pentest shows the rows.

Why AI-built apps need the audit first

AI coding tools ship more surface than anyone has reviewed. Veracode tested more than 100 large language models on 80 coding tasks: in 45% of cases the generated code introduced vulnerabilities classified in the OWASP Top 10 (Veracode, 2025 GenAI Code Security Report, 30 July 2025).

In our own work the critical issues are rarely subtle. In one security rescue, a non-technical founder's AI-built SaaS had database access controls switched off on most tables, so user data could be read without logging in. Two API keys sat in client-side code and source maps were served in production. All seven critical and high findings were fixed in five working days, before the investor demo. A pentest at that stage would most likely have surfaced the same issues, without the fixes.

When is a penetration test required?

When someone else says so, and that's the point where the audit can't stand in for it.

  • Payment card data. PCI DSS v4.0.1 requirement 11.4 asks for internal and external penetration testing at least every 12 months and after significant changes to the cardholder data environment (Secure Ideas).
  • EU financial entities. Under DORA (Regulation (EU) 2022/2554, applying since 17 January 2025), article 26, entities identified by their competent authority must run threat-led penetration testing at least every three years (DORA art. 26).
  • Contracts. Enterprise customers and insurers often ask for a recent third-party pentest report in their security questionnaire. If the contract says "penetration test", an audit report won't satisfy it, however thorough.

If the requirement names an accreditation or an independent tester, check that whoever you hire meets it. And if we fixed your findings, a different firm testing afterwards gives your customer a cleaner independent view. We also run penetration tests for clients who need one without a formal accreditation requirement.

When the audit is the wrong choice

  • You need an attestation. A contract or regulator asks for a pentest. Buy a pentest.
  • Your risk is mostly infrastructure. An on-premise network, internal systems or people (phishing) are pentest and red-team territory. The audit is built for application code.
  • You already audited and fixed. The next useful step is independent validation, which is a pentest.

How to decide

  1. Does a contract, PCI DSS, DORA or a customer questionnaire ask for a penetration test? Yes → you need a pentest. Do the audit first if the code has never been reviewed.
  2. Was the app built mostly with AI tools, by a small team, without a security review? Yes → start with the audit.
  3. Do you want a free first look today? Run the VibeSec quick scan: a URL, about a minute, no code or credentials.
  4. Who will fix what's found, and who answers for it after launch? If nobody, take the remediation sprint or name an owner before you start.
  5. Is a launch, demo or due diligence date fixed? Work back from it: 5-10 days for the audit, a week for fixes, then the pentest if required.

If you're not sure which one you need, book a 30-minute call. We'll look at your stack, any contract or regulatory requirement, and your launch date, and tell you whether you need the audit, a pentest or both. Book a strategy call

See what an attacker sees, free

The VibeSec quick scan checks your live app from the browser alone. Paste a URL and get the first findings in about a minute, before you book anything.

Tell us what you're building.

Book a strategy call. We'll tell you where we can help, and say so quickly if we can't.

Let's talk