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, 8 Mar 2012 20:25:59 +0100
From:	Oleg Nesterov <oleg@...hat.com>
To:	Cyrill Gorcunov <gorcunov@...nvz.org>
Cc:	Matt Helsley <matthltc@...ibm.com>,
	KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>,
	Pavel Emelyanov <xemul@...allels.com>,
	Kees Cook <keescook@...omium.org>, Tejun Heo <tj@...nel.org>,
	Andrew Morton <akpm@...ux-foundation.org>,
	LKML <linux-kernel@...r.kernel.org>
Subject: Re: [RFC] c/r: prctl: Add ability to set new mm_struct::exe_file v3

On 03/08, Cyrill Gorcunov wrote:
>
> On Thu, Mar 08, 2012 at 08:05:34PM +0100, Oleg Nesterov wrote:
> ...
> > >
> > > Yes, exactly, I need to remove old mappings first (because VMAs
> > > we're about to restore may intersect with current map the host
> > > program has). And yes, once they all are removed I don't have
> > > /proc/pid/exe anymore. That's why I need num_exe_file_vmas == 0
> > > case.
> >
> > OK, in this case PR_SET_MM_EXE_FILE should probably fail if
> > mm->num_exe_file_vmas != 0 ? This way it would be more or less
> > consistent or at least understandable. Just we add the new
> > special case: num_exe_file_vmas == 0 but exe_file != NULL
> > because c/r people are crazy.
> >
>
> Sure, I can drop num_exe_file_vmas != 0 case and refuse to
> setup new exe symlink if there some VM_EXECUTABLE remains
> unmapped. Sounds good?

Personally I like this. This is simple and _understable_, even
if ->num_exe_file_vmas has no meaning after PR_SET_MM_EXE.

But please-please document the new special case in the changelog.

Oleg.

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