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:	Thu, 28 Jan 2016 21:53:27 +0100
From:	Oleg Nesterov <oleg@...hat.com>
To:	Andrey Wagin <avagin@...il.com>
Cc:	LKML <linux-kernel@...r.kernel.org>,
	Andy Lutomirski <luto@...capital.net>,
	Cyrill Gorcunov <gorcunov@...nvz.org>,
	"criu@...nvz.org" <criu@...nvz.org>, kvm@...r.kernel.org
Subject: Re: x86: Hardware breakpoints are not always triggered

On 01/28, Andrey Wagin wrote:
>
> We use hardware breakpoints in CRIU and we found that sometimes we set
> a break-point, but a process doesn't stop on it.

reproduced, and this certainly looks like kvm bug to me.

> The reproducer uses a different break-point address if it is executed
> with arguments than when it executed without arguments.

IOW, multiple processes running in parallel use the same debug register db0
but different address. And it seems that set_debugreg(address, 0) sometime
doesn't work in the guest kernel.

I think I verified the following:

	- debug registers look always correct as it seen by the guest.
	  I used get_debugreg() to dump them after the task misses bp.

	- do_debug() was not called in this case.

	- finally, it seems that the host has the wrong value in db0
	  set by another process.

	  I modified your test-case so that child2() calls child() when
	  it detects the missed bp, and this does trigger do_debug/etc
	  while it should not.

Oleg.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ