Gentoo Archives: gentoo-dev

From: James Le Cuirot <chewi@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] rfc: ideas for fixing OpenRC checkpath issue
Date: Wed, 10 Jan 2018 22:19:13
Message-Id: 20180110221841.740bcd91@symphony.aura-online.co.uk
In Reply to: [gentoo-dev] rfc: ideas for fixing OpenRC checkpath issue by William Hubbs
1 On Tue, 9 Jan 2018 18:07:41 -0600
2 William Hubbs <williamh@g.o> wrote:
3
4 > All,
5 >
6 > please take a look at the following issue.
7 >
8 > https://github.com/openrc/openrc/issues/195
9 >
10 > The first part of the fix is committed to master as shown on the issue;
11 > checkpath should *never* follow symbolic links when changing ownership,
12 > so I have moved to the lchown call instead of chown.
13 >
14 > However, I'm not sure how to deal with the hard link issue in a way that
15 > will not break service scripts.
16 >
17 > If anyone has any suggestions for this, let me know.
18
19 I faced the hard link problem in another package (bug still restricted)
20 recently. I'm about to push the fix out but I just want check what I've
21 done is okay. The init script used to call chown/chmod -R, which is
22 obviously bad. I've compromised by only calling these on the
23 directories themselves (ignoring symlinks). I believe this is safe
24 because it's not possible to create hard linked directories these days?
25 Would you agree?
26
27 --
28 James Le Cuirot (chewi)
29 Gentoo Linux Developer

Replies

Subject Author
Re: [gentoo-dev] rfc: ideas for fixing OpenRC checkpath issue Michael Orlitzky <mjo@g.o>