1 |
Am 28.08.2011 13:14, schrieb Mick: |
2 |
> On Sunday 07 Aug 2011 16:20:18 Florian Philipp wrote: |
3 |
>> Am 07.08.2011 02:22, schrieb Mick: |
4 |
>>> On Friday 05 Aug 2011 23:08:38 Neil Bothwick wrote: |
5 |
>>>> On Fri, 05 Aug 2011 17:59:00 +0200, Florian Philipp wrote: |
6 |
>>>>> Yes, this was introduced in 3.8.0 to fix security issues [1]. Change |
7 |
>>>>> your config to look like this: |
8 |
>>>>> /var/log/portage/elog/summary.log { |
9 |
>>>>> su portage portage |
10 |
>>>>> ... |
11 |
>>>>> } |
12 |
>>>>> |
13 |
>>>>> Disclaimer: I've not really tried this (yet) but I think I'm able to |
14 |
>>>>> read changelogs and man-pages. ;-) |
15 |
>>>> |
16 |
>>>> Yes that fixes it. The latest portage ebuilds include an updated config |
17 |
>>>> file. |
18 |
>>> |
19 |
>>> Hmm ... it still complains here! |
20 |
>>> |
21 |
>>> error: error setting owner of |
22 |
>>> /var/log/portage/elog/summary.log-20110801.gz: Operation not permitted |
23 |
>>> |
24 |
>>> |
25 |
>>> This is my /etc/logrotate.d/elog-save-summary: |
26 |
>>> =================================== |
27 |
>>> /var/log/portage/elog/summary.log { |
28 |
>>> |
29 |
>>> su portage portage |
30 |
>>> |
31 |
>>> missingok |
32 |
>>> nocreate |
33 |
>>> delaycompress |
34 |
>>> |
35 |
>>> } |
36 |
>>> =================================== |
37 |
>>> |
38 |
>>> # ls -la /var/log/portage/elog/summary.log |
39 |
>>> -rw-rw-r-- 1 root portage 4326 Aug 6 09:44 |
40 |
>>> /var/log/portage/elog/summary.log |
41 |
>>> |
42 |
>>> Can you see anything amiss? |
43 |
>> |
44 |
>> At least on my system, /var/log/portage has the following permissions: |
45 |
>> drwxr-xr-x root root |
46 |
>> |
47 |
>> Only root can write, therefore the config must read |
48 |
>> |
49 |
>> /var/log/portage/elog/summary.log { |
50 |
>> su root portage |
51 |
>> missingok |
52 |
>> nocreate |
53 |
>> delaycompress |
54 |
>> } |
55 |
> |
56 |
> The latest logrotate update wanted to change the above line from su root |
57 |
> portage to su portage portage ... |
58 |
> |
59 |
> Should I be changing the ownership of /var/log/portage and /var/log/portage |
60 |
> elog? |
61 |
|
62 |
Unless portage now drops privileges from root:portage to portage:portage |
63 |
for writing logs, no one except root should be allowed to write in |
64 |
/var/log/portage. So, from my point of view, the answer is no. |
65 |
|
66 |
It seems so: |
67 |
https://bugs.gentoo.org/show_bug.cgi?id=374287 |
68 |
https://bugs.gentoo.org/show_bug.cgi?id=378451 |
69 |
|
70 |
This version of portage has just been stabilized this week. |
71 |
|
72 |
Regards, |
73 |
Florian Philipp |