sandboxed-api/sandboxed_api
Christian Blichmann 9c21744460 Revert memfd file sealing for embeded files
Ideally, we'd seal the embedded SAPI binary using fcntl(). However, in rare
cases, adding the file seals `F_SEAL_SEAL | F_SEAL_SHRINK | F_SEAL_GROW |
F_SEAL_WRITE` results in `EBUSY` errors.

This is likely because of an interaction of `SEAL_WRITE` with pending writes
to the mapped memory region (see `memfd_wait_for_pins()` in Linux'
`mm/memfd.c`). Since `fsync()` is a no-op on memfds, it doesn't help to
ameliorate the problem.

On systems where it is enabled, ksmd might also be a source of pending writes.

PiperOrigin-RevId: 385741435
Change-Id: I21bd6a9039be4b6298774e837ce3628180ed91a8
2021-07-20 02:29:21 -07:00
..
2021-04-26 05:00:30 -07:00
2020-03-19 09:58:28 -07:00
2021-07-14 08:00:59 -07:00
2021-04-13 01:44:01 -07:00
2021-04-13 01:44:01 -07:00
2021-04-13 01:44:01 -07:00
2021-05-20 08:17:10 -07:00
2021-07-14 08:00:59 -07:00
2020-09-03 07:40:33 -07:00
2021-07-14 08:00:59 -07:00
2021-01-22 06:01:34 -08:00
2021-01-22 06:01:34 -08:00
2021-01-22 06:01:34 -08:00
2020-07-20 03:07:54 -07:00
2021-01-22 06:01:34 -08:00
2021-01-22 06:01:34 -08:00
2021-01-22 06:01:34 -08:00
2021-04-13 01:44:01 -07:00
2020-07-20 03:07:54 -07:00