Events

Map the filtered es-python events as sources, files and the sinks they reached

Takes the SAME body as /api/get_all_events_with_count/, with view python, and returns the whole filtered set aggregated into a graph instead of a page of rows. This is what the events page's Map layout draws. Every event is counted under the source category the sources filter would select it with (socket, file, stdin, env, argv, manual, fuzzer, foreign, or other for an origin none of those claim), under the file it was read from when that source is file, and under its sink (the where field). sources, files and sinks list each of those, and links lists every source, file and sink path; each entry carries events (stored events), hits (the occurrences those events coalesce) and severity (the worst among them), worst first. file is empty on a link whose source is not file, and a file path is empty for a file read through a descriptor that named no path. Only what the filtered events contain appears: with no socket events there is no socket source. The filters, the monthly per-view quota, the suppression bucket and the impact-tag predicate mean exactly what they mean on the events page. Add any of source, file and sink as query parameters to also receive focus.events, the newest 200 matching events as list rows in the same 17-element shape as /api/get_all_events_with_count/, with focus.truncated set when there were more; the aggregate is never narrowed by them. A present but empty file selects the descriptor with no path. Add only=focus with a focus to receive just {"focus": ...} when you already hold the graph; a focus request is answered from the map most recently built for the same body, and its events are read fresh, so one that no longer matches the filter is left out. The map covers every event the filter selects, so truncated is false. Any view other than python is a 400.

This is a read: a read-only API key may call it.

post/api/event_map/

Request

  • Base URL: https://eyalsec.com
  • URL: https://eyalsec.com/api/event_map/
  • Auth: one of:
    • API key in header X-API-Key
    • API key in cookie __Host-es2session

Query parameters

sourcestring

Focus: one of socket, file, stdin, env, argv, manual, fuzzer, foreign, other. Anything else is a 400.

filestring

Focus: a file path exactly as it appears in files; empty selects the descriptor with no path. Only file-source events can match.

sinkstring

Focus: a sink label exactly as it appears in sinks.

onlystring

focus: return only the focus object, not the graph. Needs source, file or sink; any other value is a 400.

Request body

cursorstring

Opaque pagination cursor from a prior next_cursor.

sortstring

List order: newest (the default) or severity (critical first, then high, medium, low and info, newest first within each; events with no recognised severity last). Both orders list the same events. A cursor only continues the order that produced it: a cursor from the other order is a 400, so start again without one when changing order. Any other value is a 400.

whitelist_reprstring regex

Show only events whose sink label (the where field) matches this regex, case-insensitively. Despite the name, it is not matched against the repr. An invalid regex is a 400.

blacklist_reprstring regex

Hide events whose sink label (the where field) matches this regex, case-insensitively. Despite the name, it is not matched against the repr. An invalid regex is a 400.

fromstring

Lower time bound (RFC3339 or YYYY-MM-DD).

tostring

Upper time bound (RFC3339 or YYYY-MM-DD, inclusive of the whole day).

machinestring

Restrict to one machine by display name (exact match).

severitystring[]

Severity levels to include: critical, high, medium, low, info. Unknown values are ignored.

sourcesstring[]

Taint-source categories to include, matched against the event's origin: socket, file, stdin, env, argv, manual, fuzzer, foreign. Unknown values are ignored.

tagsstring[]

Restrict to events carrying any of these impact class labels (e.g. sqli, xss). An unknown label is a 400.

labelsinteger[]

Restrict to events carrying any of these triage label ids (your own, from GET /api/event_labels/).

xss_onlyboolean

es-chromium only: keep just the events whose sink can end in script execution. Must be sent with view=browser; with any other view it is a 400.

scopeobject

The events page's scope bar, as {mode, value, include_empty}: mode is is, ends (suffix) or regex, matched against the event's scope key (see scope on GET /api/event_view_counts/). A scope with no mode or no value is ignored; an unknown mode or an invalid regex is a 400.

advancedobject

The condition builder, as {match, conditions}: match is all (default) or any, and each condition is {field, op, value, negate}. The fields available depend on the view; an unknown field or an invalid value is a 400.

viewstring

Agent kind to include: python, browser, go, c, cpp, rust, node, solidity, java, bash, ruby or php. Omitted or empty = every view your account holds, which is what the pre-views clients this field exists for still get. Naming a view your account does not hold is a 403; if no products are enabled at all, even the omitted form is a 403. Any unrecognised value is a 400, never a silent empty page.

bucketstring

Sanitizer visibility bucket: live (the default, unsuppressed rows only), suppressed, or all. This was briefly named view during development; view now always means the agent kind above.

Response

OK.

object required

Changes

No recorded changes to this operation across all 1 revision of this API.