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]
Message-ID: <20130319231756.GA21071@srcf.ucam.org>
Date:	Tue, 19 Mar 2013 23:17:56 +0000
From:	Matthew Garrett <mjg59@...f.ucam.org>
To:	James Bottomley <James.Bottomley@...senPartnership.com>
Cc:	linux-efi@...r.kernel.org,
	linux-kernel <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] x86/efi: pull NV+BS variables out before we exit boot
 services

On Tue, Mar 19, 2013 at 11:00:31PM +0000, James Bottomley wrote:
> On Tue, 2013-03-19 at 18:50 +0000, Matthew Garrett wrote:
> > Well, that somewhat complicates implementation - we'd be encrypting the 
> > entire contents of memory except for the key that we're using to encrypt 
> > memory. Keeping the public key away from userspace avoids having to care 
> > about that.
> 
> I don't quite understand what you're getting at: the principle of public
> key cryptography is that you can make the public key, well public.  You
> only need to guard the private key.

Ok, so let's just rephrase it as asymmetric cryptography. The aim is to 
ensure that there's never a situation where userspace can decrypt a 
hibernation file, modify it and reencrypt it. So, shim (or whatever) 
generates a keypair. The encryption key is passed to the kernel being 
booted. The decryption key is stashed in a variable in order to be 
passed to the resume kernel.

If the decryption key is available to userspace then the kernel needs to 
discard the encryption key during image write-out - otherwise the 
encryption key will be in the encrypted image. If the decryption key 
isn't available to userspace then this isn't a concern.

If the decryption key *is* available to userspace (as it would be in 
your case), there's a requirement to discard the encryption key during 
the hibernation process. This isn't impossible, but it does add a little 
to the complexity.

-- 
Matthew Garrett | mjg59@...f.ucam.org
--
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