public inbox for linux-serial@vger.kernel.org
 help / color / mirror / Atom feed
From: Marwan Seliem <marwanmhks@gmail.com>
To: gregkh@linuxfoundation.org
Cc: akpm@linux-foundation.org, jirislaby@kernel.org,
	linux-kernel@vger.kernel.org, linux-serial@vger.kernel.org,
	marwanmhks@gmail.com
Subject: Re: [PATCH] tty: sysrq: Introduce compile-time crash-only mode
Date: Tue,  8 Jul 2025 00:16:50 +0300	[thread overview]
Message-ID: <20250707211650.12051-1-marwanmhks@gmail.com> (raw)
In-Reply-To: <2025061938-making-igloo-3326@gregkh>

Let me clarify the security rationale and address your concerns.

> "security" involves crashing the system, so I fail to understand why one
> is more "secure" than the other.

You're absolutely right that crash access itself requires careful consideration. 
The security distinction we're making is between:

1. Controlled Crash Access (our patch):
   - Single, auditable code path (only sysrq-c)
   - No runtime configuration possible
   - No ancillary debug features that could leak information

2. Full SysRq Access:
   - ~60 command vectors to maintain/audit
   - Runtime configuration complexity
   - Features like memory/register dumps

> I don't understand your graphs here, what are you trying to say?
> Somehow still allowing someone to crash the system still is "secure"?

Apologies for the unclear visualization. The key points are:

1. Current reality forces a binary choice:
   - CONFIG_MAGIC_SYSRQ=n: No debug capability
   - CONFIG_MAGIC_SYSRQ=y: Full command set

2. Our proposal adds:
   CONFIG_MAGIC_SYSRQ_CRASH_ONLY=y:
   - Only sysrq-c enabled
   - All other commands compile-time disabled
   - No runtime reconfiguration possible

The security value comes from:
- Reducing attack surface from ~60 commands to 1
- Eliminating information leaks (register/memory dumps)
- Preventing privilege escalation vectors (like filesystem control)
- Meeting compliance requirements that mandate crash access
  while prohibiting other debug features

> confused,

This isn't about claiming crashes are "secure", it's about providing the minimal 
debug capability required by certain industries while eliminating all other 
sysrq-related risks.


Marwan Seliem

  reply	other threads:[~2025-07-07 21:16 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-06-07 15:19 [PATCH] tty: sysrq: Introduce compile-time crash-only mode Marwan Seliem
2025-06-09  7:48 ` Jiri Slaby
2025-06-11  6:33 ` Marwan Seliem
2025-06-19 11:20   ` Greg KH
2025-07-07 21:16     ` Marwan Seliem [this message]
2025-07-08  8:05       ` Greg KH

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=20250707211650.12051-1-marwanmhks@gmail.com \
    --to=marwanmhks@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=jirislaby@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    /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