MCP.Market

Codesafer MCP server

by goldmembrane·io.github.goldmembrane/codesafer·v1.0.1·1 stars

Scans AI-generated code for invisible Unicode, Trojan Source, and supply-chain threats.

B74/100grade B
What users say
No reviews yet
Be the first
Safety scan
B74/100

full report

Adoption
New

1 stars49 downloads/wk

Reviews

Write one

Nobody has reviewed Codesafer yet.

If you have run it, two minutes of your experience saves the next person an afternoon.

Codesafer tools (6)

write = sends, deletes, buys or posts

Read from the package source without running it. The installed server may list more.

  • ai_analyze

    Deep AI analysis of code using the trained CodeBERT model. Classifies code chunks as malicious or benign with confidence scores. Detects obfuscated payloads, novel attack patterns, and threats that static rules may miss.

  • check_dependencies

    Check package.json for typosquatting, suspicious install scripts, and dependency risks

  • explain_finding

    Get detailed explanation of a specific threat category including attack scenarios, real-world examples, and remediation steps

  • scan_directory

    Recursively scan a directory for hidden malicious code patterns across all source files

  • scan_file

    Scan a single file for hidden malicious code patterns (invisible chars, BiDi, homoglyphs, steganography, obfuscation, etc.)

  • scan_rules_file

    Scan an AI configuration/rules file for prompt injection and Rules File Backdoor attacks

Public scan report

scanner v0.1.9 · 2026-09-27 · same rubric, same numbers if you re-run it

1 medium
  • Code scan27 source files scanned20/25
  • –Live reliabilityno gateway calls yet and no remote to proben/a
  • –Tool poisoningtools not inspected (local package is not executed); not countedn/a
  • Auth qualitylocal package, no credentials required12/15
  • Maintenancelast push 147 days ago8/15
  • Maintainer identityregistry namespace matches repository owner; GitHub account older than a year8/10

Findings (1)

  • mediumeval / new Function usedexec.eval
    dist/index.js: …niques to hide the true intent of code: eval(), dynamic Function construction, base64…
Overall 74/100. Components that don't apply are left out of the denominator. Any critical finding is an F.RubricAppeal a findingJSON

How Codesafer compares

Against every graded MCP server, from our own scans and uptime checks. Updated after each scan run.

Safety score
74/100
higher than 40% of 48,255 servers
Tools
6
the typical server has 7
Tools that change things
0%
typical: 0%. Fewer write tools means less an agent can break
GitHub stars
1
more than 65% of 28,688 servers
Downloads a week
49
more than 41% of 12,191 servers with a package

What its tools let an agent do: 6 read

Install Codesafer in Claude Code, Cursor or VS Code

Runs npx -y cleaner-code on your machine. Read the scan report first; the gateway never runs local packages.

claude mcp add codesafer -- npx -y cleaner-code
Add to Cursor

What the publisher says

From the Codesafer repository's README, as published. We do not edit it. Read it on GitHub

CodeSafer (cleaner-code)

AI code security scanner as a Model Context Protocol (MCP) server.

Detects hidden threats in AI-generated code that traditional linters miss.

Website: codesafer.org  ·  MCP Clients: Claude Code, Cursor, VS Code + Copilot, Cline

Why CodeSafer?

AI coding assistants generate code fast — but who's checking it for hidden threats?

Recent supply-chain attacks show that malicious code can hide in ways human reviewers and traditional linters routinely miss:

  • Invisible Unicode characters injected into identifiers (30+ variants)
  • BiDi / Trojan Source attacks that reorder how code is displayed vs. executed (CVE-2021-42574)
  • Homoglyphs — Cyrillic characters masquerading as Latin (CVE-2021-42694)
  • Glassworm-style Unicode steganography hiding payloads in whitespace
  • Rules file backdoors planted in .cursorrules, CLAUDE.md, and other AI config files
  • Typosquatted dependencies in package.json
  • Obfuscation patterns — eval + base64, reverse shells, packed payloads

CodeSafer scans for all of these before the code runs on your machine.

How it works

CodeSafer runs as a local MCP server. Your AI client (Claude Code, Cursor, etc.) calls its tools when reviewing or generating code, and findings are returned inline.

Hybrid detection:

  1. 8 static analysis scanners — deterministic rules for known attack categories (fast, zero false-negatives on the patterns they cover).
  2. CodeBERT deep analysis — transformer model classifies code chunks as malicious/benign with confidence scores. Catches obfuscated or novel patterns that static rules miss.

Nothing leaves your machine. The AI analysis runs locally against a tokenizer server.

Features

MCP Tools

CodeSafer exposes six tools to your MCP client:

Installation

Prerequisites

  • Node.js 18 or later
  • An MCP-compatible client (Claude Code, Cursor, VS Code + Copilot, Cline)

From source

git clone https://github.com/goldmembrane/cleaner-code.git
cd cleaner-code
npm install
npm run build

Configure your MCP client

Claude Code (~/.claude.json or project .mcp.json):

Shortened. The full README is on GitHub.

Nothing above is checked by us. What we check is on the safety report.

Codesafer: common questions

Is Codesafer MCP server safe?
Mostly: it is graded B (74/100). Read the Codesafer safety report
How do I install Codesafer?
It runs on your machine. Copy the Claude Code, Cursor, VS Code or Claude Desktop config from the install section.
Does Codesafer need an API key?
Not as far as the registry entry and our scan can tell: no credentials are declared or required.
Is Codesafer maintained?
The last commit was 184 days ago (2026-05-04). The latest release is v1.0.1.
How does Codesafer compare with other MCP servers?
safety score 74/100 (higher than 40% of 48,255 servers); tools 6 (the typical server has 7); tools that change things 0% (typical: 0%. Fewer write tools means less an agent can break). Full comparison.