/external/selinux/python/sepolgen/tests/ |
D | test_refpolicy.py | 21 import sepolgen.refpolicy as refpolicy namespace 27 s = refpolicy.IdSet(["read", "write", "getattr"]) 33 s = refpolicy.IdSet() 40 s1 = refpolicy.XpermSet() 44 s2 = refpolicy.XpermSet(True) 51 s = refpolicy.XpermSet() 68 s = refpolicy.XpermSet() 76 a = refpolicy.XpermSet() 79 b = refpolicy.XpermSet() 87 a = refpolicy.XpermSet() [all …]
|
D | test_policygen.py | 23 import sepolgen.refpolicy as refpolicy namespace 57 self.assertIsInstance(r, refpolicy.AVRule) 67 av1.xperms['ioctl'] = refpolicy.XpermSet() 70 av2.xperms['ioctl'] = refpolicy.XpermSet() 73 av3.xperms['ioctl'] = refpolicy.XpermSet() 89 if isinstance(r, refpolicy.AVRule): 94 elif isinstance(r, refpolicy.AVExtRule): 116 xp1 = refpolicy.XpermSet() 132 xp2 = refpolicy.XpermSet()
|
D | test_interfaces.py | 25 import sepolgen.refpolicy as refpolicy namespace 34 self.assertEqual(p.type, refpolicy.SRC_TYPE) 49 self.assertEqual(p.type, refpolicy.SRC_TYPE) 50 self.assertEqual(p.obj_classes, refpolicy.IdSet(["file"])) 59 self.assertEqual(p.type, refpolicy.SRC_TYPE) 60 self.assertEqual(p.obj_classes, refpolicy.IdSet(["process"])) 69 self.assertEqual(p.type, refpolicy.SRC_TYPE) 70 self.assertEqual(p.obj_classes, refpolicy.IdSet(["dir"])) 79 self.assertEqual(p.type, refpolicy.TGT_TYPE) 80 self.assertEqual(p.obj_classes, refpolicy.IdSet(["dir"])) [all …]
|
D | test_access.py | 21 import sepolgen.refpolicy as refpolicy namespace 33 self.assertTrue(isinstance(a.perms, refpolicy.IdSet)) 144 b.perms = refpolicy.IdSet(["read"]) 148 b.perms = refpolicy.IdSet(["read", "write", "append"]) 151 b.perms = refpolicy.IdSet(["read", "append"]) 166 xp = refpolicy.XpermSet() 179 xp = refpolicy.XpermSet() 193 xp1 = refpolicy.XpermSet() 198 xp2 = refpolicy.XpermSet() 212 xp1 = refpolicy.XpermSet() [all …]
|
D | test_module.py | 28 mc.create_module_package("module_compile_test.te", refpolicy=True) 32 mc.refpolicy = True 33 mc.create_module_package("module_compile_test.te", refpolicy=False)
|
D | test_refparser.py | 22 import sepolgen.refpolicy as refpolicy namespace
|
D | test_audit.py | 22 import sepolgen.refpolicy 74 sc = sepolgen.refpolicy.SecurityContext()
|
/external/selinux/python/sepolgen/src/sepolgen/ |
D | refparser.py | 40 from . import refpolicy 354 m = refpolicy.ModuleDeclaration() 357 m.refpolicy = True 363 x = refpolicy.Interface(p[4]) 371 x = refpolicy.Template(p[4]) 402 o = refpolicy.OptionalPolicy() 412 x = refpolicy.TunablePolicy() 438 x = refpolicy.IfDef(p[4]) 453 i = refpolicy.InterfaceCall(ifname=p[1]) 485 s = refpolicy.ObjPermSet(p[4]) [all …]
|
D | policygen.py | 33 from . import refpolicy 83 self.module = refpolicy.Module() 133 refpolicy = True 135 refpolicy = False 137 mod.refpolicy = refpolicy 147 m = refpolicy.ModuleDeclaration() 152 m.refpolicy = True 154 m.refpolicy = False 167 rule = refpolicy.AVRule(av) 173 rule.comment = str(refpolicy.Comment(explain_access(av, verbosity=self.explain))) [all …]
|
D | output.py | 30 from . import refpolicy 51 for node, depth in refpolicy.walktree(self.module, showdepth=True): 97 if isinstance(a, refpolicy.InterfaceCall): 98 if isinstance(b, refpolicy.InterfaceCall): 103 if isinstance(b, refpolicy.AVRule): 120 c.append(refpolicy.Comment()) 125 c.append(refpolicy.Comment()) 139 if isinstance(rule, refpolicy.InterfaceCall): 146 sep_rules.append(refpolicy.Comment()) 148 comment = refpolicy.Comment() [all …]
|
D | interfaces.py | 28 from . import refpolicy 40 self.type = refpolicy.SRC_TYPE 41 self.obj_classes = refpolicy.IdSet() 58 (self.name, refpolicy.field_to_str[self.type], " ".join(self.obj_classes)) 70 if (type == refpolicy.SRC_TYPE or type == refpolicy.TGT_TYPE) and \ 71 (p.type == refpolicy.TGT_TYPE or p.type == refpolicy.SRC_TYPE): 88 p.type = refpolicy.SRC_TYPE 145 if __param_insert(av.src_type, refpolicy.SRC_TYPE, av, params) == 1: 149 if __param_insert(av.tgt_type, refpolicy.TGT_TYPE, av, params) == 1: 153 if __param_insert(av.obj_class, refpolicy.OBJ_CLASS, av, params) == 1: [all …]
|
D | audit.py | 23 from . import refpolicy 173 self.scontext = refpolicy.SecurityContext() 174 self.tcontext = refpolicy.SecurityContext() 228 self.scontext = refpolicy.SecurityContext(fields[1]) 231 self.tcontext = refpolicy.SecurityContext(fields[1]) 315 self.invalid_context = refpolicy.SecurityContext() 316 self.scontext = refpolicy.SecurityContext() 317 self.tcontext = refpolicy.SecurityContext() 326 self.invalid_context = refpolicy.SecurityContext(recs[5]) 327 self.scontext = refpolicy.SecurityContext(recs[7].split("=")[1]) [all …]
|
D | access.py | 34 from . import refpolicy 90 self.perms = refpolicy.IdSet() 123 self.perms = refpolicy.IdSet(list[3:]) 143 self.xperms[op] = refpolicy.XpermSet() 299 types = refpolicy.IdSet() 312 s = refpolicy.IdSet() 340 role_type = refpolicy.RoleType()
|
D | module.py | 158 def create_module_package(self, sourcename, refpolicy=True): argument 174 if refpolicy:
|
D | refpolicy.py | 697 self.refpolicy = False 700 if self.refpolicy:
|
/external/selinux/libsepol/tests/ |
D | Makefile | 51 …../../checkpolicy/checkpolicy -M policies/test-cond/refpolicy-base.conf -o policies/test-downgrade…
|
/external/selinux/python/audit2allow/ |
D | audit2allow | 234 mc.create_module_package(filename, self.__options.refpolicy) 320 if self.__options.refpolicy:
|
D | audit2why | 234 mc.create_module_package(filename, self.__options.refpolicy) 320 if self.__options.refpolicy:
|
/external/selinux/python/sepolgen/ |
D | HACKING | 17 Reference Policy Representation (sepolgen.refpolicy)
|