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: <20150715160528.GA6184@treble.redhat.com>
Date:	Wed, 15 Jul 2015 11:05:28 -0500
From:	Josh Poimboeuf <jpoimboe@...hat.com>
To:	Ingo Molnar <mingo@...nel.org>
Cc:	Thomas Gleixner <tglx@...utronix.de>,
	Ingo Molnar <mingo@...hat.com>,
	"H. Peter Anvin" <hpa@...or.com>, Michal Marek <mmarek@...e.cz>,
	Peter Zijlstra <peterz@...radead.org>,
	Andy Lutomirski <luto@...nel.org>,
	Borislav Petkov <bp@...en8.de>,
	Linus Torvalds <torvalds@...ux-foundation.org>,
	Andi Kleen <andi@...stfloor.org>,
	Pedro Alves <palves@...hat.com>, x86@...nel.org,
	live-patching@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v7 0/4] Compile-time stack validation

On Wed, Jul 15, 2015 at 12:16:28PM +0200, Ingo Molnar wrote:
> 
> * Josh Poimboeuf <jpoimboe@...hat.com> wrote:
> 
> > On Tue, Jul 14, 2015 at 12:14:06PM -0500, Josh Poimboeuf wrote:
> > > Posting a listing of reported warnings in a reply to this email.
> > 
> > These are the reported stackvalidate warnings on tip/master with my Fedora-based 
> > config.  There were 1399 warnings in 26 .c files and 16 .S files.  It was mostly 
> > repeat warnings so I removed a lot of the repeats to keep it short.
> 
> Are most of these warnings legit, what's the false positive rate in your 
> impression?

Examining the warnings per-file (since that's a much easier analysis
than per-warning):

Of the 26 .c files:

- 21 have real frame pointer bugs, most of them caused by a handful of
  inline asm() macros
- 5 have false positives (but several of these have questionable usage
  of asm() which might be convertible to C code)

Of the 16 .S files:

- 12 have real frame pointer bugs*, typically caused by not having
  FRAME/ENDFRAME (note: many of these files also have false positive
  warnings)

- 4 have no bugs and only false positives

Most of the false positives in the .S files are actually incorrect ELF
annotations.  I still consider them false positives because they're not
"real" bugs, per se.  But they're still fixable.

Overall I think there will end up being only be a handful of locations
that need to use one of the whitelist macros
(STACKVALIDATE_IGNORE_{INSN,FILE}).

> You might want to start fixing a few typical types, just to see what it involves 
> exactly and whether we want to fix it that way.

I already have a good idea of what needs to be done for most of the
warnings.  I'll post some patches and try to give a representive
sampling of what the different types of fixes look like.


[*] But note that the definition of a frame pointer bug is open to
    interpretation, especially for "special" asm code like suspend,
    hibernate, relocate, reboot, ftrace, bpf, entry code, etc.  In
    general, when looking at whether frame pointers are needed, I asked
    myself "what would gcc do?"

-- 
Josh
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ