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: <CAHk-=wjEQ7wd=iRN1Du-_fAqXgqEfCZH27PisDNPCpusv3Swxg@mail.gmail.com>
Date: Sat, 22 Feb 2025 10:44:38 -0800
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: Kent Overstreet <kent.overstreet@...ux.dev>
Cc: Steven Rostedt <rostedt@...dmis.org>, Martin Uecker <uecker@...raz.at>, 
	Dan Carpenter <dan.carpenter@...aro.org>, Greg KH <gregkh@...uxfoundation.org>, 
	Boqun Feng <boqun.feng@...il.com>, "H. Peter Anvin" <hpa@...or.com>, 
	Miguel Ojeda <miguel.ojeda.sandonis@...il.com>, Christoph Hellwig <hch@...radead.org>, 
	rust-for-linux <rust-for-linux@...r.kernel.org>, David Airlie <airlied@...il.com>, 
	linux-kernel@...r.kernel.org, ksummit@...ts.linux.dev
Subject: Re: Rust kernel policy

On Sat, 22 Feb 2025 at 09:53, Kent Overstreet <kent.overstreet@...ux.dev> wrote:
>
> Because it sounds like coming up with a different way to write range
> checks is going to be easier than coming up with pattern matching magic.

Sure. But honestly, forcing humans to write non-obvious code is almost
always the exact wrong answer.

When the basic pattern is an obvious and legible one:

        if (a < X || a > Y)

saying " use a different helper pattern for this" is the WRONG
SOLUTION. You're making the source code worse.

Make the tools better. Don't make humans jump through hoops because
the tools are spouting garbage.

               Linus

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ