Skip to content
Agent Orchestration
Skill

/semgrep-skill

Runs the installed local Semgrep CLI through a bounded JSON wrapper with two bundled non-secret rules. Requires an explicit authorized workspaceRoot and target. No remote rules, uploads, installs, source excerpts or automatic fixes.

From plugin
kim-service
19635 skills15 agents10 commands

Claude Code

$ npx -y skills add KimYx0207/Kim_Service --skill semgrep-skill --agent claude-code

SKILL.md

semgrep-skill.SKILL.md
name: semgrep-skill
description: "Runs the installed local Semgrep CLI through a bounded JSON wrapper with two bundled non-secret rules. Requires an explicit authorized workspaceRoot and target. No remote rules, uploads, installs, source excerpts or automatic fixes."
version: "1.2.0"
context: fork

Local Semgrep security scan

本能力的验收方法

执行前读取 [method.json](method.json) 中当前 capabilityId 的诊断、决策和逐字段 outputChecks,并读取 [任务验收与完整示例](references/acceptance.md)。按本次能力选择相应规则,不用字段齐全、行数或作者自报代替产物质量。缺少 blocking 证据时保留未验收;既有具体授权与宿主最终决定权不变。

专业引用与工具路线继续按下文渐进读取;[来源记录](PROVENANCE.md) 和 [作者正反例](evals/professional-cases.json) 供评审。当前 Meta Skill 发现不会自动注入 method.json,宿主需按此入口读取;未观察到加载或执行时不得宣称生效。

Use only `<skill-dir>/scripts/scan.py`, where `<skill-dir>` contains this file. The package `capability.json` defines the input, result and optional invocation. Read it after the caller verifies the discovered package hash. The generated index selects the package; it does not contain or grant the invocation.

Safety contract

  • Require the user's explicit authorized absolute local `workspaceRoot` and a

directory `target` inside it. Never default to the current project or drive.

  • The wrapper accepts only `rules/local-security.yml`, extracts just

`python-subprocess-shell-true` and `javascript-eval` into temporary configuration before scanning, and records both hashes. The bundled legacy secret-pattern rule is not executed by this route; credential checks are outside this capability.

  • It executes an already-installed trusted host CLI with an argv array and

`shell:false`. Never execute files from the scan target as programs.

  • Both the version probe and scan use `--metrics off`, `--disable-version-check`,

isolated settings/log/cache paths, and a minimal subprocess environment. Caller tokens, proxies and custom Semgrep configuration are not inherited. Windows APPDATA and a computed installed Python user base/site may be retained solely to locate the existing host runtime; caller PYTHONPATH is not inherited.

  • Do not use `--config auto`, registry URLs, Semgrep Cloud, login or uploads.
  • Do not use `--autofix`, write reports, install Semgrep or fetch rules. The

installer installs the Skill projection only and requires separate write approval.

  • stdout contains rule IDs, workspace-relative paths, spans, severity and bundled

rule messages. Raw source, metavariables and raw CLI diagnostics are withheld.

Invoke and interpret

From any working directory, pass one UTF-8 JSON object over stdin:

{"schemaVersion":1,"workspaceRoot":"<authorized-absolute-local-root>","target":"<directory-within-root>"}
python "<skill-dir>/scripts/scan.py" --input-json -

Equivalent named arguments are `--workspace-root <absolute-root> --target <directory>`, optionally `--rules rules/local-security.yml`. There are no extra Semgrep flags, executable overrides or JSON-file paths. Do not separately run a bare `semgrep --version`: the wrapper performs its own isolated runtime check.

Return the wrapper result, not a promise to scan later. `completed` means every selected file was confirmed scanned, not that findings were empty or security was certified. `completed` exits 0 even with findings. `partial`, `invalid_input`, `unavailable` and `failed` exit 2 and keep `completed:false`. An unavailable tool must stay unavailable; no installation is attempted. Missing files or errors must never be labeled clean. Remediation remains advisory text.

Coverage and trust boundary

Only visible `.py`, `.js`, `.jsx`, `.ts`, `.tsx` files are selected. Hidden directories/files, node_modules, __pycache__, venv and vendor are excluded. Links/reparse points are rejected. Narrow targets to at most 512 eligible files, each at most 1 MiB; do not select a target containing the host temporary directory. Each subprocess has a 60-second limit; output is checked while running against an 8 MiB limit per stream. These are safety bounds in `scripts/scan.py`, not caller-adjustable business parameters.

`networkUsed:false` describes the enforced local configuration, metrics/version opt-outs and environment isolation; it is not OS network isolation or a packet capture certificate. `filesModified:false` means no source edits: temporary configuration, settings and logs are outside the target and cleaned afterward. Use a trusted host installation and stable filesystem; this is not a sandbox for malicious binaries or concurrent path replacement. Findings cover two patterns only; omitted file types and excluded directories were not audited.

Installing this Skill

`install.ps1`, `install.sh` and `scripts/install.py` remain dry-run first, require explicit project/user scope, and require `--apply` to write. They project this file, `capability.json`, the executable scripts, bundled rules, method, referenced professional resources, examples, documentation and licenses with hash receipts and rollback. The projected method's links must remain readable after installation. They never install Semgrep or overwrite legacy code-security. See README for preview/apply/rollback commands; do not treat scan permission as permission to install or change source.

Read more
@kimyx0207
Ships withkim-service

面向开发者、产品团队与内容创作者的开源 AI 角色方法与技能套件(Agent Playbooks & Skill Packs)。 Kim Service 将软件工程、产品设计、自媒体创作、商业财务与垂直运营中的实战方法论封装为可直接安装、可离线检索、带输入输出契约与验证脚本的标准组件包。无论是用 Claude Code / Codex / Cursor / Antigravity 写代码审接口,还是策划爆款选题、制作动态贴纸、搭建 12 个月现金流预测模型,都可以按领域套件一键装入你的 AI

19635 skills15 agents
Get the whole plugin

Stars on GitHub

Momentum

stars in total
196
Star history of KimYx0207/Kim_Service on GitHub, a chart by star-history.com

Other skills on kim-service.

agent-evaluation

agent-evaluation

用相同数据集比较不同模型客户端的已有输出,保留缺失项、关键断言、分层回归和成本延迟预算。 agent evaluation offline regression budget

agent-thinking-patterns

agent-thinking-pattern…

全行业、所有专业 Agent 可按任务选用的通用思考与行动方法。适合目标澄清、反证审查、目标倒推、专家方法比较、方案取舍、机会探索、先练后评、重复工作系统化、知识提炼或战略聚焦;不限定教育场景、不替换原 Agent 专业方法,也不要求每次使用全部十种。

api-contract-review

api-contract-review

API 契约审查(API contract OpenAPI compatibility idempotency)。检查接口是否能被真实调用、正确失败并兼容现有消费者。用于前后端要并行,先定接口。;API改版会不会破坏现有客户端?;接口重试和错误格式需要统一。

More skills from other plugins.

1password

1password

Set up and use 1Password CLI for sign-in, desktop integration, and reading or injecting secrets.

openclaw8d395k
@steipete@steipeteInstall Skill
jira-tickets

jira-tickets

Read and update Jira tickets through Orca's saved Jira connections. Use when a task comes from Jira or the user asks for Jira…

orca6d128k
@stablyai@stablyaiInstall Skill
agentmail

agentmail

Use your assigned AgentMail inbox to read email tasks, explicitly send or reply, and check delivery. Provided automatically by…

paperclip7d114k
@paperclipai@paperclipaiInstall Skill
adr-create

adr-create

Create a new Architecture Decision Record with sequential numbering and AgentDB registration

@ruvnet@ruvnetInstall Skill

Questions about semgrep-skill.

Which coding agents can use semgrep-skill?
semgrep-skill installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.