From 15ab63956560f4d994d3d22478d8877d98cc46e6 Mon Sep 17 00:00:00 2001 From: Adrian Szyndela Date: Tue, 14 Aug 2018 15:54:50 +0200 Subject: [PATCH] policychecker: modified 'Unconstrained allow' rule Unconstrained allow rule was reporting any allow in context default or mandatory. Now, it reports those rules in both contexts that: - allow send_type='method_call' but do not specify destination and interface; - allow send_path but do not specify destination; - allow receive_type='method_call' but do not specify sender and interface; - allow receive_path but do not specify sender. Additionally, in user and group context send_destination is required when send_type="method_call" or send_path is present, and receive_sender is required when receive_type="method_call" or receive_path is present. Change-Id: Icd822bf4b3e2f105a07e80ca61415410faaeb00a --- policychecker/rules.xsl | 30 +++++++++++++++++++++++++++--- 1 file changed, 27 insertions(+), 3 deletions(-) diff --git a/policychecker/rules.xsl b/policychecker/rules.xsl index f159b6f..8a8d3f4 100644 --- a/policychecker/rules.xsl +++ b/policychecker/rules.xsl @@ -27,9 +27,33 @@ - - - Unconstrained allows are not allowed in context default and context mandatory. + + + Unconstrained allows are not allowed in context default and context mandatory: missing send_destination, but send_type="method_call" is present. + Unconstrained allows are not allowed in context default and context mandatory: missing send_interface, but send_type="method_call" is present. + + + Unconstrained allows are not allowed in context default and context mandatory: missing send_destination, but send_path is present. + + + Unconstrained allows are not allowed in context default and context mandatory: missing receive_sender, but receive_type="method_call" is present. + Unconstrained allows are not allowed in context default and context mandatory: missing receive_interface, but receive_type="method_call" is present. + + + Unconstrained allows are not allowed in context default and context mandatory: missing receive_sender, but receive_path is present. + + + + Unconstrained allows are not allowed in user or group context: missing send_destination, but send_type="method_call" is present. + + + Unconstrained allows are not allowed in user or group context: missing send_destination, but send_path is present. + + + Unconstrained allows are not allowed in user or group context: missing receive_sender, but receive_type="method_call" is present. + + + Unconstrained allows are not allowed in user or group context: missing receive_sender, but receive_path is present. -- 2.34.1