gecko-dev/ipc
Jed Davis 3680ce4b19 Bug 1440203 - Support memfd_create in IPC shared memory. r=glandium
This commit also allows `memfd_create` in the seccomp-bpf policy for all
process types.

`memfd_create` is an API added in Linux 3.17 (and adopted by FreeBSD
for the upcoming version 13) for creating anonymous shared memory
not connected to any filesystem.  Supporting it means that sandboxed
child processes on Linux can create shared memory directly instead of
messaging a broker, which is unavoidably slower, and it should avoid
the problems we'd been seeing with overly small `/dev/shm` in container
environments (which were causing serious problems for using Firefox for
automated testing of frontend projects).

`memfd_create` also introduces the related operation of file seals:
irrevocably preventing types of modifications to a file.  Unfortunately,
the most useful one, `F_SEAL_WRITE`, can't be relied on; see the large
comment in `SharedMemory:ReadOnlyCopy` for details.  So we still use
the applicable seals as defense in depth, but read-only copies are
implemented on Linux by using procfs (and see the comments on the
`ReadOnlyCopy` function in `shared_memory_posix.cc` for the subtleties
there).

There's also a FreeBSD implementation, using `cap_rights_limit` for
read-only copies, if the build host is new enough to have the
`memfd_create` function.

Differential Revision: https://phabricator.services.mozilla.com/D90605
2020-10-08 02:25:20 +00:00
..
app Bug 1634765: Drop support for (and prevent from running on) macOS versions below 10.12. r=haik 2020-06-11 19:28:25 +00:00
chromium Bug 1440203 - Support memfd_create in IPC shared memory. r=glandium 2020-10-08 02:25:20 +00:00
contentproc
glue Bug 1658416 - Allow gamepad test channel to observe gamepad monitoring state r=handyman 2020-10-07 17:25:26 +00:00
gtest Bug 1654379 - Allow filtering the IPC log by multiple toplevel protocol names. r=nika 2020-07-23 17:47:39 +00:00
ipdl Bug 1661760 - Part 1: Unify all range from offset methods to one. r=morgan,nika 2020-09-24 16:04:41 +00:00
mscom Bug 1657033 - Use Span<const char> in JSONWriter - r=froydnj 2020-09-14 02:33:20 +00:00
testshell Bug 1650145 - Replace all value uses of Empty[C]String by 0-length _ns literals. r=froydnj,geckoview-reviewers,agi 2020-09-23 15:17:15 +00:00
moz.build
pull-chromium.py