lkml.org 
[lkml]   [2015]   [Sep]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Subjectc/r of seccomp filters via underlying eBPF
Date
Hi all,

Here is a set that enables checkpoint restore of the underlying eBPF programs
that power seccomp filters via the API we discussed several months ago. A few
notes:

* We expose prog_id in the ebpf dump as the pointer to the ebpf program in
kernel memory, since this is unique. I'm not sure if this is safe. The goal
of exposing prog_id is to enable userspace to figure out how the seccomp
filters are inherited (i.e. is the filter a result of a fork() or an
identical filter installed). This is relevant because
SECCOMP_FILTER_FLAG_TSYNC depends on this ancestry.

* I'm not sure what the fd argument to seccomp() should look like in the
SECCOMP_FILTER_FLAG_EBPF case: it seems ugly either as &fd or fd; any
thoughts on this are welcome.

* Please double check the first patch. I'm not too framiliar with eBPF, so this
is mostly monkey see monkey do.

* The last patch is something I discovered while testing this set (I couldn't
re-import some filters). I'm not sure if this is indicitave of a wider bug or
if the fix is even correct but it Works For Me.

Thoughts welcome,

Tycho



\
 
 \ /
  Last update: 2015-09-04 18:21    [W:0.172 / U:1.012 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site