Alistair Delva
cc73242889
block: Check ADMIN before NICE for IOPRIO_CLASS_RT
...
commit 94c4b4fd25e6c3763941bdec3ad54f2204afa992 upstream.
Booting to Android userspace on 5.14 or newer triggers the following
SELinux denial:
avc: denied { sys_nice } for comm="init" capability=23
scontext=u:r:init:s0 tcontext=u:r:init:s0 tclass=capability
permissive=0
Init is PID 0 running as root, so it already has CAP_SYS_ADMIN. For
better compatibility with older SEPolicy, check ADMIN before NICE.
Fixes: 9d3a39a5f1e4 ("block: grant IOPRIO_CLASS_RT to CAP_SYS_NICE")
Signed-off-by: Alistair Delva <adelva@google.com>
Cc: Khazhismel Kumykov <khazhy@google.com>
Cc: Bart Van Assche <bvanassche@acm.org>
Cc: Serge Hallyn <serge@hallyn.com>
Cc: Jens Axboe <axboe@kernel.dk>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Paul Moore <paul@paul-moore.com>
Cc: selinux@vger.kernel.org
Cc: linux-security-module@vger.kernel.org
Cc: kernel-team@android.com
Cc: stable@vger.kernel.org # v5.14+
Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Acked-by: Serge Hallyn <serge@hallyn.com>
Link: https://lore.kernel.org/r/20211115181655.3608659-1-adelva@google.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-11-26 10:39:19 +01:00
..
2021-07-20 16:05:39 +02:00
2020-08-23 17:36:59 -05:00
2020-08-18 07:48:08 -07:00
2021-10-06 15:55:56 +02:00
2020-08-18 07:48:08 -07:00
2020-08-18 07:48:08 -07:00
2020-07-02 12:38:18 -06:00
2021-09-15 09:50:47 +02:00
2021-03-30 14:31:48 +02:00
2019-11-07 12:28:13 -07:00
2021-09-30 10:11:07 +02:00
2021-11-26 10:39:13 +01:00
2020-07-01 07:27:24 -06:00
2020-10-05 10:47:43 -06:00
2021-09-15 09:50:30 +02:00
2020-05-27 05:21:23 -06:00
2021-09-12 08:58:27 +02:00
2021-09-30 10:11:06 +02:00
2020-07-16 10:22:15 -06:00
2021-09-03 10:09:22 +02:00
2021-08-12 13:22:08 +02:00
2020-09-25 08:18:57 -06:00
2020-09-23 09:18:39 -06:00
2021-09-15 09:50:28 +02:00
2020-10-20 07:08:17 -06:00
2019-01-17 21:21:40 -07:00
2021-10-27 09:56:46 +02:00
2019-06-13 03:00:30 -06:00
2019-05-31 15:12:34 -06:00
2019-05-31 15:12:34 -06:00
2021-09-30 10:11:04 +02:00
2020-10-13 12:12:44 -07:00
2020-10-09 12:46:28 -06:00
2021-09-30 10:11:05 +02:00
2021-07-14 16:55:58 +02:00
2020-03-17 20:55:21 +01:00
2021-11-18 14:03:58 +01:00
2021-07-14 16:55:58 +02:00
2021-01-06 14:56:50 +01:00
2021-01-12 20:18:17 +01:00
2021-07-19 09:45:00 +02:00
2021-07-14 16:56:00 +02:00
2021-03-04 11:38:22 +01:00
2020-09-01 16:48:46 -06:00
2018-12-12 06:47:51 -07:00
2020-10-09 12:46:28 -06:00
2021-09-26 14:09:01 +02:00
2020-07-31 16:29:47 -06:00
2021-07-14 16:56:12 +02:00
2021-07-14 16:56:12 +02:00
2021-09-18 13:40:06 +02:00
2021-11-18 14:03:57 +01:00
2020-10-05 10:47:43 -06:00
2020-09-23 09:18:13 -06:00
2021-09-18 13:40:11 +02:00
2017-11-02 11:10:55 +01:00
2021-09-15 09:50:28 +02:00
2021-03-30 14:31:52 +02:00
2021-04-28 13:39:59 +02:00
2021-11-26 10:39:19 +01:00
2020-09-01 16:49:26 -06:00
2020-06-14 01:57:21 +09:00
2020-11-20 11:52:52 -07:00
2021-05-19 10:13:13 +02:00
2020-06-24 09:15:56 -06:00
2021-09-15 09:50:28 +02:00
2020-03-12 08:00:10 -06:00
2020-10-13 13:04:41 -07:00
2020-03-12 08:00:10 -06:00
2020-01-06 20:59:04 -07:00