linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Kees Cook <keescook@google.com>
To: Kostya Serebryany <kcc@google.com>
Cc: Daniel Micay <danielmicay@gmail.com>,
	Dmitry Vyukov <dvyukov@google.com>,
	Michal Hocko <mhocko@kernel.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	"linux-mm@kvack.org" <linux-mm@kvack.org>,
	Rik van Riel <riel@redhat.com>, Reid Kleckner <rnk@google.com>,
	Peter Collingbourne <pcc@google.com>,
	Evgeniy Stepanov <eugenis@google.com>
Subject: Re: binfmt_elf: use ELF_ET_DYN_BASE only for PIE breaks asan
Date: Mon, 7 Aug 2017 12:46:40 -0700	[thread overview]
Message-ID: <CAGXu5jLR-qz9dM=OmtZvT6PiU3zePnZq0i0Hx0wnaPKhB7m6TA@mail.gmail.com> (raw)
In-Reply-To: <CAN=P9pi+8ufOFQJbKFDeAqHeBzBzvxsuG-dFD=_TpmRyU0vqmQ@mail.gmail.com>

On Mon, Aug 7, 2017 at 12:40 PM, Kostya Serebryany <kcc@google.com> wrote:
>
>
> On Mon, Aug 7, 2017 at 12:34 PM, Kees Cook <keescook@google.com> wrote:
>>
>> (To be clear, this subthread is for dealing with _future_ changes; I'm
>> already preparing the revert, which is in the other subthread.)
>>
>> On Mon, Aug 7, 2017 at 12:26 PM, Kostya Serebryany <kcc@google.com> wrote:
>> > Oh, a launcher (e.g. just using setarch) would be a huge pain to deploy.
>>
>> Would loading the executable into the mmap region work?
>
> This is beyond my knowledge. :(
> Could you explain?

PIE has a separate randomization base (before at 0x5555 5555 4000,
currently 0x1 0000 0000) from the mmap (DSO) area (0x7f00 0000
0000-ish). The primary reason to keep PIE separate from mmap is to
avoid leaking ASLR offsets between them, but if that's less of a
concern for *San, then we could just load PIE into the mmap region.

> If we can do this w/o a launcher (and w/o re-executing), we should try.

Let me think about the best way to do this...

-Kees

-- 
Kees Cook
Pixel Security

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  parent reply	other threads:[~2017-08-07 19:46 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-07 17:24 Dmitry Vyukov
2017-08-07 17:33 ` Kostya Serebryany
2017-08-07 17:33 ` Kees Cook
2017-08-07 18:26   ` Kostya Serebryany
2017-08-07 18:36     ` Evgenii Stepanov
2017-08-07 18:40       ` Kees Cook
2017-08-07 18:51         ` Evgenii Stepanov
2017-08-07 18:57           ` Kees Cook
2017-08-07 19:03             ` Kostya Serebryany
2017-08-07 19:06               ` Kees Cook
2017-08-07 19:10                 ` Kostya Serebryany
2017-08-07 19:24               ` Kees Cook
2017-08-07 19:32                 ` Kostya Serebryany
2017-08-07 19:12             ` Evgenii Stepanov
2017-08-07 18:38     ` Daniel Micay
2017-08-07 18:45       ` Daniel Micay
2017-08-07 18:39     ` Kees Cook
2017-08-07 18:48       ` Daniel Micay
2017-08-07 18:52         ` Kees Cook
2017-08-07 18:56           ` Kostya Serebryany
2017-08-07 18:59             ` Kees Cook
2017-08-07 19:01               ` Daniel Micay
2017-08-07 19:05               ` Kostya Serebryany
2017-08-07 19:12                 ` Kees Cook
2017-08-07 19:16                   ` Kostya Serebryany
2017-08-07 19:21                     ` Kees Cook
2017-08-07 19:26                       ` Kostya Serebryany
2017-08-07 19:34                         ` Kees Cook
2017-08-07 19:40                           ` Kostya Serebryany
2017-08-07 19:42                             ` Daniel Micay
2017-08-07 19:46                             ` Kees Cook [this message]
2017-08-07 18:21 ` Daniel Micay

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='CAGXu5jLR-qz9dM=OmtZvT6PiU3zePnZq0i0Hx0wnaPKhB7m6TA@mail.gmail.com' \
    --to=keescook@google.com \
    --cc=akpm@linux-foundation.org \
    --cc=danielmicay@gmail.com \
    --cc=dvyukov@google.com \
    --cc=eugenis@google.com \
    --cc=kcc@google.com \
    --cc=linux-mm@kvack.org \
    --cc=mhocko@kernel.org \
    --cc=pcc@google.com \
    --cc=riel@redhat.com \
    --cc=rnk@google.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