Repository navigation
Commit 56390e5
committed
fix(ocsf): emit schema-conformant OCSF events and honest downgrades
Native events failed the official OCSF 1.8.0 validator: device.os lacked
type_id, HTTP Activity emitted is_src_dst_assignment_known, sandbox
Process Activity events had no actor, and connection_info lacked
direction_id. Schema tests missed these because they checked only
top-level, non-profile attributes. The 1.1 and 1.3 downgrade stripped
three fields by name and relabelled events that did not conform.
Add OS type and connection direction enums, require an actor on Process
Activity at compile time, set hostname on domain endpoints, and make
schema validation recurse into nested objects, reject undefined
attributes, and honour declared profiles.
Make the downgrade schema-driven from definitions generated from the
vendored official 1.1.0 and 1.3.0 schemas: undefined attributes move
under unmapped.downgraded_attributes, unsupported profiles are dropped,
and an event is labelled with the target only when every requirement
holds. Otherwise it stays at native 1.8.0 and is counted by the gateway
metric openshell_ocsf_log_kept_native_total and a supervisor warning.
Top-level container stays unchanged pending a decision on #4283.
Closes #4283
Closes #4284
Signed-off-by: Adel Zaalouk <azaalouk@redhat.com>1 parent 834b79a commit 56390e5
89 files changed
Lines changed: 26104 additions & 274 deletions
File tree
- crates
- openshell-ocsf
- schemas/ocsf
- v1.1.0
- classes
- objects
- v1.3.0
- classes
- objects
- v1.8.0/objects
- src
- builders
- enums
- events
- format
- objects
- tracing_layers
- validation
- tests
- openshell-sandbox/src
- openshell-server/src
- openshell-supervisor-network/src/policy_dns
- openshell-supervisor/src
- docs
- how-it-works/gateways
- observability
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
0 commit comments