ocsf
Skill1 starsChanged 31 days agoMITView on GitHub
OCSF 1.9.0: map application audit logs to Open Cybersecurity Schema Framework events, with categories, classes, objects, profiles, extensions and schema validation. Use when emitting security or audit events for a SIEM or data lake, mapping login, authorization, API, user or role changes to OCSF, picking a class_uid and activity_id, computing type_uid, filling metadata.version and metadata.product, applying profiles, or validating events against schema.ocsf.io. Triggers: OCSF, Open Cybersecurity Schema Framework, Authentication 3002, Authorize Session 3003, API Activity 6003, User Management 3007, Role Management 3008, Account Change deprecated, class_uid, type_uid, severity_id, status_id, unmapped, OCSF validator.
We split this skill into the rules it gives an agent
1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 29
Enums use 0 for Unknown and 99 for Other: When the _id is 99, the sibling string (for example activity_name or auth_protocol) carries the …
≈ “Common” is an estimate: at least 1 in 5 of the 308,232 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Open Cybersecurity Schema Framework (OCSF)
OCSF is an open, vendor-neutral schema for security events, published by the OCSF project and licensed Apache 2.0. Events are JSON objects that belong to one class inside one category, built from shared objects and attributes, and optionally extended with profiles and extensions. With this skill the agent maps application audit logs to valid OCSF 1.9.0 events and validates them.
Follow the workflow below step by step. Every rule here comes from a source in Sources, with the section it cites. When a rule and the pinned source disagree, the source wins; when the source has a newer revision than the pin, follow the refresh steps.
Inputs (fill in, or ask before starting)
- Role: producer (an application emitting OCSF), mapper (converting existing logs), or consumer (querying or validating OCSF).
- Source events: the audit log entries to map, for example logins, permission grants, API calls, user and role changes.
- Revision: OCSF 1.9.0, the version
https://schema.ocsf.io/api/versionreturns, unless the user names another.metadata.versioncarries this value. - Sources: when refreshing this skill or when a rule looks out of date, re-read every URL in Sources first, call
https://schema.ocsf.io/api/versionand the GitHub releases page for a newer release, and update the pins.
Invariants
- Every event has the required base attributes:
activity_id,category_uid,class_uid,metadata,severity_id,timeandtype_uid(schema API, class definitions). type_uidis computed. Producers and mappers compute it asclass_uid * 100 + activity_id(schema API,type_uidattribute). The validator reportstype_uid_incorrectotherwise.metadata.versionandmetadata.productare always set.metadata.versionis the OCSF schema version in SemVer;productneeds at least one ofnameoruid(schema API,metadataandproductobjects).- Enums use 0 for Unknown and 99 for Other. When the
_idis 99, the sibling string (for exampleactivity_nameorauth_protocol) carries the source value (white paper, enum conventions; schema API,activity_id). - Class-specific required attributes and constraints hold. For example, Authentication requires
userand at least one ofserviceordst_endpoint; API Activity requiresactor,apiandsrc_endpoint(schema API, class definitions). - Do not use deprecated classes for new mappings. In 1.9.0, Account Change (3001) and User Access Management (3005) are deprecated in favour of User Management (3007) (schema API, 1.9.0 release notes).
timeis the time the event occurred, as atimestamp_tin milliseconds since the epoch (schema API,timeattribute andtimestamp_ttype).original_time,logged_timeandprocessed_timerecord the other moments (white paper).- Source fields with no OCSF attribute go in
unmapped, or better, in a registered extension (schema API,unmapped; white paper, extensions). - Applied profiles are listed in
metadata.profiles, and their attributes then follow the profile's requirements (white paper, profiles).
Workflow
- Inventory the source events. List each audit event type with its fields: who acted, on whom or what, outcome, time, source address and product. ✓ Every event type has a one-line description and a sample record.
- Pick the category, class and activity. Map each event type to a 1.9.0 class and an
activity_id, and prefer the non-deprecated class. ->references/classes.md✓ Each event type hascategory_uid,class_uid,activity_idand a computedtype_uid. - Fill the base and class attributes. Set the required attributes, then the recommended ones you have data for (
status_id,status,message,actor,src_endpoint,sessionand others). ->references/attributes.md✓ Required attributes andat_least_oneconstraints are satisfied for every class used. - Set
metadata. Fillversion,product, and where availableuid,original_event_uid,correlation_uid,tenant_uidandlog_name. ->references/attributes.md✓metadata.versionis1.9.0andmetadata.product.nameoruidis set. - Decide on profiles and extensions. Apply a profile only when you fill its attributes; put leftover source fields in
unmappedor an extension. ->references/profiles-extensions.md✓metadata.profileslists every applied profile; no field is silently dropped. - Validate. Send each sample event to the schema server's validator, first plain and then with
missing_recommended=true. ->references/validation.md✓error_countis 0 for every sample; remaining warnings are known and accepted.
Verify before done
- Every event validates with
error_count: 0atPOST https://schema.ocsf.io/api/v2/validate. type_uidequalsclass_uid * 100 + activity_idin every event.metadata.versionis the pinned OCSF version andmetadata.productis set.- No new mapping uses Account Change (3001) or User Access Management (3005).
- Enum values of 99 carry the matching string attribute.
timeis in milliseconds since the epoch.- Personal data in
message,unmappedandraw_datahas been reviewed before the events leave the application.
Reference index
references/classes.md: categories, the Identity & Access Management and Application Activity classes, activity IDs, deprecations in 1.9.0, and an audit-event-to-class mapping table. Load for step 2.references/attributes.md: required, recommended and optional base attributes, the enums forseverity_idandstatus_id, and themetadata,product,user,actorandiam_roleobjects. Load for steps 3 and 4.references/profiles-extensions.md: the 1.9.0 profiles, how to apply them, extensions and their registry, andunmapped. Load for step 5.references/validation.md: the schema server API, the validator's response format and error codes, and four example events that validate against 1.9.0. Load for step 6.
Related skills
cloudeventsto carry OCSF events in a CloudEvents envelope:npx skills add ScaleDockHQ/scaledock-skills --skill cloudevents.opentelemetry-genaifor the OpenTelemetry side of AI agent activity:npx skills add ScaleDockHQ/scaledock-skills --skill opentelemetry-genai.
Sources
Status uses the publishing body's own maturity term. Checked is the date the source was last read.
- OCSF Schema 1.9.0 release: Released, 1.9.0 (published 2026-08-03), checked 2026-10-02.
- OCSF schema server: current version: schema server API, 1.9.0, checked 2026-10-02.
- OCSF 1.9.0 categories: schema server API, 1.9.0, checked 2026-10-02.
- OCSF 1.9.0 Authentication class: schema server API, 1.9.0, checked 2026-10-02.
- OCSF 1.9.0 metadata object: schema server API, 1.9.0, checked 2026-10-02.
- OCSF 1.9.0 profiles: schema server API, 1.9.0, checked 2026-10-02.
- OCSF Schema API (OpenAPI): schema server API description, served alongside 1.9.0, checked 2026-10-02.
- Understanding the Open Cybersecurity Schema Framework: white paper, main branch, checked 2026-10-02.
- OCSF extensions registry: registry, main branch, checked 2026-10-02.
In this repository40 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- find-skillsSkill
- a2aSkill
- ag-uiSkill
- ap2Skill
- asyncapiSkill
- authzenSkill
- cedarSkill
- cloudeventsSkill
- eu-ai-actSkill
- fapiSkill
- gnapSkill
- jwtSkill
- mcp-authorizationSkill
- oauthSkill
- openapi-arazzoSkill
- openapi-overlaySkill
- openapiSkill
- openfeatureSkill
- openid4vcSkill
- openid-connectSkill
- openid-federationSkill
- openidSkill
- opentelemetry-genaiSkill
- owasp-agenticSkill
- problem-detailsSkill
- ratelimit-headersSkill
- scaledock-agent-permissionsSkill
- scaledock-enterprise-identitySkill
- scaledock-http-apiSkill
- scaledock-mcp-serverSkill
- scaledock-repo-standardSkill
- scimSkill
- shared-signalsSkill
- spiffeSkill
- standard-schemaSkill
- typespecSkill
- web-bot-authSkill
- webmcpSkill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

