[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHk-=wj95tXzuox8eXPhBtJtV_NzWksxyQ+nPPty1atWH2T-xg@mail.gmail.com>
Date: Sun, 10 Mar 2019 14:52:02 -0700
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: Rasmus Villemoes <linux@...musvillemoes.dk>
Cc: Konstantin Khlebnikov <khlebnikov@...dex-team.ru>,
Linux List Kernel Mailing <linux-kernel@...r.kernel.org>,
Tejun Heo <tj@...nel.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Andrew Morton <akpm@...ux-foundation.org>,
Alexey Dobriyan <adobriyan@...il.com>
Subject: Re: [PATCH v1 2/6] lib: scanf: handle integer overflows in vsscanf
On Sun, Mar 10, 2019 at 2:06 PM Rasmus Villemoes
<linux@...musvillemoes.dk> wrote:
>
> IIRC, this has been attempted before, causing a userspace regression
> because some sysfs/procfs file matched with %u or %x, and somebody wrote
> -1 to get 0xffffffff .
.. which is correct anyway. That's how scanf is supposed to work.
If somebody needs overflow checking, they shouldn't be using scanf.
Linus
Powered by blists - more mailing lists