# AI Code Security Auditor: Slopsquatting + Guardrail Diff

> Audit AI-generated code for hallucinated packages, silently removed auth guardrails, and agent-specific vulnerabilities.

AI Code Security Auditor: Slopsquatting + Guardrail Diff is a paid AI agent skill on Agensi by Ariel Mnang'at, in Code Quality & Review. It loads into your AI agent through the Agensi MCP server, always in its latest approved version.

- Price: $15 (one-time purchase)
- Creator: [Ariel Mnang'at](https://www.agensi.io/creators/ariel-mnang-at)
- Category: [Code Quality & Review](https://www.agensi.io/skills/code-quality-review)
- Version: 1.0
- Last updated: 2026-11-28
- Security: scan passed (2026-11-28); every new listing is also reviewed by a person
- Listing: https://www.agensi.io/skills/ai-code-security-auditor-slopsquatting-guardrail-diff
- Tags: code-review, security, javascript, python, llm-ops

## About this skill

AI coding agents often prioritize functional code over secure code, leading to hallucinated dependencies and silently removed guardrails. This skill provides a specialized security audit layer designed specifically to catch the unique failure modes of LLM-generated and agent-written PRs.

### What it does
- **Dependency verification** detects "slopsquatting" by cross-referencing imports against lockfiles and registries to catch hallucinated, malicious packages.
- **Guardrail diffing** identifies instances where agents silently deleted auth checks, middleware, or validation logic to make code "work."
- **API hallucination hunting** flags calls to non-existent framework methods, dead configuration keys, and invented REST endpoints.
- **Agent-specific secret detection** scans for hardcoded API keys, JWTs, and high-entropy strings frequently embedded by LLMs during scaffolding.
- **Injection analysis** reviews LLM-touching code for prompt-injection backdoors where model outputs are executed without validation.

### How it works
1. **Inventory phase** scans the change surface using `git diff` to identify modified configs, CI workflows, and source files.
2. **Dependency pass** runs offline scripts to verify every new import against official package registries and internal lockfiles.
3. **Guardrail audit** compares the new code against security-critical patterns like `@requires_auth` or CSRF middleware to ensure no regressions.
4. **Vulnerability sweep** performs a static analysis for OWASP Top 10 issues, specifically looking for hand-rolled crypto or "test fraud" mocks.
5. **Verdict reporting** generates a severity-ranked findings table with CVSS scores, specific line citations, and concrete code fixes.

### Frameworks & tools
The skill utilizes bundled Python scripts `check_dependencies.py` and `diff_guardrails.py`. It supports package managers across Node.js (npm/yarn), Python (pip/uv), Go, Rust (Cargo), and PHP (Composer).

### Why this beats prompting it yourself
Generic prompts often miss "silent deletions" where an agent simply stops including a security decorator. This skill enforces a 7-step systematic audit that treats LLM output as untrusted input, specifically looking for package hallucinations that standard linters ignore.

### Use cases
- Auditing a large PR generated by Claude Code or Cursor before merging to main.
- Reviewing fresh project scaffolds for hardcoded secrets and hallucinated library imports.
- Verifying that AI-refactored modules haven't accidentally bypassed existing auth middleware.
- Checking LLM-integrated applications for prompt-injection vulnerabilities and unsafe execution sinks.

### Known limitations
Does not perform dynamic analysis or runtime testing. Verification of packages is metadata-only and requires external registry access for full confirmation of package age and maintainer status.

## Requires

- Git
- Python 3.10+

## How to use this skill

1. Connect your AI agent to Agensi once: add the MCP server https://mcp.agensi.io/mcp/auth and sign in with your Agensi account (OAuth, no API key). Steps for Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and other agents: https://www.agensi.io/docs/mcp-setup
2. Ask your agent: "Use the AI Code Security Auditor: Slopsquatting + Guardrail Diff skill from Agensi" and describe your task.
3. Buy it on the listing or let your agent ask you first; your agent then loads it from Agensi when it needs it. Every paid skill has a money-back guarantee: https://www.agensi.io/docs/money-back-guarantee

## Frequently asked questions

### How does this differ from a standard linter or static analysis tool?

Unlike standard linters, this skill specifically targets 'AI slop'—hallucinated packages that don't exist in registries and instances where an agent silently deleted security decorators to make a feature work. It treats AI-generated code as untrusted input rather than just checking for syntax errors.

### Which AI coding agents is this security auditor compatible with?

This skill is agent-agnostic and designed to audit code produced by tools like Claude Code, Cursor, GitHub Copilot, or custom internal LLM workflows. It works by analyzing the git diff of the PR, regardless of which model or IDE generated the changes.

### What exactly is included in the purchase?

You receive the core logic scripts, including the dependency verifier and guardrail diffing engine, along with documentation for integrating the auditor into your existing CI/CD pipeline or local git hooks. It includes support for major package managers across Node.js, Python, Go, Rust, and PHP.

### Does the auditor require an active internet connection to function?

Dependency verification requires an internet connection to cross-reference imports against live package registries (like npm or PyPI). However, the guardrail diffing and secret detection phases can be configured to run entirely offline against your local lockfiles and codebase.

### Are there any limitations to the types of vulnerabilities this skill can detect?

While the auditor is highly effective at catching 'hallucinated' dependencies and missing auth checks, it does not perform dynamic runtime analysis or penetration testing. It focuses on static code integrity and identifying vulnerabilities introduced during the LLM's drafting process.

---

Source: [Agensi](https://www.agensi.io), the marketplace of skills for AI agents. Any MCP-compatible agent (Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and more) connects at https://mcp.agensi.io/mcp/auth and signs in with an Agensi account; setup for every agent: https://www.agensi.io/docs/mcp-setup. Append .md to any skill, guide or docs address on agensi.io for its markdown version.
