/[linux-patches]/genpatches-2.6/trunk/2.6.11/1102_ptrace-check-segment.patch
Gentoo

Contents of /genpatches-2.6/trunk/2.6.11/1102_ptrace-check-segment.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 15 - (show annotations) (download) (as text)
Sat Jun 11 23:54:58 2005 UTC (15 years, 4 months ago) by dsd
File MIME type: text/x-diff
File size: 653 byte(s)
Two more x86_64 ptrace fixes
1 --- a/arch/x86_64/kernel/ptrace.c
2 +++ b/arch/x86_64/kernel/ptrace.c
3 @@ -257,13 +257,13 @@ static int putreg(struct task_struct *ch
4 value &= 0xffff;
5 return 0;
6 case offsetof(struct user_regs_struct,fs_base):
7 - if (!((value >> 48) == 0 || (value >> 48) == 0xffff))
8 - return -EIO;
9 + if (value >= TASK_SIZE)
10 + return -EIO;
11 child->thread.fs = value;
12 return 0;
13 case offsetof(struct user_regs_struct,gs_base):
14 - if (!((value >> 48) == 0 || (value >> 48) == 0xffff))
15 - return -EIO;
16 + if (value >= TASK_SIZE)
17 + return -EIO;
18 child->thread.gs = value;
19 return 0;
20 case offsetof(struct user_regs_struct, eflags):

  ViewVC Help
Powered by ViewVC 1.1.20