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]
Date:	Fri, 31 Jul 2015 00:59:20 +0200 (CEST)
From:	Thomas Gleixner <tglx@...utronix.de>
To:	Andy Lutomirski <luto@...capital.net>
cc:	Paolo Bonzini <pbonzini@...hat.com>,
	Peter Zijlstra <peterz@...radead.org>,
	Linus Torvalds <torvalds@...ux-foundation.org>,
	Willy Tarreau <w@....eu>, Steven Rostedt <rostedt@...dmis.org>,
	X86 ML <x86@...nel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	Borislav Petkov <bp@...en8.de>, Brian Gerst <brgerst@...il.com>
Subject: Re: Dealing with the NMI mess



On Thu, 30 Jul 2015, Andy Lutomirski wrote:

> On Thu, Jul 30, 2015 at 8:41 AM, Paolo Bonzini <pbonzini@...hat.com> wrote:
> >
> >
> > On 24/07/2015 23:08, Andy Lutomirski wrote:
> >> user_icebp is set if int $0x01 happens, except it isn't because user
> >> code can't actually do that -- it'll cause #GP instead.
> >>
> >> user_icebp is also set if the user has a bloody in-circuit emulator,
> >> given the name.  But who on Earth has one of those on a system new
> >> enough to run Linux and, even if they have one, why on Earth are they
> >> using it to send SIGTRAP.
> >
> > You do not need either "int $0x01" or an ICE to set user_icebp = 1.  You
> > can use the 0xf1 opcode, which is kinda like 0xcc but generates #DB
> > instead of #BP.
> 
> Great.  There's an opcode that invokes an interrupt gate that's not
> marked as allowing unprivileged access, and that opcode doesn't appear
> in the SDM.  It appears in the APM opcode map with no explanation at
> all.

The only SDM reference I found is:

  "The opcodes D6 and F1 are undefined opcodes reserved by the Intel 64
   and IA-32 architectures. These opcodes, even though undefined, do
   not generate an invalid opcode exception."

D6 is actually something useful:

   if (carry flag set)
      AL = FF
   else
      AL = 0

It's been there since i386. It has been conveniant for return code
magic from ASM to C. I haven't thought of it for at least a decade :)

So all we need to worry about is F1, but thats bad enough :(

Thanks,

	tglx


--
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