mirror of
https://github.com/storytold/gridcraft.git
synced 2026-11-15 14:36:55 +00:00
The merged test asserts FIOSETOWN and FIOASYNC with the ioctl argument passed by value, where the kernel reads the number as an address and fails with EFAULT whether or not the filter refuses it, so the refusal alone is not the reason the call came back. Passing a pointer, as a C caller does, the call succeeds unconfined and is EPERM confined. This covers FIOSETOWN and SIOCSPGRP that way on a socket the parent made and the program inherited as a standard stream, after reading its socket name so a pipe cannot pass for one. SIOCSPGRP is in the rules and in the filter's count assertion but in no test until now. Deleting either rule line fails this test at that ioctl's assertion; restored, it passes. The test above is untouched.