Re: [PATCH v3 4/4] seccomp: add support for passing fds via USER_NOTIF

2018-06-03 Thread Tycho Andersen
Hi Alban, On Sat, Jun 02, 2018 at 09:14:09PM +0200, Alban Crequy wrote: > On Thu, 31 May 2018 at 16:52, Tycho Andersen wrote: > > > > The idea here is that the userspace handler should be able to pass an fd > > back to the trapped task, for example so it can be returned from socket(). > > > >

Re: [PATCH v3 4/4] seccomp: add support for passing fds via USER_NOTIF

2018-06-03 Thread Tycho Andersen
Hi Alban, On Sat, Jun 02, 2018 at 09:14:09PM +0200, Alban Crequy wrote: > On Thu, 31 May 2018 at 16:52, Tycho Andersen wrote: > > > > The idea here is that the userspace handler should be able to pass an fd > > back to the trapped task, for example so it can be returned from socket(). > > > >

Re: [PATCH v3 4/4] seccomp: add support for passing fds via USER_NOTIF

2018-06-02 Thread Alban Crequy
On Thu, 31 May 2018 at 16:52, Tycho Andersen wrote: > > The idea here is that the userspace handler should be able to pass an fd > back to the trapped task, for example so it can be returned from socket(). > > I've proposed one API here, but I'm open to other options. In particular, > this only

Re: [PATCH v3 4/4] seccomp: add support for passing fds via USER_NOTIF

2018-06-02 Thread Alban Crequy
On Thu, 31 May 2018 at 16:52, Tycho Andersen wrote: > > The idea here is that the userspace handler should be able to pass an fd > back to the trapped task, for example so it can be returned from socket(). > > I've proposed one API here, but I'm open to other options. In particular, > this only

Re: [PATCH v3 4/4] seccomp: add support for passing fds via USER_NOTIF

2018-06-02 Thread Tycho Andersen
Hi Jann, Thanks for taking a look! On Sat, Jun 02, 2018 at 03:13:39PM +0200, Jann Horn wrote: > On Sat, Jun 2, 2018 at 2:58 PM Tycho Andersen wrote: > > The idea here is that the userspace handler should be able to pass an fd > > back to the trapped task, for example so it can be returned from

Re: [PATCH v3 4/4] seccomp: add support for passing fds via USER_NOTIF

2018-06-02 Thread Tycho Andersen
Hi Jann, Thanks for taking a look! On Sat, Jun 02, 2018 at 03:13:39PM +0200, Jann Horn wrote: > On Sat, Jun 2, 2018 at 2:58 PM Tycho Andersen wrote: > > The idea here is that the userspace handler should be able to pass an fd > > back to the trapped task, for example so it can be returned from

Re: [PATCH v3 4/4] seccomp: add support for passing fds via USER_NOTIF

2018-06-02 Thread Jann Horn
On Sat, Jun 2, 2018 at 2:58 PM Tycho Andersen wrote: > The idea here is that the userspace handler should be able to pass an fd > back to the trapped task, for example so it can be returned from socket(). > > I've proposed one API here, but I'm open to other options. In particular, > this only

Re: [PATCH v3 4/4] seccomp: add support for passing fds via USER_NOTIF

2018-06-02 Thread Jann Horn
On Sat, Jun 2, 2018 at 2:58 PM Tycho Andersen wrote: > The idea here is that the userspace handler should be able to pass an fd > back to the trapped task, for example so it can be returned from socket(). > > I've proposed one API here, but I'm open to other options. In particular, > this only

[PATCH v3 4/4] seccomp: add support for passing fds via USER_NOTIF

2018-05-31 Thread Tycho Andersen
The idea here is that the userspace handler should be able to pass an fd back to the trapped task, for example so it can be returned from socket(). I've proposed one API here, but I'm open to other options. In particular, this only lets you return an fd from a syscall, which may not be enough in

[PATCH v3 4/4] seccomp: add support for passing fds via USER_NOTIF

2018-05-31 Thread Tycho Andersen
The idea here is that the userspace handler should be able to pass an fd back to the trapped task, for example so it can be returned from socket(). I've proposed one API here, but I'm open to other options. In particular, this only lets you return an fd from a syscall, which may not be enough in