cilium / tetragon

eBPF-based Security Observability and Runtime Enforcement
https://tetragon.io
Apache License 2.0
3.65k stars 369 forks source link

Test and document the limitations of the fields in `TracingPolicy` #709

Open mtardy opened 1 year ago

mtardy commented 1 year ago

The documentation on TracingPolicy limitation might be outdated. It would be interesting to update the documentation and add tests case to make sure the limitations are prevented from the agent side instead of failing silently or creating an error on the BPF side.

I see two ways of doing that:

Limitations include for example:

kevsecurity commented 1 year ago

filter_file_buf() in basic.h limits the number of file matches to MAX_MATCH_FILE_VALUES. This is 8 on kernels >=5.2 and 2 on kernels <5.2.

kevsecurity commented 1 year ago

Postfix file match limited to 50 chars on kernels >=5.2 and 40 on kernels <5.2.

kevsecurity commented 1 year ago

File match equal and prefix limited to 128 chars on kernels >=5.2 and 32 on kernels <5.2.

kevsecurity commented 1 year ago

1408 will alleviate some of these limitations. e.g. number of matches becomes unbounded; equal and prefix lengths become 128 on all kernels; and postfix length becomes 128 characters on kernels >=5.2 and 96 on kernels <5.2.

jrfastab commented 1 year ago

This is old. File specific issues are refile with up to date info now.

mtardy commented 1 year ago

well, it was the point of this issue because documentation is currently outdated.

kkourt commented 11 months ago

well, it was the point of this issue because documentation is currently outdated.

Let's re-open it then? Maybe let's start with points where our current docs are outdated

Faster: annotate the doc to mention it is outdated

Doing that would be a great first step!