saglitzsecure-mcp

saglitzsecure-mcp

Enables security scanning of source code and Apple configuration files, providing evidence-based findings, explanations, remediation plans, threat modeling, and knowledge base access through MCP tools.

Category
访问服务器

README

SaglitzSecure

A static security scanner that needs no parser: it works over web/backend source code and Apple platform configuration (Info.plist), and ties every finding to file + line evidence and to a dated, primary-sourced knowledge base. It is used both from the command line and as an MCP server — you can connect it to Claude and say "run a security analysis on this project", or run it as a gatekeeper in a CI/CD pipeline.

The distinguishing claim: no advice is produced without a source. If a topic is not in the knowledge base the tool stays quiet and lists the nearest covered topics; plausible-looking but invented advice is decidedly worse than no advice at all.

One package

Everything ships as saglitzsecure: the CLI, the MCP server, the rule engine, the knowledge base and the skills.

Up to 0.3.0 the rule engine was published separately as @saglitz/security-core, so npm showed two entries for one product. Since 0.4.0 it is a subpath of the one package:

import { allRules, runRules, toSarif } from 'saglitzsecure/core';

That entry point carries the finding model, the 15-rule engine and the JSON/Markdown/SARIF writers, and nothing about the CLI or MCP — the same boundary the separate package used to draw, now enforced by packages/saglitzsecure/tests/core-boundary.test.ts and by the release preflight rather than by npm. The rules need no parser: the engine's package budget is zod alone, and today it spends none of it. Its node builtins are allowlisted too — node:crypto, node:fs/promises, node:path and nothing else — so the part of the tool that reads your source cannot spawn a process or open a socket.

@saglitz/security-core is retired. If you depend on it, drop it and depend on saglitzsecure, importing from saglitzsecure/core.

Installation and use

CLI

npx saglitzsecure scan .
npx saglitzsecure scan . --target apple --format sarif --fail-on high
npx saglitzsecure explain apple/ats-arbitrary-loads
npx saglitzsecure knowledge --freshness

Exit codes: 0 below the threshold · 1 threshold exceeded · 2 tool error (invalid argument, unreadable directory, nothing audited). "The scanner crashed" and "the code is clean" never give the same signal.

MCP

claude mcp add saglitzsecure -- npx -y --package=saglitzsecure saglitzsecure-mcp

Because the package name (saglitzsecure) and the MCP server's bin name (saglitzsecure-mcp) differ, npx is told explicitly with --package which package to install; without --package, a bare npx -y saglitzsecure-mcp looks for a DIFFERENT (non-existent) package carrying exactly that name in the npm registry and fails. The server exposes eight tools: scan_project, explain_finding, security_guide, knowledge_freshness, and the four that make up a remediation loop — remediation_plan, verify_fixes, threat_model, deep_review_protocol — see packages/saglitzsecure/README.md for the detail and for how the loop is used.

Claude Code plugin (skills + MCP server in one install)

The MCP command above gives Claude the eight tools. It does not give it the four skills, which are what decide when each tool is called, in which order, and what may not be said about the result — Claude Code never reads inside an npm tarball, so a skill shipped only in the package reaches nobody. The supported route for skills is a plugin, and this repository is itself the marketplace that serves it:

/plugin marketplace add HalidSaglam/saglitzsecure
/plugin install saglitzsecure@saglitzsecure

Both commands are run inside Claude Code. From the CLI the same thing reads claude plugin marketplace add HalidSaglam/saglitzsecure. Installing the plugin brings both halves: the four skills, namespaced as /saglitzsecure:security-audit, /saglitzsecure:secure-by-default, /saglitzsecure:threat-modeling and /saglitzsecure:remediation, and the MCP server above, declared inline in the plugin manifest — so claude mcp add is not needed on top. If the install summary says Run /reload-plugins to activate., run it.

Installed as a plugin, the eight tools are named mcp__plugin_saglitzsecure_saglitzsecure__scan_project and so on; added by hand with claude mcp add saglitzsecure, they are mcp__saglitzsecure__scan_project. Pick one route, or write permission rules that cover both prefixes.

To try the plugin from a local clone without a marketplace at all:

claude --plugin-dir /path/to/this/repository

What this release does not do

This section exists so that you read a "clean" scan knowing what it does NOT mean — the most dangerous failure mode of a security tool is not crashing, it is making a place it never looked at appear examined:

  • No data-flow (taint) analysis. Chains reaching from an input to a dangerous sink are not evaluated; the rules work at the single-file, single-pattern level.
  • No dependency CVE matching. Whether a lock file (package-lock.json and friends) EXISTS is checked; the known vulnerabilities of the packages inside it are not scanned.
  • No live target testing. The tool makes no network request; it only reads the files in the repository as text. Security headers added by a CDN or a reverse proxy cannot be seen — header/* findings reflect only the configuration in the repository.
  • Only the file types the discovery layer recognises are scanned. Web/backend source (certain extensions) and Apple platform configuration (Info.plist) are read; sources in other languages such as Python, Go, Ruby, PHP and Java are NOT scanned at all in this release. The rules are language-independent, but the discovery layer never gets those files to the rules — a project producing no findings does not mean "clean" when that project is written in an unsupported language.

Findings cover test and fixture files too: this release cannot deliberately tell a knowingly insecure example apart from a real vulnerability. Set your CI thresholds (--fail-on) accordingly, or narrow the scope with .saglitzsecureignore.

Every report ends with a coverage statement: what was looked at, what could not be, under which assumption. That statement is not a document separate from the tool, it is a mandatory part of every scan.

Excluding files from a scan

By default nothing is excluded — every file is scanned, your own test and fixture directories included. Narrowing the scope is your choice and it is never silent: everything you exclude appears in the coverage statement with a count and the patterns.

  • .saglitzsecureignore — a file at the scan root, in .gitignore syntax (comments, ! negation, the trailing / for directories, wildcards). It is committed to the repository and shared across the team.
  • --exclude <pattern> — a repeatable CLI flag for one-off use; it can override a rule in .saglitzsecureignore.

For the detail and examples see the package README.

Repository layout

packages/
  saglitzsecure/ the one published package
    src/         CLI (cli.ts) + MCP server (mcp.ts) + scan orchestration
    src/core/    the rule engine, finding model and report writers,
                 exported as `saglitzsecure/core`
knowledge/       an 11-section, dated, primary-sourced knowledge base
skills/          Claude skills (security-audit, secure-by-default, threat-modeling, remediation)
.claude-plugin/  plugin.json (the plugin, incl. the MCP server it configures on
                 install) + marketplace.json (this repo as a marketplace)

Publishing

If you are publishing from this repository, see RELEASING.md — the sequence, the gates it runs, and the npm-token traps learned the hard way are there.

License

MIT — see LICENSE.

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选