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:	Wed, 19 Sep 2012 09:15:12 -0700
From:	Kees Cook <keescook@...omium.org>
To:	Mimi Zohar <zohar@...ux.vnet.ibm.com>
Cc:	Rusty Russell <rusty@...tcorp.com.au>,
	"H. Peter Anvin" <hpa@...or.com>, linux-kernel@...r.kernel.org,
	Serge Hallyn <serge.hallyn@...onical.com>,
	James Morris <james.l.morris@...cle.com>,
	Al Viro <viro@...iv.linux.org.uk>,
	Eric Paris <eparis@...hat.com>, Jiri Kosina <jkosina@...e.cz>,
	linux-security-module@...r.kernel.org
Subject: Re: [PATCH 1/2] module: add syscall to load module from fd

On Wed, Sep 19, 2012 at 7:41 AM, Mimi Zohar <zohar@...ux.vnet.ibm.com> wrote:
> On Wed, 2012-09-19 at 13:08 +0930, Rusty Russell wrote:
>> Mimi Zohar <zohar@...ux.vnet.ibm.com> writes:
>>
>> > On Wed, 2012-09-12 at 17:04 +0930, Rusty Russell wrote:
>> >> "H. Peter Anvin" <hpa@...or.com> writes:
>> >>
>> >> > On 09/06/2012 11:13 AM, Kees Cook wrote:
>> >> >> Instead of (or in addition to) kernel module signing, being able to reason
>> >> >> about the origin of a kernel module would be valuable in situations
>> >> >> where an OS already trusts a specific file system, file, etc, due to
>> >> >> things like security labels or an existing root of trust to a partition
>> >> >> through things like dm-verity.
>> >> >>
>> >> >> This introduces a new syscall (currently only on x86), similar to
>> >> >> init_module, that has only two arguments. The first argument is used as
>> >> >> a file descriptor to the module and the second argument is a pointer to
>> >> >> the NULL terminated string of module arguments.
>> >> >>
>> >> >
>> >> > Please use the standard naming convention, which is an f- prefix (i.e.
>> >> > finit_module()).
>> >>
>> >> Good point; I just did a replace here.
>> >
>> > Have you pushed out the changes?  And if so, to where?
>>
>> No, I kept them in my patch series but out of linux-next, since I
>> thought you disliked the placement of the security hooks?
>
> I thought about it some more.  The call to
> security_kernel_module_from_file() from copy_module_from_user() doesn't
> provide any information, not the buffer contents nor the signature.  The
> only thing IMA-appraisal can do is to fail the request with
> INTEGRITY_UNKNOWN.  This is reflected in the IMA-appraisal patch I
> posted http://marc.info/?l=linux-security-module&m=134739023306344&w=2.
>
> Please add my Acked-by: Mimi Zohar <zohar@...ibm.com>

FWIW, this was my intent: it is a way for the LSM to see an attempt to
load a module it can't reason about. If it wants to allow it blindly,
it can, otherwise is has the option to refuse it. I didn't want to
leave the old syscall unhooked.

-Kees

-- 
Kees Cook
Chrome OS Security
--
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