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: <20250712103732.79c7b9e1@batman.local.home>
Date: Sat, 12 Jul 2025 10:37:32 -0400
From: Steven Rostedt <rostedt@...dmis.org>
To: "Masami Hiramatsu (Google)" <mhiramat@...nel.org>
Cc: Mathieu Desnoyers <mathieu.desnoyers@...icios.com>,
 linux-kernel@...r.kernel.org, linux-trace-kernel@...r.kernel.org
Subject: Re: [PATCH 1/2] tracing: Remove "__attribute__()" from the type
 field of event format

On Sat, 12 Jul 2025 20:45:24 +0900
Masami Hiramatsu (Google) <mhiramat@...nel.org> wrote:

> Hmm, Ok. But when I sanitized the field->type in
> update_event_fields(), it did not work. So something
> we missed.

Ah, it's because we test to see if the event has enums or not before
calling update_event_fields. We need something like this:


diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c
index 120531268abf..52829b950022 100644
--- a/kernel/trace/trace_events.c
+++ b/kernel/trace/trace_events.c
@@ -3349,6 +3349,8 @@ void trace_event_eval_update(struct trace_eval_map **map, int len)
 				}
 				update_event_printk(call, map[i]);
 				update_event_fields(call, map[i]);
+			} else if (need_sanitize_field_type(__type)) {
+				sanitize_fields(call);
 			}
 		}
 		cond_resched();


And have the attribute fixed in both update_event_fields() and have
your own sanitize_fields() that just does the attribute update.

-- Steve

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ