tracing: t_start: reset FTRACE_ITER_HASH in case of seek/pread
authorChris Wright <chrisw@sous-sol.org>
Thu, 9 Sep 2010 23:34:59 +0000 (16:34 -0700)
committerSteven Rostedt <rostedt@goodmis.org>
Fri, 10 Sep 2010 02:43:49 +0000 (22:43 -0400)
commitdf09162550fbb53354f0c88e85b5d0e6129ee9cc
treee8ba6014c442cf72d587948733f8c29e0d330925
parent5e11637e2c929e34dcc0fbbfb48bdb638937701a
tracing: t_start: reset FTRACE_ITER_HASH in case of seek/pread

Be sure to avoid entering t_show() with FTRACE_ITER_HASH set without
having properly started the iterator to iterate the hash.  This case is
degenerate and, as discovered by Robert Swiecki, can cause t_hash_show()
to misuse a pointer.  This causes a NULL ptr deref with possible security
implications.  Tracked as CVE-2010-3079.

Cc: Robert Swiecki <swiecki@google.com>
Cc: Eugene Teo <eugene@redhat.com>
Cc: <stable@kernel.org>
Signed-off-by: Chris Wright <chrisw@sous-sol.org>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
kernel/trace/ftrace.c