More screenshots

    Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIMuseMuseDotsDots+21 more

    Safe AI Coding: Permission Gate and Code Review

    0

    The agent calls a class that does not exist, or leaves `// ...

    $9.99

    Secure checkout via Stripe

    Money-back guarantee

    Converts to your local currency at checkout

    Security scanned
    Safe AI Coding: Permission Gate and Code Review

    Safe AI Coding: Permission Gate and Code Review

    Example session with this skill installed

    Review my changes before I commit. I edited the order controller and added a chart script to the layout.

    • Read your context and instructions
    • Compiled the safe ai coding

    Gate mode: balanced (asks only before actions that can cause harm)

    Summary

    I scanned the change and read every changed line through the AI lens and the human lens.

    Not ready: 5 HIGH and 1 WARN. The worst one is the ownership check removed from show(): any customer can open another customer's order. The scanner cannot see that kind of business rule.

    1. Pattern and symbol scan (diff-check.sh HEAD)

    HIGH  app/Http/Controllers/OrderController.php:18  SQL built from request input: SQL injection; use bound parameters
          > $rows = DB::select("SELECT * FROM orders WHERE email = '" . $request->input('email') . "'");
    HIGH  app/Http/Controllers/OrderController.php:20  AI placeholder: code was left out ('rest of the code...'); the file is incomplete
          > // ... rest of the code unchanged
    HIGH  config.local.php:1  Stripe live key
          > STRI****
    WARN  resources/views/layout.blade.php:1  script loaded from another site without integrity (SRI): if that host is compromised, its code runs for every user; pin the version and add integrity and crossorigin, or serve a local copy
    
    3 file(s), 12 added line(s) scanned. Findings: 3 high, 1 warn, 0 info.
    Syntax:  3 file(s) checked.
    

    2. Findings after the full read

    #SeverityWhereProblemWhat goes wrongFixFound by
    1HIGHOrderController.php:12user_id filter removed from show()Any signed-in customer opens /orders/123 and sees someone else's orderRestore Order::where('user_id', $request->user()->id)->findOrFail($id)Human lens
    2HIGHOrderController.php:18Email concatenated into SQL' OR '1'='1 returns every orderDB::select('... WHERE email = ?', [$email])Scan
    3HIGHOrderController.php:19OrderTotals is not defined anywhere in the projectFatal error on the first searchUse the existing totals code, or decide with meAI lens
    4HIGHOrderController.php:20Code replaced by "rest of the code unchanged"The method body is lostWrite the full methodScan
    5HIGHconfig.local.php:1Live Stripe key in a file git will pick upThe key leaks with the next pushMove it to .env, and rotate the key in StripeScan
    6WARNlayout.blade.php:1CDN script without SRI, added without askingA compromised CDN runs code for every visitorPin the version and add integrity and crossorigin, or serve a local copyScan + gate

    For each changed endpoint

    show(): reachable by every signed-in user. It returns any order by ID. It must return only that user's own orders.

    search(): reachable by every signed-in user. It returns every matching order across all customers. Decide who may search whose orders.

    Verdict: Not ready

    • Ran: diff-check.sh and its syntax check of 3 files.
    • Not run: tests. No test covers OrderController.
    • Permission requests: none in this session.

    Next steps

    1. Rotate the Stripe key now. It may already be in your shell history or a backup.
    2. Say "fix 1-5" and I will fix them in this change, then run the review again.
    3. For the chart script, I will ask before adding third-party code. I recommend a local copy.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    AI coding agents fail in predictable ways. The code runs but breaks the business rule. An ownership check goes missing. The agent calls a class that does not exist, or leaves // ... rest of the code unchanged where real code used to be. It reports "tested" when nothing ran. The agent itself can also run something harmful on your machine, or follow instructions hidden in a file it reads.

    Safe AI Coding closes those gaps, in any language and any repository.

    What it does

    1. Permission gate: it asks before harm, and says what the harm is

    Before a risky step, the agent stops and shows a permission block:

    • the exact command and where it runs
    • why the task needs it
    • what can go wrong (the worst realistic outcome first)
    • whether it can be undone
    • a safer option

    Then it waits for your yes. Your request for the task does not count as approval, and a "no" stands.

    It covers:

    • package installs
    • database writes and migrations
    • git push, reset and clean
    • deleting files
    • reading secrets
    • sending data out
    • adding CDN scripts and other third-party code
    • writing code that could open a security hole or leak data

    2. Two gate modes

    • balanced (default): asks only before steps that can cause harm, and does everything else without stopping.
    • strict: asks before every command and file change.

    3. Build mode: it copies your codebase, not generic framework knowledge

    The agent restates the business rule, then finds the closest existing example in your repository and matches its naming, validation, error handling, transactions and authorisation checks. It makes the smallest change, then proves it with syntax checks, tests and edge cases.

    4. Review mode: a scan plus two lenses

    • Scan: a scanner checks every added line for:
      • secrets and real-looking keys (printed masked)
      • SQL, command and path injection, XSS, SSRF
      • weakened auth, CSRF, CORS and TLS
      • destructive migrations
      • weakened tests
      • AI leftovers: elided code, pasted chat text, conflict markers
      • install hooks, unpinned dependencies, and CDN scripts without SRI
      • open Firebase rules, row level security switched off, secrets in VITE_ / NEXT_PUBLIC_ variables
      • LLM features that run model output as code or SQL
      • classes, methods, views, routes and imports that do not exist
    • AI lens: a full read for invented symbols, scope creep, copied defects and gamed tests.
    • Human lens: a full read as the teammate who maintains the code and the person who owns the business rule.

    You get a findings table with file:line, the concrete failure, the fix, and a verdict: Ready, Ready with notes or Not ready.

    5. Scan mode for a fresh clone

    Before an agent works in a repository you did not write, the scan finds what could steer or attack it:

    • instruction files, including copies inside vendor/ and node_modules/
    • agent settings that auto-approve tools
    • the repository's own git config and hooks
    • install hooks and custom package registries
    • symlinks that leave the repository
    • hidden unicode
    • committed .env files and keys

    6. Report mode, only when you ask

    A polished PDF covering:

    • what was wrong: symptom, root cause, impact and evidence
    • what was fixed, with before/after code
    • the checks and the scan counts
    • the permission log

    It comes in English or Roman Urdu.

    7. Alerts, so you never miss a question (optional)

    Start a task, switch to another app, and the skill tells you when the agent is waiting:

    • Sound: it repeats until you answer. It has its own on/off switch, and you can use your own .wav, .mp3 or .wma.

    • Popup (Windows): it appears when the editor is not in front and shows the same thing the editor shows:

      • for a permission: Allow, Deny and "Deny with a message"
      • for a question: every option, multi-select and an "Other" text answer

      You answer right there. It never takes the keyboard focus and has no default button, so a stray Enter cannot approve anything.

    • Mobile: a push to your phone through Claude Code's own notifications.

    8. Per-project switch, self-test and commit guard

    • off / on / status switch the skill off for one project and keep it everywhere else.
    • self-test runs 125 cases that prove the scanners catch attacks and stay quiet on good code.
    • An optional commit guard blocks commits with HIGH findings.

    Commands

    SayWhat happens
    build <task>Writes the change the safe way, then reviews it
    review [base]Reviews the current change
    scanChecks a repository before real work
    reportPDF report of the session
    mode strict / mode balancedHow often the gate asks
    off / on / statusThe skill in this project
    alerts on / off / test, alerts sound <file>Sound, popup and mobile push
    self-testProves the scanners work

    Where it stops

    • Pattern scans cannot judge intent or business logic. A clean scan means "no obvious red flags", not "safe". The human-lens review is there for that, and a person should still read the diff.
    • It changes your agent's settings only on your command (alerts on, off), and shows you the change first where it affects every project or your team.
    • Hard enforcement still belongs in tool permissions, branch protection and CI.

    Automated scans may miss obfuscated attacks. Performance is intentionally slower during high-risk tasks. Requires manual human verification for business logic and intent.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before any payment.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Money-back guarantee

    Doesn't do what its page promises? You get your money back.

    Trust & safety

    Security scan

    Security scan passed 18 days ago

    Requires

    Example
    Git
    Bash
    Perl
    and
    Node.js
    Python

    Permissions

    Network Access
    Read Files
    Write Files
    Environment Variables
    Terminal / Shell

    Allowed Hosts

    example.invalid
    cdn.example.invalid
    evil.example.invalid

    File Scopes

    .claude/settings.local.json
    ~/.claude/settings.json
    ~/.claude/safe-ai-alerts.json
    .git/hooks/pre-commit
    ~/Desktop/safe-ai-reports/**

    Terminal: runs git, bash and perl locally, plus php -l, node --check and python for syntax checks. It never runs code from the repository it scans. Read files: the current repository, to scan and review changes. Write files: only the temp folder while scanning. The rest is written only on the user's command: the PDF report (report), the two alert hooks in ~/.claude/settings.json and ~/.claude/safe-ai-alerts.json (alerts on/off; settings.json is backed up first), .claude/settings.local.json (off/on), and .git/hooks/pre-commit (commit guard). Environment variables: reads TMPDIR, and LOCALAPPDATA and the Program Files paths to find the temp folder and the browser. Optional settings: SAFE_AI_PDF_BROWSER, SAFE_AI_PDF_TIMEOUT. Nothing is sent anywhere. No network access.

    Listed18 days ago

    What's inside

    Frequently Asked Questions

    No. It lowers the risk of AI-written code and makes the agent's own review honest. A person should still read the diff.

    No. In the default balanced mode it asks only before steps that can cause harm. Say "strict mode" if you want a question before every step.

    Only when you ask. `alerts on` adds two hooks to your Claude Code settings after showing you the change, and `alerts off` removes exactly those. `off` writes one line to the project's personal settings file. Other settings are kept, and an invalid settings file is never overwritten.

    Yes: `alerts sound C:/path/to/sound.mp3`. `alerts sound off` mutes it and keeps the popup and the phone push.

    Any language for the gate and the review. The scanner has extra checks for PHP/Laravel, JavaScript/TypeScript and Python, and syntax-checks PHP, JS, Python and shell. |

    Yes, with Git Bash. The alert popup is Windows only; macOS and Linux get the sound and a system notification.

    New in Code Quality & Review