From: Mehmet Kayaalp <mkayaalp@linux.vnet.ibm.com>
To: David Howells <dhowells@redhat.com>
Cc: Mimi Zohar <zohar@linux.vnet.ibm.com>,
Stefan Berger <stefanb@linux.vnet.ibm.com>,
George Wilson <gcwilson@us.ibm.com>,
LSM <linux-security-module@vger.kernel.org>,
keyrings@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/4] KEYS: Insert incompressible bytes to reserve space in bzImage
Date: Fri, 25 Nov 2016 14:49:17 -0500 [thread overview]
Message-ID: <FC2E387E-55A7-4AD8-AA0A-8BAD9F0B5FC9@linux.vnet.ibm.com> (raw)
In-Reply-To: <14475.1480064784@warthog.procyon.org.uk>
> On Nov 25, 2016, at 4:06 AM, David Howells <dhowells@redhat.com> wrote:
>
> Mehmet Kayaalp <mkayaalp@linux.vnet.ibm.com> wrote:
>
>> Include a random filled binary in vmlinux at the space reserved with
>> CONFIG_SYSTEM_EXTRA_CERTIFICATE. This results in an uncompressed reserved
>> area inside the bzImage as well, so that it can be replaced with an actual
>> certificate later (after the bzImage is distributed).
>
> You haven't said *why* you need an incompressible buffer. I presume it's
> something to do with the decompression wrapper.
>
After you replace zeroes with a certificate and compress again, the image size
increases. Then, repackaging the bzImage becomes difficult.
>From the commit message of 3/4:
> This patch adds the capability of extracting the
> vmlinux, inserting the certificate, and repackaging the result into a
> bzImage.
>
> It only works if the resulting compressed vmlinux is smaller than the
> original. Otherwise re-linking would be required. To make the reserved
> space allocate actual space in bzImage, incompressible bytes are
> inserted into the vmlinux as a placeholder for the extra certificate.
Mehmet
prev parent reply other threads:[~2016-11-25 19:49 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-11-22 4:11 Mehmet Kayaalp
2016-11-22 4:11 ` [PATCH 1/4] KEYS: Insert incompressible bytes to reserve space in bzImage Mehmet Kayaalp
2016-11-22 4:11 ` [PATCH 2/4] KEYS: Add ELF class-independent certificate insertion support Mehmet Kayaalp
2016-11-22 4:11 ` [PATCH 3/4] KEYS: Support for inserting a certificate into x86 bzImage Mehmet Kayaalp
2016-11-22 4:11 ` [PATCH 4/4] KEYS: Print insert-sys-cert information to stdout instead of stderr Mehmet Kayaalp
2016-11-25 9:06 ` [PATCH 1/4] KEYS: Insert incompressible bytes to reserve space in bzImage David Howells
2016-11-25 19:49 ` Mehmet Kayaalp [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=FC2E387E-55A7-4AD8-AA0A-8BAD9F0B5FC9@linux.vnet.ibm.com \
--to=mkayaalp@linux.vnet.ibm.com \
--cc=dhowells@redhat.com \
--cc=gcwilson@us.ibm.com \
--cc=keyrings@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-security-module@vger.kernel.org \
--cc=stefanb@linux.vnet.ibm.com \
--cc=zohar@linux.vnet.ibm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®