4 |
--- |
--- |
5 |
Makefile | 2 |
Makefile | 2 |
6 |
arch/alpha/kernel/ptrace.c | 8 +++ |
arch/alpha/kernel/ptrace.c | 8 +++ |
7 |
|
arch/ia64/ia32/sys_ia32.c | 8 +++ |
8 |
arch/ia64/kernel/ptrace.c | 8 +++ |
arch/ia64/kernel/ptrace.c | 8 +++ |
9 |
arch/m32r/kernel/ptrace.c | 8 +++ |
arch/m32r/kernel/ptrace.c | 8 +++ |
10 |
|
arch/mips/kernel/ptrace32.c | 8 +++ |
11 |
arch/powerpc/kernel/ptrace32.c | 8 +++ |
arch/powerpc/kernel/ptrace32.c | 8 +++ |
12 |
arch/s390/kernel/ptrace.c | 8 +++ |
arch/s390/kernel/ptrace.c | 8 +++ |
13 |
arch/sh64/kernel/ptrace.c | 8 +++ |
arch/sh64/kernel/ptrace.c | 8 +++ |
46 |
net/ipv6/inet6_hashtables.c | 6 ++ |
net/ipv6/inet6_hashtables.c | 6 ++ |
47 |
net/socket.c | 28 +++++++++++++ |
net/socket.c | 28 +++++++++++++ |
48 |
net/unix/af_unix.c | 10 ++++ |
net/unix/af_unix.c | 10 ++++ |
49 |
42 files changed, 511 insertions(+), 3 deletions(-) |
44 files changed, 527 insertions(+), 3 deletions(-) |
50 |
|
|
51 |
--- linux-2.6.21.orig/Makefile |
--- linux-2.6.21.orig/Makefile |
52 |
+++ linux-2.6.21/Makefile |
+++ linux-2.6.21/Makefile |
1480 |
|
|
1481 |
switch (request) { |
switch (request) { |
1482 |
case PTRACE_TRACEME: |
case PTRACE_TRACEME: |
1483 |
|
--- linux-2.6.21.orig/arch/ia64/ia32/sys_ia32.c |
1484 |
|
+++ linux-2.6.21/arch/ia64/ia32/sys_ia32.c |
1485 |
|
@@ -56,6 +56,9 @@ |
1486 |
|
#include <asm/types.h> |
1487 |
|
#include <asm/uaccess.h> |
1488 |
|
#include <asm/unistd.h> |
1489 |
|
+/***** TOMOYO Linux start. *****/ |
1490 |
|
+#include <linux/tomoyo.h> |
1491 |
|
+/***** TOMOYO Linux end. *****/ |
1492 |
|
|
1493 |
|
#include "ia32priv.h" |
1494 |
|
|
1495 |
|
@@ -1758,6 +1761,11 @@ sys32_ptrace (int request, pid_t pid, un |
1496 |
|
struct task_struct *child; |
1497 |
|
unsigned int value, tmp; |
1498 |
|
long i, ret; |
1499 |
|
+ /***** TOMOYO Linux start. *****/ |
1500 |
|
+#ifdef TOMOYO_SYS_PTRACE |
1501 |
|
+ if (CheckCapabilityACL(TOMOYO_SYS_PTRACE)) return -EPERM; |
1502 |
|
+#endif |
1503 |
|
+ /***** TOMOYO Linux end. *****/ |
1504 |
|
|
1505 |
|
lock_kernel(); |
1506 |
|
if (request == PTRACE_TRACEME) { |
1507 |
|
--- linux-2.6.21.orig/arch/mips/kernel/ptrace32.c |
1508 |
|
+++ linux-2.6.21/arch/mips/kernel/ptrace32.c |
1509 |
|
@@ -35,6 +35,9 @@ |
1510 |
|
#include <asm/system.h> |
1511 |
|
#include <asm/uaccess.h> |
1512 |
|
#include <asm/bootinfo.h> |
1513 |
|
+/***** TOMOYO Linux start. *****/ |
1514 |
|
+#include <linux/tomoyo.h> |
1515 |
|
+/***** TOMOYO Linux end. *****/ |
1516 |
|
|
1517 |
|
int ptrace_getregs (struct task_struct *child, __s64 __user *data); |
1518 |
|
int ptrace_setregs (struct task_struct *child, __s64 __user *data); |
1519 |
|
@@ -50,6 +53,11 @@ asmlinkage int sys32_ptrace(int request, |
1520 |
|
{ |
1521 |
|
struct task_struct *child; |
1522 |
|
int ret; |
1523 |
|
+ /***** TOMOYO Linux start. *****/ |
1524 |
|
+#ifdef TOMOYO_SYS_PTRACE |
1525 |
|
+ if (CheckCapabilityACL(TOMOYO_SYS_PTRACE)) return -EPERM; |
1526 |
|
+#endif |
1527 |
|
+ /***** TOMOYO Linux end. *****/ |
1528 |
|
|
1529 |
|
#if 0 |
1530 |
|
printk("ptrace(r=%d,pid=%d,addr=%08lx,data=%08lx)\n", |