Skip to contentSkip to conversation

Fix hierarchy checking on type rules

PATCH In review Joshua Brindle 2 participants 2 messages Jul 14, 2005 – Jul 18, 2005 SELinux security module

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Fix hierarchy checking on type rules

Currently the hierarchy checker will incorrectly try to check type rules, this patch fixes that.

src/hierarchy.c 14 Jul 2005 15:29:16 -0000 renamed from src/hierarchy.c 6 Jul 2005 17:45:07 -0000 1.4 +5 -0
diff -u -r1.4 hierarchy.c
@@ -127,6 +127,11 @@
        uint32_t av;
        type_datum_t *t = NULL, *t2 = NULL;
 
+       if (!d->specified & AVTAB_AV) {
+               /* This is a type rule, no checking done */
+               return 0;
+       }
+
        a = (hierarchy_args_t *)args;
        if (find_parent(a->p->p_type_val_to_name[k->source_type - 1],

&parent))

                return -1;

--
This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.

#1 lore raw
Quoted 2 lines · Joshua Brindle

Currently the hierarchy checker will incorrectly try to check type rules, this patch fixes that.

Corrected patch merged.

Signature · 8 lines
Stephen Smalley
National Security Agency


--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to [email protected] with
the words "unsubscribe selinux" without quotes as the message.