lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150205154336.0be014e9@gandalf.local.home>
Date:	Thu, 5 Feb 2015 15:43:36 -0500
From:	Steven Rostedt <rostedt@...dmis.org>
To:	Al Viro <viro@...IV.linux.org.uk>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: [RFC][PATCH 1/7] trace: fix the glob match in
 __unregister_ftrace_function_probe()

On Thu,  5 Feb 2015 19:56:34 +0000
Al Viro <viro@...IV.linux.org.uk> wrote:

> From: Al Viro <viro@...iv.linux.org.uk>
> 
> For patterns starting with '*' we need to match against 'search', not
> 'glob'.
> 
> Signed-off-by: Al Viro <viro@...iv.linux.org.uk>
> ---
>  kernel/trace/ftrace.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
> index 224e768..9f90a4f 100644
> --- a/kernel/trace/ftrace.c
> +++ b/kernel/trace/ftrace.c

Can you make search = NULL instead of glob at the start of the
function. That is:

	if (!glob || strcmp(glob, "*") == 0 || !strlen(glob))
		search = NULL;

> @@ -3802,7 +3802,7 @@ __unregister_ftrace_function_probe(char *glob, struct ftrace_probe_ops *ops,
>  			if (glob) {

And then here have

			if (search) {

>  				kallsyms_lookup(entry->ip, NULL, NULL,
>  						NULL, str);
> -				if (!ftrace_match(str, glob, len, type))
> +				if (!ftrace_match(str, search, len, type))

Otherwise I'm sure there's a gcc out there that will give a warning
about search being used uninitialized.

-- Steve

>  					continue;
>  			}
>  

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ