backend-audit-logging

backend-audit-logging is a skill for Claude Code, Codex from j4flmao/agent-skills. It costs 67 tokens per session (4,584 once invoked), scanned A, original, MIT.

A design for recording sensitive data access and changes in an append-only log that can show who did what and reveal tampering. It supports compliance records for rules such as GDPR, HIPAA, and SOC 2.

In plain words
What is it for?
Use it to define an audit-log table or implementation, including recorded events, retention rules, tamper evidence, and queries by user, resource, or time.
Why use it?
It provides a reliable history of important actions instead of leaving teams to reconstruct events from scattered application logs. This helps with investigations, reporting, and compliance checks.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: positional $N argument; mentions Codex.

Good fit Use it to define an audit-log table or implementation, including recorded events, retention rules, tamper evidence, and queries by user, resource, or time.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/j4flmao/agent-skills/audit-logging
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 j4flmao/agent-skills --skill audit-logging
Clone the repo
git clone --depth 1 https://github.com/j4flmao/agent-skills

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 backend-audit-logging

README.md
[![agentmods](https://agentmods.dev/badge/skills/j4flmao/agent-skills/audit-logging/github.svg)](https://agentmods.dev/skills/j4flmao/agent-skills/audit-logging)
Your own site
<a href="https://agentmods.dev/skills/j4flmao/agent-skills/audit-logging"><img src="https://agentmods.dev/badge/skills/j4flmao/agent-skills/audit-logging/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 backend-audit-logging

Your own site · 80×15
<a href="https://agentmods.dev/skills/j4flmao/agent-skills/audit-logging"><img src="https://agentmods.dev/badge/skills/j4flmao/agent-skills/audit-logging.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 67 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,584 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.00067 $0.04584
Opus 5.5 $0.00027 $0.01834
Sonnet 5.5 $0.00013 $0.00917
Haiku 4.5 $0.00007 $0.00458

Measured 16d ago against content hash 98787b1cdb14, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

backend-audit-logging 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 16d 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/backend/universal/audit-logging/SKILL.md · 498 lines

How it starts

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

Backend Audit Logging

Purpose

Record every sensitive data access and state change in an immutable, tamper-evident audit trail for regulatory compliance (SOC 2, SOX, HIPAA, GDPR).

Agent Protocol

Trigger

Exact user phrases: "audit log", "audit trail", "compliance logging", "tamper-evident log", "immutable log", "audit table", "change tracking", "who changed what", "data provenance", "audit events", "reporting log".

Input Context

  • Regulatory framework (SOC 2, SOX, HIPAA, GDPR, PCI-DSS).
  • Data classification and sensitive fields.
  • Existing database and storage infrastructure.
  • Retention requirements.

Output Artifact

Audit log schema or implementation code. No file unless requested.

Response Format

Event: {event type}
Actor: {user/system}
Resource: {resource type}:{id}
Action: {read|create|update|delete}

Completion Criteria

  • Audit events recorded for all sensitive operations
  • Audit log is append-only (immutable)
  • Tamper evidence implemented (hash chain or similar)
  • Retention policy configured
  • Audit logs queryable by actor, resource, and time range

Architecture Decision Trees

Storage Backend Decision Tree

What is the primary compliance requirement?
├── SOC 2 / SOX → PostgreSQL with hash chain (append-only table, partition by month)
├── HIPAA → Encrypted database with strict access controls + hash chain + 6-year retention
├── GDPR → Searchable storage with data deletion capability (anonymization, not deletion)
├── PCI-DSS → Immutable log with strict access controls, 1-year retention, quarterly review
└── General compliance → Cloud-native audit service (AWS CloudTrail, Azure Monitor)

What is the write volume?
├── < 1000 events/sec → Relational database (PostgreSQL, MySQL) with hash chain
├── 1000–10000 events/sec → Time-series database (TimescaleDB, ClickHouse)
└── > 10000 events/sec → Log aggregator (Elasticsearch) + batched hash chain

Tamper Evidence Decision Tree

Is tamper evidence required by compliance framework?
├── Yes → Is regulatory framework HIPAA or PCI-DSS?
│   ├── Yes → Hash chain with periodic verification (quarterly) + external audit service
│   └── No → Hash chain (SHA-256 linked list) or digital signature per entry
└── No → Append-only table with database-level access controls (no hash chain needed)

Volume consideration:
├── Single DB (<1000/s) → Hash chain linking each row via previous_hash
├── Medium (1000–10000/s) → Batch Merkle tree, publish root hash periodically
└── High (>10000/s) → Periodic hash anchor (chain per batch, not per event)

Read the full file on GitHub · 498 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. 16d ago Changed · +1 lines · -43 tokens per session 98787b1cdb14
  2. 17d ago Changed 46ff9b1342fd
  3. 1mo ago Changed · -122 lines 5e893a0b3484
  4. 3mo ago First seen · 619 lines · 110 tokens per session scan A 1f899d75de65

Subscribe to this mod's changes

backend-audit-logging is a skill published in the GitHub repository j4flmao/agent-skills (47 stars, last pushed 17d ago), licensed MIT. It adds 67 tokens to every session and 4,584 once invoked, about $0.0003 per session on Opus 5.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-09-03.

Related

backend-audit-logging compared with skills from other repositories

backend-audit-logging next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
backend-audit-loggingj4flmao/agent-skillsSkill4717d agoMITA67Claude Code, Codex
saas-msa-review-bossmann007ThomasMoreAI/legal-skills-openSkill1531mo agoApache-2.0A69Claude Code, Codex
akf-trust-metadatasickn33/agentic-awesome-skillsSkill51ktodayMITA60Claude Code
lgpd-ripdgoul4rt/lgpd-skillsSkill3454d agoMITA116Claude Code
lgpd-vendor-auditgoul4rt/lgpd-skillsSkill3454d agoMITA108Claude Code
wcagSushegaad/Claude-Skills-Governance-Risk-and-ComplianceSkill1.1k18d agoMITA162Claude Code
clio-webhookshookdeck/webhook-skillsSkill104yesterdayMITA64Claude Code, Codex