Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1470792

Re: [PATCH] binfmt_misc: allow selecting the interpreter based on xattr keywords

From Florian Weimer <fweimer@redhat.com>
Newsgroups linux.kernel
Subject Re: [PATCH] binfmt_misc: allow selecting the interpreter based on xattr keywords
Date 2016-08-26 17:00 +0200
Message-ID <saqLU-8tm-27@gated-at.bofh.it> (permalink)
References <sa5xM-3jP-29@gated-at.bofh.it> <sa5xM-3jP-27@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On 08/25/2016 06:15 PM, James Bottomley wrote:
> On Sun, 2016-08-21 at 21:01 -0700, Josh Max wrote:
>> This patch allows binfmt_misc to select the interpeter for arbitrary
>> binaries by comparing a specified registered keyword with the value
>> of a specified binary's extended attribute (user.binfmt.interp),
>> and then launching the program with the registered interpreter.
>>
>> This is useful when wanting to launch a collection of binaries under
>> the same interpreter, even when they do not necessarily share a
>> common extension or magic bits, or when their magic conflics with the
>> operation of binfmt_elf. Some examples of its use would be to launch
>> some executables of various different architectures in a directory,
>> or for running some native binaries under a sandbox (like firejail)
>> automatically during their launch.
>
> Could you expand on the use cases?

A non-security use case would be to run the binary (without 
modification) with a different ELF interpreter (assuming this allows to 
override binfmt_elf, but self-sandboxing would need that as well).  This 
would make it easier to use older or newer libcs for select binaries on 
the system.  Right now, one has to write wrappers for that, and the 
explicit dynamic linker invocation is not completely transparent to the 
application.

Florian

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Re: [PATCH] binfmt_misc: allow selecting the interpreter based on  xattr keywords James Bottomley <James.Bottomley@HansenPartnership.com> - 2016-08-25 18:20 +0200
  Re: [PATCH] binfmt_misc: allow selecting the interpreter based on  xattr keywords Florian Weimer <fweimer@redhat.com> - 2016-08-26 17:00 +0200
    Re: [PATCH] binfmt_misc: allow selecting the interpreter based on  xattr keywords Carlos O'Donell <carlos@redhat.com> - 2016-08-26 20:00 +0200
      Re: [PATCH] binfmt_misc: allow selecting the interpreter based on  xattr keywords James Bottomley <James.Bottomley@HansenPartnership.com> - 2016-08-26 23:50 +0200
    Re: [PATCH] binfmt_misc: allow selecting the interpreter based on  xattr keywords One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk> - 2016-08-26 23:20 +0200
      Re: [PATCH] binfmt_misc: allow selecting the interpreter based on  xattr keywords James Bottomley <James.Bottomley@HansenPartnership.com> - 2016-08-26 23:30 +0200
        Re: [PATCH] binfmt_misc: allow selecting the interpreter based on  xattr keywords One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk> - 2016-08-27 14:00 +0200

csiph-web