Date: Fri, 28 Mar 2025 15:16:52 +0300 From: Gleb Popov <arrowd@freebsd.org> To: freebsd-hackers <freebsd-hackers@freebsd.org> Subject: Re: Would we want pidfd_open(2) & SO_PEERPIDFD? Message-ID: <CALH631kDAF2rTKwL3BfCTL7_0M6JfXqSNebuFJhbRKpdCPH_JQ@mail.gmail.com> In-Reply-To: <CALH631=582=rpqCaR6FQTF_4C88NRf%2BLGnZR3fAynVvuNNWheA@mail.gmail.com> References: <CALH631mgztNmngL1Hffbbcf0n-kLZP-2YmsMLJ8Xi33HV8uuvw@mail.gmail.com> <Z6udhDuj4uBjNUsM@kib.kiev.ua> <CALH631=7MnCAe67yPqG%2BAJfy_CPxf3HUxsfeVvgmiTEXEy27Bg@mail.gmail.com> <Z6wuyS4uBQJbCG-c@kib.kiev.ua> <CALH631m7DZKOLkjn4Z9z7arE9xwfEEjaGVSO=5KyHJ=iZ8o9Qw@mail.gmail.com> <Z9BR90ijwniJr2IJ@kib.kiev.ua> <CALH631mhpv7tzr1vhNgF2Hs6=ynSrMeuP1=NeXU63FEAmfUwRw@mail.gmail.com> <Z-I5Vwb3383R6UZs@kib.kiev.ua> <CALH631=582=rpqCaR6FQTF_4C88NRf%2BLGnZR3fAynVvuNNWheA@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Mar 25, 2025 at 8:27 AM Gleb Popov <arrowd@freebsd.org> wrote: > > The high level code expects a descriptor with some properties, so we > either provide it or have to patch large parts of the code using it. > Emulating pidfd somehow is also fine to me, but I have no idea how to > do that. libinotify-kqueue example shows that emulating a descriptor > with certain properties is quite a non-trivial task. A bit orthogonal to the Capsicum discussion, I wonder if the following idea makes sense: We do have FUSE as a framework to implement filesystems from the userspace, same goes for CUSE that allows for programming character devices. Maybe having some sort of FDUSE providing a way to create "custom" descriptors and define their behaviour from userspace would be useful?
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CALH631kDAF2rTKwL3BfCTL7_0M6JfXqSNebuFJhbRKpdCPH_JQ>
