From 3b728a53fd2d3cd3009f5740bbbc21cda7d28a5a Mon Sep 17 00:00:00 2001 From: Michael LeMay Date: Tue, 27 Jun 2006 02:53:42 -0700 Subject: [PATCH] --- yaml --- r: 30735 b: refs/heads/master c: 28eba5bf9d4bf3ba4d58d985abf3a2903b7f2125 h: refs/heads/master i: 30733: 63f4a2af2c072d62ec95d93d02f8e238d6d51d16 30731: 48af54385eb08c8afc66916706aa55c156a0cd0a 30727: 04ad84e298788c65fc910f5baba35e7b03fb39dd 30719: 9991833e64508655770c042b36e7664ece7b545d v: v3 --- [refs] | 2 +- trunk/security/selinux/hooks.c | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index 6257f33836e5..7135dd5f7f20 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 76b67ed9dce69a6a329cdd66f94af1787f417b62 +refs/heads/master: 28eba5bf9d4bf3ba4d58d985abf3a2903b7f2125 diff --git a/trunk/security/selinux/hooks.c b/trunk/security/selinux/hooks.c index ac7f2b2e3924..28832e689800 100644 --- a/trunk/security/selinux/hooks.c +++ b/trunk/security/selinux/hooks.c @@ -1532,8 +1532,9 @@ static int selinux_bprm_set_security(struct linux_binprm *bprm) /* Default to the current task SID. */ bsec->sid = tsec->sid; - /* Reset create and sockcreate SID on execve. */ + /* Reset fs, key, and sock SIDs on execve. */ tsec->create_sid = 0; + tsec->keycreate_sid = 0; tsec->sockcreate_sid = 0; if (tsec->exec_sid) { @@ -2586,9 +2587,10 @@ static int selinux_task_alloc_security(struct task_struct *tsk) tsec2->osid = tsec1->osid; tsec2->sid = tsec1->sid; - /* Retain the exec, create, and sock SIDs across fork */ + /* Retain the exec, fs, key, and sock SIDs across fork */ tsec2->exec_sid = tsec1->exec_sid; tsec2->create_sid = tsec1->create_sid; + tsec2->keycreate_sid = tsec1->keycreate_sid; tsec2->sockcreate_sid = tsec1->sockcreate_sid; /* Retain ptracer SID across fork, if any.