原型 · 预览版:收录官方注册中心里的全部服务器,每 30 分钟同步一次。评价和账户功能将在后续阶段推出。
PopNx MCP为使用 AI 的人准备的 MCP 服务器 · 用大白话讲清楚

Code Sentinel

作者:salrad22版本 0.2.6i★ –i在你的电脑上运行
注册名称io.github.salrad22/code-sentinel

安装

概览

作者提供的说明(英文原文)

Code quality analysis MCP server - detects security issues, deceptive patterns, and placeholders

PopNx MCP 的三大支柱

这三项永远不会合并成一个分数:意见、测量和人气是不同的东西。

它能帮你做什么

我们还没有为它写通俗的介绍。下面是我们从注册中心读取到的事实。

  • 连接方式: 在你的电脑上运行
  • 传输方式: stdio
  • 分类: 其他

安装

选择你使用的 AI 应用,然后复制设置。

安装之前

  • 基础检查:1 项中通过 1 项
  • 在你的电脑上运行,拥有你的用户账户的权限(文件、网络、应用)。
  • 注册中心没有列出需要填写的密钥。

你需要

  • npm已安装 Node.js(用于 npx 命令)

你用的是哪个应用?

在上方选择你的应用。我们会记住它,下次按钮会显示“安装到 …”。

打开 Claude Desktop → Settings → Developer → Edit Config,把下面的内容粘贴到 claude_desktop_config.json

{
  "mcpServers": {
    "code-sentinel": {
      "command": "npx",
      "args": [
        "-y",
        "code-sentinel-mcp"
      ]
    }
  }
}

在终端中运行这条命令

claude mcp add code-sentinel -- npx -y code-sentinel-mcp

在 Cursor 中打开

或者自己复制设置

粘贴到项目中的 .cursor/mcp.json,或 ~/.cursor/mcp.json

{
  "mcpServers": {
    "code-sentinel": {
      "command": "npx",
      "args": [
        "-y",
        "code-sentinel-mcp"
      ]
    }
  }
}

浏览器会先询问是否打开应用,然后应用会显示设置并请你确认。密钥的值会留空,由你自己填写。

在 VS Code 中打开

或者自己复制设置

粘贴到项目中的 .vscode/mcp.json

{
  "servers": {
    "code-sentinel": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "code-sentinel-mcp"
      ]
    }
  }
}

浏览器会先询问是否打开应用,然后应用会显示设置并请你确认。密钥的值会留空,由你自己填写。

这个服务器在你的电脑上运行,而 ChatGPT 只能连接互联网上的服务器。请选择其他应用。

你的选择通过 Cookie 保存在这台设备上,无需账户。

这些设置是根据作者在注册中心的条目生成的。如果 README 的写法不同,请以 README 为准。

它能做什么

它在你的电脑上运行;安装后,工具列表会显示在你的 AI 应用中。

基础检查i

我们检查的是任何人都能看到的信息;我们没有阅读代码。不适用的检查项不计入总数。 · 检查于 2026年11月6日

  • ✓ 通过

    作者与仓库一致

    注册名称已通过 GitHub 账户 salrad22 验证,该账户拥有此仓库

  • … 尚未检查

    仍在维护

    我们还没有从 GitHub 读取这个仓库

  • … 尚未检查

    有许可证

    我们还没有从 GitHub 读取这个仓库

  • – 不适用

    端点有响应

    它在你的电脑上运行,没有互联网端点

  • – 不适用

    使用 OAuth 登录

    在你的电脑上运行,改用本地设置

  • … 尚未检查

    工具描述中没有隐藏指令

    它在你的电脑上运行;我们只能读取互联网端点的工具列表

与“其他”中的其他服务器比较i

  • 星标数多于此分类中其他 32410 个服务器的 0%
  • 发布到注册中心的时间比此分类中其他 32410 个服务器的 1% 更新
  • 基础检查结果等于或优于此分类中其他 32410 个服务器的 100%

与注册中心里这个分类中所有活跃的服务器比较。只有当发布者拥有该仓库时,星标数才计入。

常见问题

Code Sentinel 安全吗?

它在 1 项适用的基础检查中通过了 1 项。我们没有阅读代码。在添加密钥或令牌之前,请先看看这个服务器要求哪些权限,并使用只具备所需权限的密钥。

它需要哪些密钥或代码?

注册中心没有列出必需的密钥,不过有些服务器会在首次使用时要求你登录。

它在我的电脑上运行还是在云端?

它在你的电脑上运行。你的 AI 应用会在需要时启动它,数据不会经过作者的服务器(除非它自己调用在线服务)。

它还在维护吗?

GitHub 仓库最后更新于–,最新版本(0.2.6)于10个月前进入注册中心。

哪些应用可以使用它?

支持 MCP 的应用,例如 Claude Desktop、Claude Code、Cursor 和 VS Code。你的电脑上还需要有 Node.js。

有什么可以替代它?

同一分类中有:Spec Driven Development, Remote Desktop Commander, debuff

替代选择

同一分类中其他作者的服务器,按星标数排序。

如何看卡片:★ GitHub 星标i三大支柱:评价 · 检查 · 使用情况i更新 = 最新版本发布到注册中心的时间i

Spec Driven Development

作者:formulahendry

MCP Server that facilitates spec-driven development workflows, not just Vibe Coding.

在你的电脑上运行★ 440MIT14个月前更新
安装

Remote Desktop Commander

作者:desktop-commander

Remote Desktop Commander: use files, terminal and processes on your own computers from any AI app.

在云端运行★ 211昨天更新
安装

debuff

作者:debuffjp

Let coding agents play, test and tune your 2D web game: live state, explained errors, replays, fuzz.

在你的电脑上运行今天更新
安装

作者的 README

打开 README

按原文从作者的仓库复制。PopNx MCP 没有审查或背书其内容。HTML、图片和脚本已被移除。链接会离开本站。

CodeSentinel MCP Server

A comprehensive code quality analysis server for the Model Context Protocol (MCP). CodeSentinel integrates with Claude Code and other MCP-compatible clients to detect security vulnerabilities, deceptive patterns, incomplete code, and highlight good practices.

Why CodeSentinel?

AI coding assistants can inadvertently introduce subtle issues: hardcoded secrets, empty catch blocks, TODO placeholders left behind, or patterns that hide errors. CodeSentinel acts as a quality gate, analyzing code for 93 distinct patterns across 5 categories before issues reach production.

Key differentiators:

  • Verification-aware detection: Many patterns include verification steps to reduce false positives
  • LLM-optimized output: Structured JSON output designed for AI consumption and action
  • Balanced analysis: Detects both issues AND strengths for fair code assessment
  • Multi-language support: Works with TypeScript, JavaScript, Python, Go, Rust, Java, and more

Why Not Tree-sitter or AST-Based Tools?

CodeSentinel intentionally uses a pattern-based approach rather than AST parsing. Here's why:

The Problem We Solve Is Different

Traditional linters (ESLint, tree-sitter) detect syntax errors and style violations. CodeSentinel detects semantically deceptive patterns - code that is:

  • Syntactically valid (passes all linters)
  • Structurally correct (valid AST)
  • But hides serious issues that AI agents commonly produce
Examples AST Tools Miss
// AST sees: valid try-catch block

// CodeSentinel sees: error swallowing that masks failures try { riskyOperation(); } catch(e) { }

// AST sees: valid function returning boolean // CodeSentinel sees: fake implementation that always succeeds function validateUser() { return true; } // TODO: implement

// AST sees: valid fallback expression // CodeSentinel sees: failure masking - "no data" vs "fetch failed" indistinguishable const users = response.data || [];

// AST sees: valid return statement // CodeSentinel sees: silent failure hiding if (error) { return null; } // error case

What Each Approach Detects
Issue TypeAST/Tree-sitterCodeSentinel
Syntax errorsYesNo (not our goal)
Missing semicolonsYesNo
Unused variablesYesNo
Empty catch blocksPartiallyYes
Silent error returnsNoYes
Fake success responsesNoYes
TODO/placeholder codeNoYes
Error-masking fallbacksNoYes
Hardcoded secretsLimitedYes
Deceptive commentsNoYes
The Real Issue: Agent Behavior

AI coding agents produce code that looks correct but contains subtle deceptions:

  1. "Making the error go away" - Empty catches, silent returns, swallowed exceptions
  2. Placeholder implementations - return true, return [], TODO comments
  3. False confidence patterns - || [] fallbacks that mask fetch failures
  4. Suppression abuse - @ts-ignore, eslint-disable to hide type errors

These patterns pass every linter and compile successfully. AST tools see valid structure. Only pattern-based detection catches the semantic intent behind the code.

When to Use What
ToolUse For
ESLint/TSLintStyle consistency, syntax rules, unused code
Tree-sitterSyntax highlighting, code navigation, refactoring
TypeScriptType safety, compile-time errors
CodeSentinelAgent-generated deceptions, error hiding, incomplete implementations

CodeSentinel complements these tools - it catches what they structurally cannot.

Features

  • Security Analysis (16 patterns): Hardcoded secrets, SQL injection, XSS, command injection, insecure crypto, disabled SSL, and more
  • Deceptive Pattern Detection (17 patterns): Empty catch blocks, silent failures, error-hiding fallbacks, linter suppression
  • Placeholder Detection (19 patterns): TODO/FIXME/HACK comments, lorem ipsum, test data, incomplete implementations
  • Error & Code Smell Detection (18 patterns): Type coercion issues, null references, async anti-patterns, floating point comparison
  • Strength Recognition (23 patterns): Highlights good practices like proper typing, error handling, testing patterns, documentation
  • HTML Reports: Visual reports with quality scores and actionable suggestions

Installation

From npm
npm install -g code-sentinel-mcp
From source
git clone https://github.com/salrad22/code-sentinel.git

cd code-sentinel npm install npm run build

Usage with Claude Code

Quick setup
claude mcp add code-sentinel -- npx code-sentinel-mcp
Or if installed globally
claude mcp add code-sentinel -- code-sentinel
Manual configuration

Add to your Claude Code MCP configuration file (~/.claude/claude_desktop_config.json):

{

"mcpServers": { "code-sentinel": { "command": "npx", "args": ["code-sentinel-mcp"] } } }

Remote Server (Cloudflare Workers)

CodeSentinel is also available as a remote MCP server on Cloudflare Workers. No local installation required!

Quick connect (Claude Code)
claude mcp add-remote code-sentinel https://code-sentinel-mcp.sharara.dev/sse

Or use the Streamable HTTP endpoint (recommended for newer clients):

claude mcp add --transport http code-sentinel https://code-sentinel-mcp.sharara.dev/mcp
Endpoints
EndpointProtocolDescription
https://code-sentinel-mcp.sharara.dev/mcpStreamable HTTPRecommended
https://code-sentinel-mcp.sharara.dev/sseServer-Sent EventsLegacy support
https://code-sentinel-mcp.sharara.dev/HTTP GETHealth check / server info
Self-hosting on Cloudflare

Deploy your own instance:

cd cloudflare

npm install npm run dev # Local development at localhost:8787 npm run deploy # Deploy to your Cloudflare account

Requirements:

  • Cloudflare account (free tier works)
  • Wrangler CLI (npm install -g wrangler)
  • wrangler login to authenticate

The server uses Durable Objects for persistent MCP connections. No database required.

Available Tools

analyze_code

Full analysis returning structured JSON with all issues and strengths. Best for programmatic processing.

Parameters:

  • code (string, required): The source code to analyze
  • filename (string, required): Filename for language detection (e.g., "app.ts")

Returns: JSON object with issues, strengths, and summary statistics.

generate_report

Full analysis with a visual HTML report. Best for human review.

Parameters:

  • code (string, required): The source code to analyze
  • filename (string, required): Filename for language detection

Returns: Markdown summary plus complete HTML report.

check_security

Security-focused analysis only. Use when you specifically want to audit for vulnerabilities.

Parameters:

  • code (string, required): The source code to check
  • filename (string, required): Filename

Returns: List of security issues or confirmation of none found.

check_deceptive_patterns

Check for code patterns that hide errors or create false confidence.

Parameters:

  • code (string, required): The source code to check
  • filename (string, required): Filename

Returns: List of deceptive patterns found.

check_placeholders

Find TODOs, dummy data, and incomplete implementations.

Parameters:

  • code (string, required): The source code to check
  • filename (string, required): Filename

Returns: List of placeholder code found.

analyze_patterns

Analyze code for architectural, design, and implementation patterns. Detects pattern usage, inconsistencies, and provides actionable suggestions.

Parameters:

  • code (string, required): The source code to analyze
  • filename (string, required): Filename for language detection
  • level (string, optional): Pattern level to analyze:
  • architectural: System structure patterns (layering, modules)
  • design: Gang of Four patterns (Singleton, Factory, Observer)
  • code: Implementation idioms (error handling, async patterns)
  • all: All levels (default)
  • query (string, optional): Natural language query to focus analysis (e.g., "how is error handling done?")

Returns: LLM-optimized JSON with detected patterns, inconsistencies, suggestions, and ready-to-execute action items.

analyze_design_patterns

Focused analysis of Gang of Four (GoF) design patterns. Best for understanding OOP structure.

Parameters:

  • code (string, required): The source code to analyze
  • filename (string, required): Filename for language detection

Returns: Detected design patterns with confidence levels, locations, and implementation details.

Example Usage

Ask Claude to analyze code:

Analyze this code for quality issues:

const API_KEY = "sk-abc123456789";

async function fetchData() { try { const response = await fetch(url); return response.json(); } catch (e) { // TODO: handle error } }

CodeSentinel will detect:

  • Critical (CS-SEC003): OpenAI API key hardcoded in source
  • High (CS-DEC001): Empty catch block silently swallowing errors
  • Low (CS-PH001): TODO comment indicating incomplete implementation

Detection Categories

Security Issues (CS-SEC)
IDPattern
SEC001Hardcoded secrets (API keys, tokens, passwords)
SEC002GitHub tokens
SEC003OpenAI API keys
SEC004AWS access keys
SEC005-010SQL injection patterns
SEC011-015XSS vulnerabilities
SEC016Command injection (eval, exec)
Deceptive Patterns (CS-DEC)
IDPattern
DEC001-003Empty/comment-only catch blocks
DEC010-012Silent promise rejections
DEC020-025Error-hiding fallbacks ([],{}, ?? default)
DEC030+Linter suppression, fake success responses
Placeholders (CS-PH)
IDPattern
PH001-005TODO/FIXME/HACK/XXX/NOTE comments
PH010-015Lorem ipsum, placeholder text
PH020-025Test/dummy data (test@example.com, password123)
PH030+console.log debugging, debugger statements
Errors & Code Smells (CS-ERR)
IDPattern
ERR001-005Loose equality (==), type coercion issues
ERR010-015Null reference risks
ERR020-025Async anti-patterns
ERR030+parseInt without radix, array mutation in loops
Strengths (CS-STR)
IDPattern
STR001-005TypeScript strict typing
STR010-015Proper error handling patterns
STR020-025Test coverage indicators
STR030+Documentation, input validation

Scoring Algorithm

Quality score (0-100) calculated as:

Score = 100 - (critical × 25) - (high × 15) - (medium × 5) - (low × 1) + (strengths × 2)
SeverityPoint Deduction
Critical-25 points
High-15 points
Medium-5 points
Low-1 point
Strength+2 points (bonus)

Supported Languages

CodeSentinel detects language from file extensions:

ExtensionLanguage
.ts, .tsxTypeScript
.js, .jsxJavaScript
.pyPython
.goGo
.rsRust
.javaJava
.ktKotlin
.swiftSwift
.csC#
.cpp, .cC/C++
.phpPHP
.vueVue
.svelteSvelte

Extending CodeSentinel

CodeSentinel uses a data-driven pattern system that separates pattern definitions from regex generation. This makes adding new patterns easier and more maintainable.

Project Structure
src/

├── patterns/ │ ├── types.ts # Type definitions for pattern configs │ ├── buil

只显示了开头部分;其余内容请在仓库中阅读

问 PopNx