From: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
To: Steven Rostedt <rostedt@goodmis.org>, WangYuli <wangyuli@uniontech.com>
Cc: dmitry.torokhov@gmail.com, guanwentao@uniontech.com,
linux-input@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-trace-kernel@vger.kernel.org, mhiramat@kernel.org,
niecheng1@uniontech.com, wangyuli@deepin.org,
zhanjun@uniontech.com, Winston Wen <wentao@uniontech.com>
Subject: Re: [PATCH 1/2] input: Add tracepoint support
Date: Tue, 22 Jul 2025 21:24:27 -0400 [thread overview]
Message-ID: <2b31b238-667e-47b9-b61f-76832a1f77a7@efficios.com> (raw)
In-Reply-To: <20250722202551.1614f59a@gandalf.local.home>
On 2025-07-22 20:25, Steven Rostedt wrote:
> On Thu, 10 Jul 2025 15:31:38 +0800
> WangYuli <wangyuli@uniontech.com> wrote:
>
>> diff --git a/include/trace/events/input.h b/include/trace/events/input.h
>> new file mode 100644
>> index 000000000000..3c5ffcfb7c8d
>> --- /dev/null
>> +++ b/include/trace/events/input.h
>> @@ -0,0 +1,251 @@
>> +/* SPDX-License-Identifier: GPL-2.0 */
>> +/* input tracepoints
>> + *
>> + * Copyright (C) 2025 WangYuli <wangyuli@uniontech.com>
>> + */
>> +#undef TRACE_SYSTEM
>> +#define TRACE_SYSTEM input
>> +
>> +#if !defined(_TRACE_INPUT_H) || defined(TRACE_HEADER_MULTI_READ)
>> +#define _TRACE_INPUT_H
>> +
>> +#include <linux/tracepoint.h>
>> +#include <linux/input.h>
>> +
>> +/**
>> + * input_event - called when an input event is processed
>> + * @dev: input device that generated the event
>> + * @type: event type (EV_KEY, EV_REL, EV_ABS, etc.)
>> + * @code: event code within the type
>> + * @value: event value
>> + *
>> + * This tracepoint fires for every input event processed by the input core.
>> + * It can be used to monitor input device activity and debug input issues.
>> + */
I've always been worried about adding tracepoint instrumentation of the
input subsystem that includes the actual keystrokes into the event
payload. What I'm trying to avoid here is people leaking their password
by mistake just because they happened to record a trace while
typing on their keyboard.
I don't mind if this gets enabled with a new kernel command line
options "tracing_leak_my_credentials=yes" or such, but I'd try to
avoid making it easy to enable by mistake unless this information
is specifically needed.
But maybe I'm being too careful and people should really learn not
to share kernel traces with others.
Thoughts ?
Thanks,
Mathieu
--
Mathieu Desnoyers
EfficiOS Inc.
https://www.efficios.com
next prev parent reply other threads:[~2025-07-23 1:24 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-10 7:26 [PATCH 0/2] " WangYuli
2025-07-10 7:31 ` [PATCH 1/2] " WangYuli
2025-07-23 0:25 ` Steven Rostedt
2025-07-23 1:24 ` Mathieu Desnoyers [this message]
2025-07-28 7:07 ` WangYuli
2025-07-28 13:53 ` Mathieu Desnoyers
2025-07-28 6:51 ` WangYuli
2025-07-10 7:31 ` [PATCH 2/2] selftests: input: Add tracepoint testing script WangYuli
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2b31b238-667e-47b9-b61f-76832a1f77a7@efficios.com \
--to=mathieu.desnoyers@efficios.com \
--cc=dmitry.torokhov@gmail.com \
--cc=guanwentao@uniontech.com \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-trace-kernel@vger.kernel.org \
--cc=mhiramat@kernel.org \
--cc=niecheng1@uniontech.com \
--cc=rostedt@goodmis.org \
--cc=wangyuli@deepin.org \
--cc=wangyuli@uniontech.com \
--cc=wentao@uniontech.com \
--cc=zhanjun@uniontech.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®