All of lore.kernel.org
 help / color / mirror / Atom feed
From: Solar Designer <solar@openwall.com>
To: kernel-hardening@lists.openwall.com
Subject: Re: [kernel-hardening] base address for shared libs
Date: Fri, 12 Aug 2011 14:04:47 +0400	[thread overview]
Message-ID: <20110812100447.GB6743@openwall.com> (raw)
In-Reply-To: <20110812095219.GA3012@albatros>

On Fri, Aug 12, 2011 at 01:52:19PM +0400, Vasiliy Kulikov wrote:
> There are 2 allocation logics, top down and bottom up:
> 
> http://lxr.free-electrons.com/source/mm/mmap.c#L1372
> 
> http://lxr.free-electrons.com/source/mm/mmap.c#L1444
> 
> If use top down logic (start from 0x01000000 as the end of the library)
> then some gap at 0x00110000 will be wasted.  With bottom up logic I'll
> simply have the last library partly being in ASCII-armor zone, the end
> of it will be located after 0x01000000, but no waste of vm space.
> 
> Or you mean anything else?

You're right.  I just didn't realize the words "bottom up" were used in
kernel source to mean that.

> OK.  However, I don't see much sense in sizes between 10 and 16.  If we
> want to use ASCII-armor or warried about vm-hungry apps, then use 10
> bits.

Why not use 14 in such cases, which still fits in the below-binary range
and thus does not reduce the maximum continuous allocation size?

> But if use distros with their default 12 bits in containers, it makes
> sense to protect them with a probabilistic measure, though.

I don't understand what you mean here.  The distros' default 12 bits -
are they patched into those distros' kernels?  If so, they do not apply
to use in containers (where only userlands are used).

Alexander

  reply	other threads:[~2011-08-12 10:04 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-23 16:22 [kernel-hardening] base address for shared libs Solar Designer
2011-07-24  8:51 ` Vasiliy Kulikov
2011-07-24 14:27   ` Solar Designer
2011-07-24 18:18     ` Vasiliy Kulikov
2011-07-25 19:20     ` Vasiliy Kulikov
2011-08-11  8:32       ` Vasiliy Kulikov
2011-08-12  3:57         ` Solar Designer
2011-08-12  4:21           ` Solar Designer
2011-08-12  8:20             ` Vasiliy Kulikov
2011-08-12  9:20               ` Solar Designer
2011-08-12  9:52                 ` Vasiliy Kulikov
2011-08-12 10:04                   ` Solar Designer [this message]
2011-08-12 10:06                     ` Vasiliy Kulikov
2011-07-29  9:27 ` Vasiliy Kulikov
2011-07-30 18:38 ` Vasiliy Kulikov
2011-07-30 18:43   ` Vasiliy Kulikov

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=20110812100447.GB6743@openwall.com \
    --to=solar@openwall.com \
    --cc=kernel-hardening@lists.openwall.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.