File paths?
File paths?
Posted Jun 4, 2018 21:37 UTC (Mon) by wahern (subscriber, #37304)In reply to: File paths? by Cyberax
Parent article: Deferring seccomp decisions to user space
Isn't that susceptible to a race condition? systrace (https://en.wikipedia.org/wiki/Systrace) never saw widespread adoption exactly because of the race condition, both on Linux and on OpenBSD (with an in-kernel implementation). The TOCTTOU race is that a signal handler or thread changes the path between the check and the actual open.
The solution is to copy the path or otherwise make it immutable. That's costly and it's why the the seccomp BPF filter originally didn't support processing the file path string. Has that changed?
