AI-penetration-testing

AI-penetration-testing

AI/ML/LLM Penetration Testing Toolkit by Mr-Infect โ€” the #1 GitHub resource for AI security, red teaming, and adversarial ML techniques. This repository is dedicated to offensive and defensive security for cutting-edge AI, Machine Learning (ML), and Large Language Models (LLMs) like ChatGPT, Claude, and LLaMA.

Stars: 91

Visit
 screenshot

AI Penetration Testing is a tool designed to automate the process of identifying security vulnerabilities in computer systems using artificial intelligence algorithms. It helps security professionals to efficiently scan and analyze networks, applications, and devices for potential weaknesses and exploits. The tool combines machine learning techniques with traditional penetration testing methods to provide comprehensive security assessments and recommendations for remediation. With AI Penetration Testing, users can enhance the effectiveness and accuracy of their security testing efforts, enabling them to proactively protect their systems from cyber threats and attacks.

README:

๐Ÿ›ก๏ธ AI Penetration Testing | ML & LLM Security | Prompt Injection

Welcome to the AI/ML/LLM Penetration Testing Toolkit by Mr-Infect โ€” the #1 GitHub resource for AI security, red teaming, and adversarial ML techniques. This repository is dedicated to offensive and defensive security for cutting-edge AI, Machine Learning (ML), and Large Language Models (LLMs) like ChatGPT, Claude, and LLaMA.

โœ… Designed for cybersecurity engineers, red teamers, AI/ML researchers, and ethical hackers โœ… focused to : AI Penetration Testing, Prompt Injection, LLM Security , Red Team AI, AI Ethical Hacking


๐ŸŒ Why AI/LLM/ML Pentesting Matters in 2025

AI is now integrated across finance, healthcare, legal, defense, and national infrastructure. Penetration testing for AI systems is no longer optional โ€” it is mission-critical.

Common Threats:

  • ๐Ÿ•ต๏ธ Sensitive Data Leaks โ€“ PII, trade secrets, source code
  • ๐Ÿ’€ Prompt Injection Attacks โ€“ Jailbreaking, sandbox escapes, plugin abuse
  • ๐Ÿง  Model Hallucination โ€“ Offensive, misleading, or manipulated content
  • ๐Ÿ Data/Model Poisoning โ€“ Adversarial training manipulation
  • ๐Ÿ”Œ LLM Plugin Abuse โ€“ Uncontrolled API interactions
  • ๐Ÿ“ฆ AI Supply Chain Attacks โ€“ Dependency poisoning, model tampering

๐Ÿš€ Get Started Fast

To use this repository effectively:

Recommended Skill Set

  • ๐Ÿ”ฌ Understanding of AI/ML lifecycle: Data > Train > Deploy > Monitor
  • ๐Ÿง  Familiarity with LLMs (e.g. Transformer models, tokenization)
  • ๐Ÿง‘โ€๐Ÿ’ป Core pentesting skills: XSS, SQLi, RCE, API abuse
  • ๐Ÿ Strong Python scripting (most tools and exploits rely on Python)

๐Ÿ“š Repository Structure

๐Ÿ” AI, ML, LLM Fundamentals

  • AI vs ML vs LLMs: Clear distinctions
  • LLM Lifecycle: Problem -> Dataset -> Model -> Training -> Evaluation -> Deployment
  • Tokenization & Vectorization: Foundation of how LLMs parse and understand input

๐Ÿ”ฅ AI/LLM Attack Categories

  • Prompt Injection
  • Jailbreaking & Output Overwriting
  • Sensitive Information Leakage
  • Vector Store Attacks & Retrieval Manipulation
  • Model Weight Poisoning
  • Data Supply Chain Attacks

โš”๏ธ Prompt Injection Techniques

  • "Ignore previous instructions" payloads
  • Unicode, emojis, and language-switching evasion
  • Markdown/image/HTML-based payloads
  • Plugin and multi-modal attack vectors (image, audio, PDF, API)

๐Ÿ† OWASP LLM Top 10 (2024 Version)

ID Risk SEO Keywords
LLM01 Prompt Injection "LLM jailbreak", "prompt override"
LLM02 Sensitive Info Disclosure "AI data leak", "PII exfiltration"
LLM03 Supply Chain Risk "dependency poisoning", "model repo hijack"
LLM04 Data/Model Poisoning "AI training corruption", "malicious dataset"
LLM05 Improper Output Handling "AI-generated XSS", "model SQLi"
LLM06 Excessive Agency "plugin abuse", "autonomous API misuse"
LLM07 System Prompt Leakage "instruction leakage", "LLM prompt reveal"
LLM08 Vector Store Vulnerabilities "embedding attack", "semantic poisoning"
LLM09 Misinformation "hallucination", "bias injection"
LLM10 Unbounded Resource Consumption "LLM DoS", "token flooding"

โžก๏ธ Read Full OWASP LLM Top 10


๐Ÿ› ๏ธ Offensive AI Pentesting Tools & Frameworks

Tool Description
LLM Attacks Directory of adversarial LLM research
PIPE Prompt Injection Primer for Engineers
MITRE ATLAS MITRE's AI/ML threat knowledge base
Awesome GPT Security Curated LLM threat intelligence tools
ChatGPT Red Team Ally ChatGPT usage for red teaming
Lakera Gandalf Live prompt injection playground
AI Immersive Labs Prompt attack labs with real-time feedback
AI Goat OWASP-style AI pentesting playground
L1B3RT45 Jailbreak prompt collections
PromptTrace Interactive AI security training with 7 attack labs, 15-level Gauntlet, and real-time Context Trace for prompt injection and defense bypass

๐Ÿ’ฃ Prompt Injection Payload Libraries


๐Ÿง  Research, Case Studies, and Exploits

๐Ÿ” Prompt Injection & Jailbreaking

๐Ÿงฌ Model Poisoning & Supply Chain

๐Ÿ•ท๏ธ Output Handling & Exfil

๐Ÿคฅ Hallucination, Bias & Ethics

๐Ÿงจ Token Abuse & DoS


๐Ÿค Contributions Welcome

Want to improve this repo? Here's how:

# Fork and clone the repo
$ git clone https://github.com/Mr-Infect/AI-penetration-testing
$ cd AI-penetration-testing

# Create a new feature branch
$ git checkout -b feature/my-feature

# Commit, push, and create a pull request

๐Ÿ” Keywords

AI Pentesting, Prompt Injection, LLM Security, Mr-Infect AI Hacking, ChatGPT Exploits, Large Language Model Jailbreak, AI Red Team Tools, Adversarial AI Attacks, OpenAI Prompt Security, LLM Ethical Hacking, AI Security Github, AI Offensive Security, LLM OWASP, LLM Top 10, AI Prompt Vulnerability, Token Abuse DoS, ChatGPT Jailbreak, Red Team AI, AI Security Research


๐Ÿ“ž Contact / Follow

โš ๏ธ Disclaimer: This project is intended solely for educational, research, and authorized ethical hacking purposes. Unauthorized use is illegal.


โญ๏ธ Star this repository to help others discover top-tier content on AI/LLM penetration testing along with security infra!

For Tasks:

Click tags to check more tools for each tasks

For Jobs:

Alternative AI tools for AI-penetration-testing

Similar Open Source Tools

For similar tasks

For similar jobs