soc-2

An engineering guide to SOC 2, a framework for checking how an organisation protects information and runs its systems. It focuses on building systems that record audit evidence during normal operation.

In plain words
What is it for?
Use it to map engineering controls to SOC 2 criteria, design evidence-producing events, review controls, and plan continuous monitoring.
Why use it?
It helps replace manual evidence collection before an audit with controls and monitoring that continuously produce records.

Skill for Claude CodeCodex

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.

agentmods
npx agentmods add skills/grcwarlock/compliance-as-code/soc-2
Any agent
npx skills add grcwarlock/compliance-as-code --skill soc-2
Clone the repo
git clone --depth 1 https://github.com/grcwarlock/compliance-as-code

Made for: Claude Code, Codex.

Per session 59 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 673 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00059 $0.00673
Opus 5 $0.00030 $0.00336
Sonnet 5 $0.00012 $0.00135
Haiku 4.5 $0.00006 $0.00067

Measured 2d ago against content hash 31d037587ae8, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

soc-2 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 2d 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.

skills/soc-2/SKILL.md · 48 lines

How it starts

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

SOC 2 Skill (engineer-voice)

You are an expert on SOC 2 implementation from an engineering perspective. You help engineers design and instrument systems that produce audit-ready evidence by default — not engineers preparing screenshots two weeks before an audit.

When to use

  • Designing controls that emit evidence as a side effect of normal operation
  • Translating Trust Services Criteria (TSC) into event types, resource types, and assertions
  • Moving a manual control to continuous monitoring
  • Choosing what to instrument when starting a SOC 2 program from scratch
  • Reviewing existing controls for evidence quality and continuous-monitoring fit

Core knowledge (load on demand)

  • TSC structure and engineer's view — see references/trust-services-criteria-engineer-view.md
  • Evidence-as-code patterns — see references/evidence-as-code-patterns.md
  • Continuous monitoring patterns — see references/continuous-monitoring-patterns.md
  • Type 1 vs Type 2 from an engineering perspective — see references/type-1-vs-type-2-for-engineers.md

Working style

  1. Anchor every recommendation to a specific criterion (e.g., CC6.1 for logical access, CC7.2 for monitoring). Generic "implement access controls" advice is not useful.
  2. Translate the criterion into a system shape: what events get emitted, what resources get tagged, what assertion fires when.
  3. Default to continuous controls. Quarterly manual reviews are a fallback, not a target. If a control can be replaced with a real-time check plus an alert plus a remediation workflow, propose that.
  4. Be honest about the gap to audit-readiness. Some criteria require human judgment (board oversight, vendor risk reviews) and cannot be fully automated. Flag those clearly.
  5. Route attestation work out. Signing the SOC 2 report, opining on operating effectiveness, and auditor independence questions go to a licensed CPA firm.

Out of scope

  • Signing or opining on the SOC 2 report — route to a licensed CPA firm (SSAE 18).
  • ISO 27001 ISMS certification — route to the iso-27001 skill.
  • HIPAA-specific controls — route to a HIPAA-specific skill.

Read the full file on GitHub · 48 lines

Files

What ships with it

5 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 2d ago First seen · 48 lines · 59 tokens per session scan A 31d037587ae8

Subscribe to this mod's changes

soc-2 is a skill published in the GitHub repository grcwarlock/compliance-as-code (2 stars, last pushed 4mo ago), licensed MIT. It adds 59 tokens to every session and 673 once invoked, about $0.0003 per session on Opus 5. 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-31.

Related

Other skills, from other repositories

GRC & Compliance

Governance, risk, and compliance — risk assessment and scoring, control mapping across NIST CSF 2.0 / ISO 27001:2022 / SOC 2 / CIS Controls v8, gap analysis, audit evidence preparation, and security policy generation.

Masriyan/Claude-Code-CyberSecurity-Skill · 58 tokens

trestle-authoring-workflow

Use this skill for the Compliance Trestle authoring workflow. The workflow is the generate-edit-assemble cycle that converts OSCAL documents to markdown and back. Use it for authoring catalogs, profiles, SSPs, or component definitions. Use it for editing control markdown, YAML headers, or the roundtrip workflow…

oscal-compass-lab/compliance-trestle-skills · 76 tokens

trestle-compliance-pipeline

Use this skill for end-to-end compliance pipelines with Compliance Trestle. Topics include GRC personas, artifact ownership, multi-repository coordination, two-phase component definition authoring, CI/CD pipeline integration, and the Compliance-to-Policy (C2P) bridge. Use it for compliance pipelines, personas…

oscal-compass-lab/compliance-trestle-skills · 103 tokens

trestle-control-implementation

Use this skill to write control implementation responses, rules, parameters, and component-level responses. Use it for inheritance and leveraged SSPs in Compliance Trestle. Use it for control responses, implementation status, rules, parameters, component definitions, SSP implementation details, or compliance…

oscal-compass-lab/compliance-trestle-skills · 64 tokens

trestle-task-system

Use this skill for the Compliance Trestle task system for data conversion and transformation. Use it for CSV import, XLSX import, XCCDF results, Tanium results, and CIS benchmarks. Use it for config.ini task configuration, trestle tasks, or conversion of scan results to assessment results.

oscal-compass-lab/compliance-trestle-skills · 68 tokens

trestle-validation

Use this skill for Compliance Trestle validation, common errors, and troubleshooting. Use it for validation errors, trestle validate failures, and OSCAL schema checks. Use it to fix compliance document issues or to troubleshoot trestle problems.

oscal-compass-lab/compliance-trestle-skills · 54 tokens