Gentoo Archives: gentoo-dev

From: Georgy Yakovlev <gyakovlev@g.o>
To: gentoo-dev@l.g.o
Cc: pr@g.o, Georgy Yakovlev <gyakovlev@g.o>
Subject: [gentoo-dev] [PATCH] 2021-07-07-systemd-tmpfiles: restore news item
Date: Fri, 09 Jul 2021 19:23:04
Message-Id: 20210709192248.2493373-1-gyakovlev@gentoo.org
In Reply to: [gentoo-dev] [PATCH] 2021-07-07-systemd-tmpfiles: add news item by Georgy Yakovlev
1 This reverts commit a93dbc1701de3b983c6f791391f7967d4b919b4a.
2 and addresses some feedback items
3 ---
4 .../2021-07-07-systemd-tmpfiles.en.txt | 66 +++++++++++++++++++
5 1 file changed, 66 insertions(+)
6 create mode 100644 2021-07-07-systemd-tmpfiles/2021-07-07-systemd-tmpfiles.en.txt
7
8 diff --git a/2021-07-07-systemd-tmpfiles/2021-07-07-systemd-tmpfiles.en.txt b/2021-07-07-systemd-tmpfiles/2021-07-07-systemd-tmpfiles.en.txt
9 new file mode 100644
10 index 0000000..7167985
11 --- /dev/null
12 +++ b/2021-07-07-systemd-tmpfiles/2021-07-07-systemd-tmpfiles.en.txt
13 @@ -0,0 +1,66 @@
14 +Title: opentmpfiles deprecation
15 +Author: Georgy Yakovlev <gyakovlev@g.o>
16 +Author: Sam James <sam@g.o>
17 +Posted: 2021-07-09
18 +Revision: 2
19 +News-Item-Format: 2.0
20 +Display-If-Installed: sys-apps/opentmpfiles
21 +Display-If-Installed: sys-apps/systemd-tmpfiles
22 +
23 +A tmpfiles [0] implementation provides a generic mechanism to define
24 +the creation of regular files, directories, pipes, and device nodes,
25 +adjustments to their access mode, ownership, attributes, quota
26 +assignments, and contents, and finally their time-based removal.
27 +It is commonly used for volatile and temporary files and directories
28 +such as those located under /run/, /tmp/, /var/tmp/, the API file
29 +systems such as /sys/ or /proc/, as well as some other directories
30 +below /var/. [1]
31 +
32 +On 2021-07-06, the sys-apps/opentmpfiles package was masked due to a
33 +root privilege escalation vulnerability (CVE-2017-18925 [2],
34 +bug #751415 [3], issue 4 [4] upstream).
35 +
36 +The use of opentmpfiles is discouraged by its maintainer due to the
37 +unpatched vulnerability and other long-standing bugs [5].
38 +
39 +Users will start seeing their package manager trying to replace
40 +sys-apps/opentmpfiles with sys-apps/systemd-tmpfiles because it is
41 +another provider of virtual/tmpfiles.
42 +
43 +Despite the name, 'systemd-tmpfiles' does not depend on systemd, does
44 +not use dbus, and is just a drop-in replacement for opentmpfiles. It is
45 +a small binary built from systemd source code, but works separately,
46 +similarly to eudev or elogind. It is known to work on both glibc and
47 +musl systems.
48 +
49 +Note that systemd-tmpfiles is specifically for non-systemd systems. It
50 +is intended to be used on an OpenRC system.
51 +
52 +If you wish to selectively test systemd-tmpfiles, follow those steps:
53 +
54 + 1. # emerge --oneshot sys-apps/systemd-tmpfiles
55 + 2. # reboot
56 + 3. # rm /etc/runlevels/boot/opentmpfiles-setup
57 + 4. # rm /etc/runlevels/sysinit/opentmpfiles-dev
58 +
59 +No other steps required.
60 +
61 +If, after reviewing the linked bug reference for opentmpfiles, you feel
62 +your system is not vulnerable/applicable to the attack described, you
63 +can unmask [6] opentmpfiles at your own risk:
64 +
65 + 1. In /etc/portage/package.unmask, add a line:
66 + -sys-apps/opentmpfiles-
67 + 2. # emerge --oneshot sys-apps/opentmpfiles
68 +
69 +Note that opentmpfiles is likely to be removed from gentoo repository
70 +in the future.
71 +
72 +[0] https://www.freedesktop.org/software/systemd/man/systemd-tmpfiles.html
73 +[1] https://www.freedesktop.org/software/systemd/man/tmpfiles.d.html
74 +[2] https://nvd.nist.gov/vuln/detail/CVE-2017-18925
75 +[3] https://bugs.gentoo.org/751415
76 +[4] https://github.com/OpenRC/opentmpfiles/issues/4
77 +[5] https://archives.gentoo.org/gentoo-dev/message/bce91b9d37db0b1e0980eb923a8607c9
78 +[6] https://wiki.gentoo.org/wiki/Knowledge_Base:Unmasking_a_package
79 +
80 --
81 2.32.0