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] [day] [month] [year] [list]
Date:	Sat, 10 Nov 2012 18:59:03 +0000
From:	Al Viro <viro@...IV.linux.org.uk>
To:	Michel Lespinasse <walken@...gle.com>
Cc:	linux-next@...r.kernel.org, LKML <linux-kernel@...r.kernel.org>,
	Hugh Dickins <hughd@...gle.com>
Subject: Re: Issues with "x86, um: switch to generic fork/vfork/clone" commit

On Sat, Nov 10, 2012 at 07:33:39AM +0000, Al Viro wrote:
> I think I see what's going on there.  It's PTREGSCALL blindly used for
> clone wrapper in ia32entry.S.  FWIW, it's wrong for all of those
> suckers, anyway:
> 	* fork/clone/vfork need to save extra registers, but don't need
> to restore them; after unification we don't need pt_regs argument for any
> of those - for fork/vfork it's useless, for clone it breaks things.
> 	* execve doesn't need pt_regs argument; harmless, but useless.
> 	* for sigaltstack() we simply need to get rid of stupid pt_regs
> argument, along with the wrapper; current_pt_regs()->sp is all it needs.
> 	* for sigreturn/rt_sigreturn we need to restore extra registers,
> but we do *not* need to save them; just leave the space on stack.  And
> no need to pass pt_regs either - it'll be current_pt_regs() anyway.
> 	* iopl() doesn't need to save/restore extras and it doesn't need
> pt_regs argument - it's going to be current_pt_regs().

Alas, sigaltack() and iopl() do need a bit of a wrapper; they don't care
about extras, but they wants ->sp and ->flags resp., which means needing
to go through FIXUP_TOP_OF_STACK on amd64 ;-/

> On top of all that, there's an extra piece of crap - different order of
> arguments for native and compat clone.

... and the same commit slightly buggers clone(2) on amd64 as well.  Grr...
Anyway, fixed and pushed; please, test for-next when it propagates, head
should be at fae45353de587ae6a949dbf21ee06d5dd652248c
--
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