source: postlfs/security/polkit.xml@ 8da5263

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts lazarus lxqt plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since 8da5263 was 8da5263, checked in by Bruce Dubbs <bdubbs@…>, 4 years ago

Update to polkit-cf22af32. Allows use of js68.
Archive js60.

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@23262 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 14.2 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY polkit-download-http "&sources-anduin-http;/polkit/polkit-&polkit-version;.tar.xz">
8 <!ENTITY polkit-download-ftp "&sources-anduin-ftp;/polkit/polkit-&polkit-version;.tar.xz">
9 <!ENTITY polkit-md5sum "3178fb1dcc6896178515861fe6910c6b">
10 <!ENTITY polkit-size "656 KB">
11 <!ENTITY polkit-buildsize "21 MB (with tests)">
12 <!ENTITY polkit-time "0.4 SBU (Using parallelism=4; with tests)">
13]>
14
15<!--
16 The tarball above was generated from a merge request using
17 git fetch "https://gitlab.freedesktop.org/xry111/polkit.git" "js68"
18 and merging the polkit-0.116 patch and running autogen.sh NOCONFIGURE=1
19
20 If/when this is actually merged with a new release, we need
21 to go back to that.
22-->
23
24<sect1 id="polkit" xreflabel="Polkit-&polkit-version;">
25 <?dbhtml filename="polkit.html"?>
26
27 <sect1info>
28 <othername>$LastChangedBy$</othername>
29 <date>$Date$</date>
30 </sect1info>
31
32 <title>Polkit-&polkit-version;</title>
33
34 <indexterm zone="polkit">
35 <primary sortas="a-Polkit">Polkit</primary>
36 </indexterm>
37
38 <sect2 role="package">
39 <title>Introduction to Polkit</title>
40
41 <para>
42 <application>Polkit</application> is a toolkit for defining and handling
43 authorizations. It is used for allowing unprivileged processes to
44 communicate with privileged processes.
45 </para>
46
47 &lfs91_checked;
48
49 <bridgehead renderas="sect3">Package Information</bridgehead>
50 <itemizedlist spacing="compact">
51 <listitem>
52 <para>
53 Download (HTTP): <ulink url="&polkit-download-http;"/>
54 </para>
55 </listitem>
56 <listitem>
57 <para>
58 Download (FTP): <ulink url="&polkit-download-ftp;"/>
59 </para>
60 </listitem>
61 <listitem>
62 <para>
63 Download MD5 sum: &polkit-md5sum;
64 </para>
65 </listitem>
66 <listitem>
67 <para>
68 Download size: &polkit-size;
69 </para>
70 </listitem>
71 <listitem>
72 <para>
73 Estimated disk space required: &polkit-buildsize;
74 </para>
75 </listitem>
76 <listitem>
77 <para>
78 Estimated build time: &polkit-time;
79 </para>
80 </listitem>
81 </itemizedlist>
82<!--
83 <bridgehead renderas="sect3" revision="sysv">Additional Downloads</bridgehead>
84 <itemizedlist spacing="compact" revision="sysv">
85 <listitem>
86 <para>
87 Recommended patch:
88 <ulink url="&patch-root;/polkit-&polkit-version;-fix_elogind_detection-1.patch"/>
89 </para>
90 </listitem>
91 </itemizedlist>
92-->
93 <bridgehead renderas="sect3">Polkit Dependencies</bridgehead>
94
95 <bridgehead renderas="sect4">Required</bridgehead>
96 <para role="required">
97 <xref linkend="glib2"/> and
98 <xref linkend="js68"/>
99 </para>
100
101 <bridgehead renderas="sect4">Recommended</bridgehead>
102 <para role="recommended">
103 <xref linkend="linux-pam"/><phrase revision="sysv"> and
104 <xref linkend="elogind"/></phrase>
105 </para>
106
107 <note>
108 <para>
109 Since <phrase revision="sysv"><command>elogind</command></phrase>
110 <phrase revision="systemd"><command>systemd-logind</command></phrase>
111 uses PAM to register user sessions, it is a good idea to build
112 <application>Polkit</application> with PAM support so
113 <phrase revision="sysv"><command>elogind</command></phrase>
114 <phrase revision="systemd"><command>systemd-logind</command></phrase>
115 can track <application>Polkit</application> sessions.
116 </para>
117 </note>
118
119
120 <bridgehead renderas="sect4">Optional (Required if building GNOME)</bridgehead>
121 <para role="optional">
122 <xref linkend="gobject-introspection"/>
123 </para>
124
125 <bridgehead renderas="sect4">Optional</bridgehead>
126 <para role="optional">
127 <xref linkend="dbus-python"/> and
128 <xref linkend="python-dbusmock"/> (for tests),
129 <xref linkend="DocBook"/>,
130 <xref linkend="docbook-xsl"/>,
131 <xref linkend="gtk-doc"/>, and
132 <xref linkend="libxslt"/>
133 </para>
134
135 <bridgehead renderas="sect4" revision="systemd">Required Runtime Dependencies</bridgehead>
136 <para role="required" revision="systemd">
137 <xref role="runtime" linkend="systemd"/>
138 </para>
139
140 <bridgehead renderas="sect4" id="polkit-agent" xreflabel="Polkit Authentication Agent">
141 Optional Runtime Dependencies
142 </bridgehead>
143 <para role="optional">
144 One polkit authentication agent for using polkit in the graphical
145 environment:
146 <application>polkit-kde-agent</application> in
147 <xref role="runtime" linkend="plasma5-build"/> for KDE,
148 the agent built in
149 <xref role="runtime" linkend="gnome-shell"/> for GNOME3,
150 <xref role="runtime" linkend="polkit-gnome"/> for XFCE, and
151 <application>lxpolkit</application> in
152 <xref role="runtime" linkend="lxsession"/> for LXDE.
153 </para>
154
155 <note>
156 <para>
157 If <xref linkend="libxslt"/> is installed,
158 then <xref linkend="DocBook"/> and <xref linkend="docbook-xsl"/> are
159 required. If you have installed <xref linkend="libxslt"/>, but you do
160 not want to install any of the DocBook packages mentioned, you will
161 need to use <option>--disable-man-pages</option> in the instructions
162 below.
163 </para>
164 </note>
165
166 <para condition="html" role="usernotes">User Notes:
167 <ulink url="&blfs-wiki;/polkit"/>
168 </para>
169 </sect2>
170
171 <sect2 role="installation">
172 <title>Installation of Polkit</title>
173
174 <para>
175 There should be a dedicated user and group to take control
176 of the <command>polkitd</command> daemon after it is
177 started. Issue the following commands as the
178 <systemitem class="username">root</systemitem> user:
179 </para>
180
181<screen role="root"><userinput>groupadd -fg 27 polkitd &amp;&amp;
182useradd -c "PolicyKit Daemon Owner" -d /etc/polkit-1 -u 27 \
183 -g polkitd -s /bin/false polkitd</userinput></screen>
184
185 <note revision="systemd">
186 <para>
187 When building <application>Polkit</application> with
188 <application>systemd</application> logind support, the
189 <command>configure</command> script explicitly checks if
190 system is booted using <application>systemd</application>.
191 This can cause problems if building the package in chroot,
192 where the <command>configure</command> would fail to
193 detect <application>systemd</application>. To workaround
194 the problem, simply run the following command:
195 </para>
196
197<screen><userinput>sed -i "s:/sys/fs/cgroup/systemd/:/sys:g" configure</userinput></screen>
198 </note>
199<!--
200 <para revision="sysv">
201 Fix an issue introduced in recent <application>Polkit</application>
202 realeases with elogind:
203 </para>
204
205<screen revision="sysv"><userinput>patch -Np1 -i ../polkit-&polkit-version;-fix_elogind_detection-1.patch &amp;&amp;
206autoreconf -fi</userinput></screen>
207-->
208 <para>
209 Install <application>Polkit</application> by running the following
210 commands:
211 </para>
212
213<screen revision="systemd"><userinput>./configure --prefix=/usr \
214 --sysconfdir=/etc \
215 --localstatedir=/var \
216 --disable-static \
217 --with-os-type=LFS &amp;&amp;
218make</userinput></screen>
219
220<screen revision="sysv"><userinput>./configure --prefix=/usr \
221 --sysconfdir=/etc \
222 --localstatedir=/var \
223 --disable-static \
224 --with-os-type=LFS \
225 --enable-libsystemd-login=no &amp;&amp;
226make</userinput></screen>
227
228 <para>
229 To test the results, issue: <command>make check</command>.
230 Note that system <application>D-Bus</application> daemon
231 must be running for the testsuite to complete.
232 </para>
233
234 <para>
235 Now, as the <systemitem class="username">root</systemitem> user:
236 </para>
237
238<screen role="root"><userinput>make install</userinput></screen>
239
240 </sect2>
241
242 <sect2 role="commands">
243 <title>Command Explanations</title>
244
245 <para>
246 <option>--with-authfw=shadow</option>: This switch enables the
247 package to use the <application>Shadow</application> rather than the
248 <application>Linux PAM</application> Authentication framework. Use it
249 if you have not installed <application>Linux PAM</application>.
250 </para>
251
252 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
253 href="../../xincludes/static-libraries.xml"/>
254
255 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
256 href="../../xincludes/gtk-doc-rebuild.xml"/>
257
258 <para revision="sysv">
259 <parameter>--enable-libsystemd-login=no</parameter>: This switch forces
260 polkit to build with elogind support (if available) rather than systemd.
261 </para>
262
263 </sect2>
264
265 <sect2 role="configuration">
266 <title>Configuring Polkit</title>
267
268 <sect3>
269 <title>PAM Configuration</title>
270
271 <note>
272 <para>
273 If you did not build <application>Polkit</application> with
274 <application>Linux PAM</application> support, you can skip this section.
275 </para>
276 </note>
277
278 <para>
279 If you have built <application>Polkit</application> with
280 <application>Linux PAM</application> support, you need to modify
281 the default PAM configuration file which was installed by default to get
282 <application>Polkit</application> to work correctly with BLFS. Issue the
283 following commands as the <systemitem class="username">root</systemitem>
284 user to create the configuration file for <application>Linux PAM</application>:
285 </para>
286
287<screen role="root"><userinput>cat &gt; /etc/pam.d/polkit-1 &lt;&lt; "EOF"
288<literal># Begin /etc/pam.d/polkit-1
289
290auth include system-auth
291account include system-account
292password include system-password
293session include system-session
294
295# End /etc/pam.d/polkit-1</literal>
296EOF</userinput></screen>
297
298 </sect3>
299
300 </sect2>
301
302 <sect2 role="content">
303 <title>Contents</title>
304
305 <segmentedlist>
306 <segtitle>Installed Programs</segtitle>
307 <segtitle>Installed Libraries</segtitle>
308 <segtitle>Installed Directories</segtitle>
309
310 <seglistitem>
311 <seg>
312 pkaction, pkcheck, pk-example-frobnicate, pkexec,
313 pkttyagent and polkitd
314 </seg>
315 <seg>
316 libpolkit-agent-1.so and
317 libpolkit-gobject-1.so
318 </seg>
319 <seg>
320 /etc/polkit-1,
321 /usr/include/polkit-1,
322 /usr/lib/polkit-1,
323 /usr/share/gtk-doc/html/polkit-1 and
324 /usr/share/polkit-1
325 </seg>
326 </seglistitem>
327 </segmentedlist>
328
329 <variablelist>
330 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
331 <?dbfo list-presentation="list"?>
332 <?dbhtml list-presentation="table"?>
333
334 <varlistentry id="pkaction">
335 <term><command>pkaction</command></term>
336 <listitem>
337 <para>
338 is used to obtain information about registered PolicyKit actions.
339 </para>
340 <indexterm zone="polkit pkaction">
341 <primary sortas="b-pkaction">pkaction</primary>
342 </indexterm>
343 </listitem>
344 </varlistentry>
345
346 <varlistentry id="pkcheck">
347 <term><command>pkcheck</command></term>
348 <listitem>
349 <para>
350 is used to check whether a process is authorized for action.
351 </para>
352 <indexterm zone="polkit pkcheck">
353 <primary sortas="b-pkcheck">pkcheck</primary>
354 </indexterm>
355 </listitem>
356 </varlistentry>
357
358 <varlistentry id="pk-example-frobnicate">
359 <term><command>pk-example-frobnicate</command></term>
360 <listitem>
361 <para>
362 is an example program to test the <command>pkexec</command>
363 command.
364 </para>
365 <indexterm zone="polkit pk-example-frobnicate">
366 <primary sortas="b-pk-example-frobnicate">pk-example-frobnicate</primary>
367 </indexterm>
368 </listitem>
369 </varlistentry>
370
371 <varlistentry id="pkexec">
372 <term><command>pkexec</command></term>
373 <listitem>
374 <para>
375 allows an authorized user to execute a command as another user.
376 </para>
377 <indexterm zone="polkit pkexec">
378 <primary sortas="b-pkexec">pkexec</primary>
379 </indexterm>
380 </listitem>
381 </varlistentry>
382
383 <varlistentry id="pkttyagent">
384 <term><command>pkttyagent</command></term>
385 <listitem>
386 <para>
387 is used to start a textual authentication agent for the subject.
388 </para>
389 <indexterm zone="polkit pkttyagent">
390 <primary sortas="b-pkttyagent">pkttyagent</primary>
391 </indexterm>
392 </listitem>
393 </varlistentry>
394
395 <varlistentry id="polkitd">
396 <term><command>polkitd</command></term>
397 <listitem>
398 <para>
399 provides the org.freedesktop.PolicyKit1 <application>D-Bus</application>
400 service on the system message bus.
401 </para>
402 <indexterm zone="polkit polkitd">
403 <primary sortas="b-polkitd">polkitd</primary>
404 </indexterm>
405 </listitem>
406 </varlistentry>
407
408 <varlistentry id="libpolkit-agent-1">
409 <term><filename class='libraryfile'>libpolkit-agent-1.so</filename></term>
410 <listitem>
411 <para>
412 contains the <application>Polkit</application> authentication
413 agent API functions.
414 </para>
415 <indexterm zone="polkit libpolkit-agent-1">
416 <primary sortas="c-libpolkit-agent-1">libpolkit-agent-1.so</primary>
417 </indexterm>
418 </listitem>
419 </varlistentry>
420
421 <varlistentry id="libpolkit-gobject-1">
422 <term><filename class='libraryfile'>libpolkit-gobject-1.so</filename></term>
423 <listitem>
424 <para>
425 contains the <application>Polkit</application> authorization API functions.
426 </para>
427 <indexterm zone="polkit libpolkit-gobject-1">
428 <primary sortas="c-libpolkit-gobject-1">libpolkit-gobject-1.so</primary>
429 </indexterm>
430 </listitem>
431 </varlistentry>
432
433 </variablelist>
434
435 </sect2>
436
437</sect1>
Note: See TracBrowser for help on using the repository browser.