Gentoo Archives: gentoo-dev

From: Michael Orlitzky <mjo@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] portage reliance on GNU objcopy ownership perseverance behavior in strip
Date: Fri, 05 Feb 2021 01:00:27
Message-Id: 088e556926dba2a6fb0d3da3627664f7cf60c434.camel@gentoo.org
In Reply to: [gentoo-dev] portage reliance on GNU objcopy ownership perseverance behavior in strip by Manoj Gupta
1 On Thu, 2021-02-04 at 16:09 -0800, Manoj Gupta wrote:
2 >
3 > What does everyone think of modifying usages of calls to strip and
4 > objcopy
5 > inside estrip so that file ownership is manually restored. e.g
6 >
7 > owner=$(stat -U file)
8 > group=$(stat -G file)
9 > strip <file>
10 > chown owner:group file
11 >
12
13 This is probably safe in portage because the temporary directory is no
14 longer user-accessible, but it seems perverse to seek feature parity by
15 adding the security vulnerability into the implementations that don't
16 have it, rather than by removing it from the ones that do. Hopefully
17 LLVM just accepts the patch.