Re: [PATCH v3 3/7] kprobes: validate the symbol name length

2017-04-24 Thread Masami Hiramatsu
On Sun, 23 Apr 2017 15:44:32 + "Naveen N. Rao" wrote: > >> >> +bool is_valid_kprobe_symbol_name(const char *name) > >> > > >> > This just check the length of symbol_name buffer, and can contain > >> > some invalid chars. > >> > >> Yes, I kept the function name generic incase we would like t

Re: [PATCH v3 3/7] kprobes: validate the symbol name length

2017-04-23 Thread Naveen N. Rao
Excerpts from Masami Hiramatsu's message of April 21, 2017 19:12: On Wed, 19 Apr 2017 16:38:22 + "Naveen N. Rao" wrote: Excerpts from Masami Hiramatsu's message of April 19, 2017 20:07: > On Wed, 19 Apr 2017 18:21:02 +0530 > "Naveen N. Rao" wrote: > >> When a kprobe is being registered,

Re: [PATCH v3 3/7] kprobes: validate the symbol name length

2017-04-21 Thread Masami Hiramatsu
On Wed, 19 Apr 2017 16:38:22 + "Naveen N. Rao" wrote: > Excerpts from Masami Hiramatsu's message of April 19, 2017 20:07: > > On Wed, 19 Apr 2017 18:21:02 +0530 > > "Naveen N. Rao" wrote: > > > >> When a kprobe is being registered, we use the symbol_name field to > >> lookup the address whe

Re: [PATCH v3 3/7] kprobes: validate the symbol name length

2017-04-20 Thread Naveen N. Rao
Excerpts from Michael Ellerman's message of April 20, 2017 11:38: "Naveen N. Rao" writes: diff --git a/kernel/kprobes.c b/kernel/kprobes.c index 6a128f3a7ed1..bb86681c8a10 100644 --- a/kernel/kprobes.c +++ b/kernel/kprobes.c @@ -1382,6 +1382,28 @@ bool within_kprobe_blacklist(unsigned long add

Re: [PATCH v3 3/7] kprobes: validate the symbol name length

2017-04-19 Thread Michael Ellerman
"Naveen N. Rao" writes: > diff --git a/kernel/kprobes.c b/kernel/kprobes.c > index 6a128f3a7ed1..bb86681c8a10 100644 > --- a/kernel/kprobes.c > +++ b/kernel/kprobes.c > @@ -1382,6 +1382,28 @@ bool within_kprobe_blacklist(unsigned long addr) > return false; > } > > +bool is_valid_kprobe_s

Re: [PATCH v3 3/7] kprobes: validate the symbol name length

2017-04-19 Thread Naveen N. Rao
Excerpts from Masami Hiramatsu's message of April 19, 2017 20:07: On Wed, 19 Apr 2017 18:21:02 +0530 "Naveen N. Rao" wrote: When a kprobe is being registered, we use the symbol_name field to lookup the address where the probe should be placed. Since this is a user-provided field, let's ensure

Re: [PATCH v3 3/7] kprobes: validate the symbol name length

2017-04-19 Thread Masami Hiramatsu
On Wed, 19 Apr 2017 18:21:02 +0530 "Naveen N. Rao" wrote: > When a kprobe is being registered, we use the symbol_name field to > lookup the address where the probe should be placed. Since this is a > user-provided field, let's ensure that the length of the string is > within expected limits. Wou

[PATCH v3 3/7] kprobes: validate the symbol name length

2017-04-19 Thread Naveen N. Rao
When a kprobe is being registered, we use the symbol_name field to lookup the address where the probe should be placed. Since this is a user-provided field, let's ensure that the length of the string is within expected limits. Signed-off-by: Naveen N. Rao --- include/linux/kprobes.h | 1 +