aquasecurity / kube-hunter

Hunt for security weaknesses in Kubernetes clusters
Apache License 2.0
4.71k stars 581 forks source link

Add report option for unique flattened json output #326

Open shellw opened 4 years ago

shellw commented 4 years ago

What would you like to be added

A new --report ndjson feature that flattens and outputs node, service, vulnerability combinations as unique JSON results.

Why is this needed

The current --report json option outputs json in one large chunk and does not map the relationship between nodes, services, and vulnerabilities. This makes it hard to ingest large amounts of output into a single entry for many logging tools and also makes it hard to correlate nodes and services to respective vulnerabilities.

dustin-decker commented 4 years ago

This would be very helpful when exporting logs to bigquery. It is difficult to query fields that are lists, and sometimes log lines exceed size limits in stackdriver (256kb) with the current JSON output.

danielsagi commented 3 years ago

+1