オープンソース・ソフトウェアの開発とダウンロード

Subversion リポジトリの参照

Diff of /trunk/1.8.x/ccs-patch/patches/ccs-patch-2.6.16-vine-linux-4.2.diff

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2805 by kumaneko, Mon Jul 27 02:00:55 2009 UTC revision 2851 by kumaneko, Wed Aug 5 04:58:04 2009 UTC
# Line 32  Source code for this patch is http://upd Line 32  Source code for this patch is http://upd
32   kernel/module.c                 |    7 +++++--   kernel/module.c                 |    7 +++++--
33   kernel/ptrace.c                 |    3 +++   kernel/ptrace.c                 |    3 +++
34   kernel/sched.c                  |    3 +++   kernel/sched.c                  |    3 +++
35   kernel/signal.c                 |   13 +++++++++++++   kernel/signal.c                 |    7 +++++++
36   kernel/sys.c                    |   11 +++++++++++   kernel/sys.c                    |   11 +++++++++++
37   kernel/sysctl.c                 |   11 +++++++++++   kernel/sysctl.c                 |   11 +++++++++++
38   kernel/time.c                   |    7 +++++++   kernel/time.c                   |    7 +++++++
# Line 45  Source code for this patch is http://upd Line 45  Source code for this patch is http://upd
45   net/ipv6/udp.c                  |    9 +++++++++   net/ipv6/udp.c                  |    9 +++++++++
46   net/socket.c                    |   26 +++++++++++++++++++++++---   net/socket.c                    |   26 +++++++++++++++++++++++---
47   net/unix/af_unix.c              |    4 ++++   net/unix/af_unix.c              |    4 ++++
48   43 files changed, 288 insertions(+), 11 deletions(-)   43 files changed, 282 insertions(+), 11 deletions(-)
49    
50  --- linux-2.6.16-76.49vl4.orig/arch/alpha/kernel/ptrace.c  --- linux-2.6.16-76.49vl4.orig/arch/alpha/kernel/ptrace.c
51  +++ linux-2.6.16-76.49vl4/arch/alpha/kernel/ptrace.c  +++ linux-2.6.16-76.49vl4/arch/alpha/kernel/ptrace.c
# Line 693  Source code for this patch is http://upd Line 693  Source code for this patch is http://upd
693          if (entry)          if (entry)
694                  entry->proc_fops = &proc_sysrq_trigger_operations;                  entry->proc_fops = &proc_sysrq_trigger_operations;
695   #endif   #endif
696  +       printk(KERN_INFO "Hook version: 2.6.16-76.49vl4 2009/07/23\n");  +       printk(KERN_INFO "Hook version: 2.6.16-76.49vl4 2009/08/05\n");
697   }   }
698  --- linux-2.6.16-76.49vl4.orig/include/linux/init_task.h  --- linux-2.6.16-76.49vl4.orig/include/linux/init_task.h
699  +++ linux-2.6.16-76.49vl4/include/linux/init_task.h  +++ linux-2.6.16-76.49vl4/include/linux/init_task.h
# Line 854  Source code for this patch is http://upd Line 854  Source code for this patch is http://upd
854    
855   /*   /*
856    * SLAB caches for signal bits.    * SLAB caches for signal bits.
857  @@ -2336,6 +2337,10 @@ asmlinkage long  @@ -2336,6 +2337,8 @@ asmlinkage long
858   sys_kill(int pid, int sig)   sys_kill(int pid, int sig)
859   {   {
860          struct siginfo info;          struct siginfo info;
861  +       if (sig && !ccs_capable(CCS_SYS_KILL))  +       if (ccs_kill_permission(pid, sig))
 +               return -EPERM;  
 +       if (sig && ccs_check_signal_acl(sig, pid))  
862  +               return -EPERM;  +               return -EPERM;
863    
864          info.si_signo = sig;          info.si_signo = sig;
865          info.si_errno = 0;          info.si_errno = 0;
866  @@ -2394,6 +2399,10 @@ asmlinkage long sys_tgkill(int tgid, int  @@ -2394,6 +2397,8 @@ asmlinkage long sys_tgkill(int tgid, int
867          /* This is only valid for single tasks */          /* This is only valid for single tasks */
868          if (pid <= 0 || tgid <= 0)          if (pid <= 0 || tgid <= 0)
869                  return -EINVAL;                  return -EINVAL;
870  +       if (sig && !ccs_capable(CCS_SYS_KILL))  +       if (ccs_tgkill_permission(tgid, pid, sig))
 +               return -EPERM;  
 +       if (sig && ccs_check_signal_acl(sig, pid))  
871  +               return -EPERM;  +               return -EPERM;
872    
873          return do_tkill(tgid, pid, sig);          return do_tkill(tgid, pid, sig);
874   }   }
875  @@ -2407,6 +2416,10 @@ sys_tkill(int pid, int sig)  @@ -2407,6 +2412,8 @@ sys_tkill(int pid, int sig)
876          /* This is only valid for single tasks */          /* This is only valid for single tasks */
877          if (pid <= 0)          if (pid <= 0)
878                  return -EINVAL;                  return -EINVAL;
879  +       if (sig && !ccs_capable(CCS_SYS_KILL))  +       if (ccs_tkill_permission(pid, sig))
 +               return -EPERM;  
 +       if (sig && ccs_check_signal_acl(sig, pid))  
880  +               return -EPERM;  +               return -EPERM;
881    
882          return do_tkill(0, pid, sig);          return do_tkill(0, pid, sig);

Legend:
Removed from v.2805  
changed lines
  Added in v.2851

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26