aboutsummaryrefslogtreecommitdiffstats
path: root/security/dummy.c
diff options
context:
space:
mode:
authorDavid Quigley <dpquigl@tycho.nsa.gov>2006-06-23 05:04:01 -0400
committerLinus Torvalds <torvalds@g5.osdl.org>2006-06-23 10:42:54 -0400
commit35601547baf92d984b6e59cf3583649da04baea5 (patch)
treea392501e6e004ed33789dbf3f7a9fe43295439e1 /security/dummy.c
parent22fb52dd736a62e24c44c50739007496265dc38c (diff)
[PATCH] SELinux: add task_movememory hook
This patch adds new security hook, task_movememory, to be called when memory owened by a task is to be moved (e.g. when migrating pages to a this hook is identical to the setscheduler implementation, but a separate hook introduced to allow this check to be specialized in the future if necessary. Since the last posting, the hook has been renamed following feedback from Christoph Lameter. Signed-off-by: David Quigley <dpquigl@tycho.nsa.gov> Acked-by: Stephen Smalley <sds@tycho.nsa.gov> Signed-off-by: James Morris <jmorris@namei.org> Cc: Christoph Lameter <clameter@sgi.com> Cc: Andi Kleen <ak@muc.de> Acked-by: Chris Wright <chrisw@sous-sol.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'security/dummy.c')
-rw-r--r--security/dummy.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/security/dummy.c b/security/dummy.c
index 879a98523b1b..c3c5493581e2 100644
--- a/security/dummy.c
+++ b/security/dummy.c
@@ -537,6 +537,11 @@ static int dummy_task_getscheduler (struct task_struct *p)
537 return 0; 537 return 0;
538} 538}
539 539
540static int dummy_task_movememory (struct task_struct *p)
541{
542 return 0;
543}
544
540static int dummy_task_wait (struct task_struct *p) 545static int dummy_task_wait (struct task_struct *p)
541{ 546{
542 return 0; 547 return 0;
@@ -981,6 +986,7 @@ void security_fixup_ops (struct security_operations *ops)
981 set_to_dummy_if_null(ops, task_setrlimit); 986 set_to_dummy_if_null(ops, task_setrlimit);
982 set_to_dummy_if_null(ops, task_setscheduler); 987 set_to_dummy_if_null(ops, task_setscheduler);
983 set_to_dummy_if_null(ops, task_getscheduler); 988 set_to_dummy_if_null(ops, task_getscheduler);
989 set_to_dummy_if_null(ops, task_movememory);
984 set_to_dummy_if_null(ops, task_wait); 990 set_to_dummy_if_null(ops, task_wait);
985 set_to_dummy_if_null(ops, task_kill); 991 set_to_dummy_if_null(ops, task_kill);
986 set_to_dummy_if_null(ops, task_prctl); 992 set_to_dummy_if_null(ops, task_prctl);