This guide provides brief guidance on mapping data to schemas other than OCSF. While OCSF is the recommended choice for security data, you may need to support Elastic Common Schema (ECS), Google UDM, Microsoft ASIM, or another platform-specific schema.
Use Map to UDM and Map to ASIM for the dedicated Google UDM and Microsoft ASIM workflows.
Choosing a schema
Section titled “Choosing a schema”| Schema | Best For | Considerations |
|---|---|---|
| OCSF | Security data normalization | Vendor-neutral, comprehensive security focus |
| ECS | Elasticsearch/Elastic Stack | Tight Elastic integration, good field coverage |
| UDM | Google SecOps | Required for SecOps, API-oriented UDM shape |
| ASIM | Microsoft Sentinel | Required for Sentinel, KQL-optimized |
Elastic Common Schema (ECS)
Section titled “Elastic Common Schema (ECS)”ECS is Elastic’s open schema for structured data in Elasticsearch.
Key differences from OCSF
Section titled “Key differences from OCSF”- Field names use dots instead of nesting:
source.ipvssrc_endpoint.ip - Less prescriptive about field values
- Wider scope (not security-specific)
Mapping pattern
Section titled “Mapping pattern”// From OCSF to ECSecs.source.ip = ocsf.src_endpoint.ipecs.source.port = ocsf.src_endpoint.portecs.destination.ip = ocsf.dst_endpoint.ipecs.destination.port = ocsf.dst_endpoint.portecs.event.category = ["network"]ecs.event.type = ["connection"]ecs.network.protocol = ocsf.connection_info.protocol_nameecs.network.bytes = ocsf.traffic.total_bytesecs.@timestamp = ocsf.timeECS field sets
Section titled “ECS field sets”Common ECS field sets for security data:
event.*- Event metadata and classificationsource.*/destination.*- Network endpointsprocess.*- Process informationfile.*- File metadatauser.*- User informationhost.*- Host/device detailsthreat.*- Threat intelligence
Microsoft ASIM
Section titled “Microsoft ASIM”ASIM (Advanced Security Information Model) is Microsoft Sentinel’s normalization schema. Use Map to ASIM for the detailed ASIM mapping workflow.
Key differences from OCSF
Section titled “Key differences from OCSF”- Designed for KQL queries
- Uses specific parser naming conventions
- Column-oriented naming style
ASIM schemas
Section titled “ASIM schemas”ASIM provides schemas for:
- Network sessions
- Authentication events
- DNS activity
- Web sessions
- Process events
- File activity
- Audit events
Translation strategies
Section titled “Translation strategies”Direct field mapping
Section titled “Direct field mapping”When fields have direct equivalents:
ecs.source.ip = ocsf.src_endpoint.ipValue transformation
Section titled “Value transformation”When values need conversion:
// OCSF uses integers, ECS might use stringsecs.event.severity = ocsf.severity_id.string()Structural transformation
Section titled “Structural transformation”When structure differs:
// OCSF nested to ECS flatecs.source.ip = ocsf.src_endpoint.ipecs.source.port = ocsf.src_endpoint.portecs.source.bytes = ocsf.traffic.bytes_outEnum mapping
Section titled “Enum mapping”When schemas use different enumerations:
let $severity_map = { 1: "low", 2: "medium", 3: "high", 4: "critical",}ecs.event.severity_name = $severity_map[ocsf.severity_id]Maintaining multiple schemas
Section titled “Maintaining multiple schemas”If you need to support multiple target schemas:
- Normalize to OCSF first as your canonical format
- Create translator operators for each target schema
- Branch pipelines based on destination
// Central normalizationfrom_kafka "raw-events"my_source::ocsf::map // Normalize to OCSF
// Branch to different destinationsfork { // Send OCSF to data lake to_kafka "ocsf-events"}fork { // Translate and send to Elasticsearch ocsf_to_ecs to_opensearch "https://elasticsearch.example.com:9200", action="index", index="ecs"}fork { // Translate and send to Google SecOps ocsf_to_udm to_google_secops "..."}