AI Pentest 8 min read

AI and LLM Penetration Testing in 2026: what to test, how much it costs and how to hire

Buyer's guide to AI and LLM penetration testing: OWASP risks, agents, scope, prices in Brazil, how to choose a provider and compliance with the EU AI Act.

Also in PT-BRPTES
AI and LLM Penetration Testing in 2026: what to test, how much it costs and how to hire

Chatbots, RAG and autonomous agents have left the lab and gone into production. A traditional pentest covers SQL injection, XSS and authentication flaws, but does not see risks specific to language models, such as prompt injection, system prompt leakage or tool abuse by agents. This guide explains what an AI pentest actually evaluates, how much it costs in Brazil and what to demand from a provider.

Short answer: An AI/LLM pentest tests the entire application — model, prompts, RAG, APIs, agents and access controls — against risks such as prompt injection, data leakage and excessive agency. In Brazil, typical projects cost R$ 40,000 to R$ 120,000 and last 5 to 10 days for simple chatbots/RAG; agents with tools require more. Ask for reproducible evidence, manual + automated coverage and included retest.

What an AI pentest covers

An AI pentest is not a “jailbreak list”. It is a structured assessment that maps the attack surface of the model and the surrounding ecosystem. The table below relates the risks of the OWASP Top 10 for LLM Applications 2025 with what the tester verifies, in defensive language.

OWASP LLM 2025 Risk What the tester verifies
LLM01: Prompt Injection Whether external inputs (user, documents, web pages) can manipulate the model’s behavior for unintended actions.
LLM02: Sensitive Information Disclosure Whether the model can reveal sensitive data from training, context or other users.
LLM03: Supply Chain Whether third-party components (models, datasets, libraries) introduce vulnerabilities or backdoors.
LLM04: Data and Model Poisoning Whether training or fine-tuning data can be poisoned to create malicious behaviors.
LLM05: Improper Output Handling Whether the model’s output is validated and sanitized before being used downstream (e.g., SQL, HTML, commands).
LLM06: Excessive Agency Whether the model has permissions or action capacity beyond what is necessary for its function.
LLM07: System Prompt Leakage Whether the system prompt can be extracted, revealing internal rules or secrets.
LLM08: Vector and Embedding Weaknesses Whether the vector base (RAG) allows injection of malicious content or leakage of chunks.
LLM09: Misinformation Whether the model produces false information with confidence, leading to wrong decisions.
LLM10: Unbounded Consumption Whether the model can be induced to consume excessive resources (loops, tokens, cost).

For a deeper look at indirect injection in RAG, see our article Indirect prompt injection in RAG.

Agents and tools: the new risk

AI agents that execute actions (send email, query database, call APIs) amplify the impact of any flaw. The OWASP Top 10 for Agentic Applications, published in December 2025 by the OWASP GenAI Security Project, lists risks such as agent goal hijack, tool misuse, identity and privilege abuse, agentic supply chain and unexpected code execution.

In practice, the pentest should evaluate:

  • Excessive agency: does the agent have more permissions than it needs? Can it execute irreversible actions without human approval?
  • Tool misuse: can a tool be called with malicious arguments to exfiltrate data or execute commands?
  • Human approval: is there a human in the loop for critical actions? Can the agent bypass this approval?

Our post AI agents and tool abuse details these scenarios.

How the project works

A successful AI pentest starts with clear scope. Typical scoping questions:

  • Which models and providers are used (OpenAI, Anthropic, open-source, fine-tuned)?
  • Is there RAG? Which data sources feed the vector base?
  • Does the system use agents with tools/actions? Which ones?
  • What user roles exist (admin, customer, anonymous)?
  • What is the sensitivity of the processed data (PII, financial, health)?

The project generally follows these phases:

  1. Reconnaissance and threat modeling: understand architecture, data flows and critical assets.
  2. Active testing: combination of manual tests (consultant reasoning) and automated tests (own and market tools), covering the model and the surrounding application (APIs, authentication, authorization).
  3. Documentation: report with reproducible evidence, risk classification, impact and remediation recommendations.
  4. Retest: after corrections, validate that the flaws have been closed.

The report should contain reproducible evidence (steps, requests, responses), not just screenshots. See what a pentest report should contain.

How much it costs

In Brazil, AI application tests typically cost R$ 40,000 to R$ 120,000, depending on complexity (number of models, RAG sources, agent tools, user roles). For Europe and the US, the price depends on the scope; request a quote.

Typical duration is 5 to 10 days of testing for a simple chatbot or RAG feature. Agents with multiple tools and roles require more time. The price range is what we publish for the Brazilian market; the timeframe is a typical estimate, and the final quote depends on the scope.

To better understand price factors, read how much a pentest costs.

How to choose the provider

Not every traditional pentest company is prepared for AI. Demand:

  • Real experience in AI/LLM testing: ask for examples of previous projects, methodology and understanding of OWASP LLM risks.
  • Manual + automated coverage: tools alone do not find logic flaws in prompts or agents.
  • Testing the application around the model: API, authentication, authorization and integrations should also be tested.
  • Not just a “jailbreak list”: the test should be threat-based, not based on ready-made payloads.
  • Retest included: confirm that the provider validates corrections at no extra cost.
  • Sample report: ask for a sample report to evaluate the quality of evidence and recommendations.

Want to go deeper before hiring? Download the free AI Security Pentest ebook and take the free LLM security course.

Also see our checklist for hiring a pentest and top pentest companies in Brazil.

Regulation: EU AI Act and good practices

The EU AI Act (Regulation 2024/1689) entered into force on 1 August 2024. Prohibitions on unacceptable risk practices apply from 2 February 2025; obligations for general-purpose AI models from 2 August 2025; and most obligations for high-risk systems were scheduled for 2 August 2026 (some systems embedded in products, 2027). In November 2025 the European Commission proposed postponing part of these high-risk deadlines (Digital Omnibus package); confirm the current calendar before planning.

High-risk systems must achieve adequate levels of accuracy, robustness and cybersecurity (Article 15). An AI pentest helps evidence these requirements, but is not a certification. Frameworks such as MITRE ATLAS (adversarial tactics against AI) and NIST AI RMF (AI risk management) complement the assessment.

For compliance with other standards (NIS2, DORA, PCI DSS, LGPD), see our articles on pentest for NIS2, DORA and TLPT, PCI DSS 4.0 and BACEN and LGPD and ANPD incidents.

Frequently asked questions

What is an AI/LLM pentest?

It is a security assessment that tests the AI application as a whole — model, prompts, RAG, APIs, agents and access controls — against LLM-specific risks such as prompt injection, data leakage and excessive agency. The goal is to find exploitable flaws and recommend corrections.

How much does an AI pentest cost in Brazil?

Typical projects cost between R$ 40,000 and R$ 120,000, depending on complexity (models, RAG, agents, roles). For Europe and the US, the price is defined by the scope; request a quote.

How long does an AI pentest take?

A simple chatbot or RAG feature generally requires 5 to 10 days of testing. Agents with multiple tools and user roles require more time.

Does the AI pentest cover only the model?

No. A good AI pentest also tests the surrounding application: APIs, authentication, authorization, integrations and infrastructure. The model is one part of the scope, not the whole.

What is the OWASP Top 10 for LLM Applications?

It is a list of the ten most critical risks for LLM-based applications, published by OWASP in November 2024. It includes prompt injection, sensitive information disclosure, supply chain, excessive agency, among others.

What is the OWASP Top 10 for Agentic Applications?

It is a list published in December 2025 by the OWASP GenAI Security Project, focused on risks of autonomous agents, such as agent goal hijack, tool misuse and unexpected code execution.

Does the AI pentest help with EU AI Act compliance?

Yes. Article 15 of the EU AI Act requires high-risk systems to have adequate robustness and cybersecurity. A pentest provides evidence of these controls, but does not replace the full compliance assessment.

What is the difference between AI pentest and jailbreak testing?

Jailbreak testing is just one technique to bypass model restrictions. An AI pentest is a comprehensive assessment that includes jailbreak, but also tests RAG, APIs, agents, authorization and data leakage.

Do I need a retest after the AI pentest?

Yes. The retest validates that corrections were effective and that new flaws were not introduced. Require the provider to include retest in the scope.

How to choose an AI pentest provider?

Check real experience in AI/LLM, threat-based methodology (not just payload lists), manual + automated coverage, testing the surrounding application, included retest and quality of the sample report.

Sources


Need to assess the security of your chatbot, RAG or AI agent? Request an AI pentest quote or start with a free Raio-X of your domain.