macos-security-bypass

macos-security-bypass is a skill for Claude Code, Codex from SeaOf0/dsh-redteam-model. It costs 0 tokens per session (1,774 once invoked), scanned A, original, MIT.

A guide to how macOS security checks work, including Gatekeeper, System Integrity Protection, code-signing checks, and notarization. It approaches these mechanisms from a reverse-engineering perspective.

In plain words
What is it for?
Use it to inspect quarantine attributes, notarization, code signatures, protected paths, and debugging restrictions when analyzing macOS security behavior.
Why use it?
It helps explain which macOS layer blocks an action and what evidence supports that conclusion. The analysis is intended for authorized targets.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to inspect quarantine attributes, notarization, code signatures, protected paths, and debugging restrictions when analyzing macOS security behavior.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/seaof0/dsh-redteam-model/macos-security-bypass
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add SeaOf0/dsh-redteam-model --skill macos-security-bypass
Clone the repo
git clone --depth 1 https://github.com/SeaOf0/dsh-redteam-model

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for macos-security-bypass

README.md
[![agentmods](https://agentmods.dev/badge/skills/seaof0/dsh-redteam-model/macos-security-bypass/github.svg)](https://agentmods.dev/skills/seaof0/dsh-redteam-model/macos-security-bypass)
Your own site
<a href="https://agentmods.dev/skills/seaof0/dsh-redteam-model/macos-security-bypass"><img src="https://agentmods.dev/badge/skills/seaof0/dsh-redteam-model/macos-security-bypass/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for macos-security-bypass

Your own site · 80×15
<a href="https://agentmods.dev/skills/seaof0/dsh-redteam-model/macos-security-bypass"><img src="https://agentmods.dev/badge/skills/seaof0/dsh-redteam-model/macos-security-bypass.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,774 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.01774
Opus 5 $0.00000 $0.00887
Sonnet 5 $0.00000 $0.00355
Haiku 4.5 $0.00000 $0.00177

Measured 9d ago against content hash 03e7345de52e, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

macos-security-bypass scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

modes/binary-analysis/refs/macos-security-bypass/SKILL.md · 114 lines

How it starts

The opening of the file, as written. The whole thing — 114 lines — stays where its author put it; the contents beside it link to each section on GitHub.

macOS 安全机制绕过分析(Gatekeeper / SIP / AMFI / 公证)

定位:从逆向分析视角拆解 macOS 四大安全机制——它们各自验什么、拦截在哪一层、绕过分析要满足什么前置条件。 与 dynamic/macos-process-injection.md 的「绕过 TCC/Gatekeeper/SIP 阻断注入」引用对应。 授权范围:仅对已获授权的目标做安全机制逆向与绕过分析;结论遵循字节级证据 + whoami 级最小影响;删除/破坏性操作只提示不执行。


0. 机制分层速览

机制 验什么 拦在哪 绕过分析焦点
Gatekeeper 应用来源(公证/隔离属性) 首次启动(用户态 syspolicyd quarantine xattr、公证票据、spctl 评估
SIP(System Integrity Protection) 系统关键路径写保护 + 内核扩展/调试限制 内核(csrutil 配置) csrutil 配置位、受保护目录、debug 限制
AMFI(Apple Mobile File Integrity) 代码签名 + 库校验 + 调试许可 内核(exec/映射时) get-task-allow/库校验/CS_OPS 判定
公证(Notarization) 应用经 Apple 扫描无恶意 下载来源(stapled 票据) 公证票据存在性、离线公证缓存

1. Gatekeeper

工作原理

  • 首次执行来源不明应用时,syspolicyd 检查 com.apple.quarantine 扩展属性与公证状态,决定是否放行。
  • 命令行观察评估结果:
xattr -l ./app                                  # 查 quarantine 属性
spctl -a -vv ./app 2>&1                         # 评估(rejected/accepted 及原因)
codesign -dv --verbose=4 ./app 2>&1             # 看公证/隔离来源

逆向分析点

  • 隔离属性来源com.apple.quarantine 记录下载来源(应用/URL),是 Gatekeeper 触发的前提。
  • 绕过分析的合法路径:移除隔离属性(xattr -d com.apple.quarantine ./app)或让应用满足公证——这属于「本地样本分析前的前置处理」,不是对生产系统发起攻击。
  • 判据:spctl -a -vvrejectedaccepted,且 xattr 无 quarantine。

2. SIP(System Integrity Protection)

工作原理

  • 内核级写保护 /System/usr(除 /usr/local)、/bin/sbin 等;限制 task_for_pid 调试、内核扩展加载、dtrace 等。
  • 配置查看(仅恢复环境可改):
csrutil status                                  # 查看 SIP 状态
csrutil enable --without debug                  # 恢复环境里放宽调试(示例,需重启)

逆向分析点

  • 受影响面:SIP 开启时无法调试受保护系统进程、无法写系统路径——限制「系统组件级」逆向。
  • 绕过分析的合法路径:目标为用户态应用(不受 SIP 目录保护)时无需关 SIP;仅当必须调试受 SIP 保护的系统进程/写系统路径时,才需在恢复环境 csrutil disable--without debug(需物理/管理员权限,重启生效)。
  • 判据:csrutil status 输出各保护位(System Integrity Protection status: enabled/disabled),按需记录调试限制是否解除。

3. AMFI(Apple Mobile File Integrity)

工作原理

  • 内核执行/映射代码时校验代码签名;执行 CS_OPS 判定(CS_VALID/CS_DEBUGGED/CS_GET_TASK_ALLOW 等)。
  • 控制「能否调试」(get-task-allow entitlement)、「能否加载任意 dylib」(Hardened Runtime 下的 disable-library-validation)。
  • 命令行观察:

Read the full file on GitHub · 114 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 114 lines · 0 tokens per session scan A 03e7345de52e

Subscribe to this mod's changes

macos-security-bypass is a skill published in the GitHub repository SeaOf0/dsh-redteam-model (325 stars, last pushed 5d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,774 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

dsh-sdk-upgrade

Safely select and install a compatible official @deepseek-ai SDK release for dsh plugin projects (dsh-web, dsh-trading, and similar monorepos) from npm using an isolated worktree, explicit cohort review, CI-equivalent validation, and controlled rollout — including syncing the project's declared DSH host-version floor…

zhu1090093659/dsh-web · 176 tokens

dsh-web-sdk-compatibility

Adapt and repair dsh-web after an approved official @deepseek-ai SDK/runtime cohort is selected or installed. Compare public API, type, service-injection, module-table, protocol, and behavior changes; map every change to repository consumers; implement the smallest fixes and durable compatibility contracts; handle…

zhu1090093659/dsh-web · 107 tokens

ov-experience-memory

Retrieve and apply OpenViking Experience memories through the Agent runtime's generic OpenViking search and read tools. Use before or during executable, multi-step, or tool-based work such as coding, file or data changes, configuration, deployment, workflow execution, and failure recovery when prior operational…

volcengine/OpenViking · 78 tokens

mem9

Persistent cloud memory plugin for OpenClaw. This document routes setup, troubleshooting, and uninstall flows and defines config boundaries.

mem9-ai/mem9 · 27 tokens

workflow

A command set for starting and managing step-by-step automated workflows.

inclusionAI/Avernet · 52 tokens

mnemos-setup

Setup mnemos persistent memory with mnemo-server. Triggers: "set up mnemos", "install mnemo plugin", "configure memory plugin", "configure openclaw memory", "configure opencode memory", "configure claude code memory".

mem9-ai/mem9 · 54 tokens