source: postlfs/security/polkit.xml@ 1017eed

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 9.0 9.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 1017eed was 1017eed, checked in by Pierre Labastie <pieere@…>, 5 years ago

Remove unneeded patch for polkit

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

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