source: postlfs/security/polkit.xml@ 9da30c5

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 9da30c5 was 9da30c5, checked in by Douglas R. Reno <renodr@…>, 5 years ago

systemd: Remove unneccesary carriage return in polkit

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@21618 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
[9da30c5]192<screen revision="systemd"><userinput>./configure --prefix=/usr \
[55c80c6]193 --sysconfdir=/etc \
194 --localstatedir=/var \
195 --disable-static \
196 --with-os-type=LFS &amp;&amp;
[f586237]197make</userinput></screen>
198
[b84342d6]199 <para>
[01996ebb]200 To test the results, issue: <command>make check</command>.
[3bbf74c5]201 Note that system <application>D-Bus</application> daemon
[55c80c6]202 must be running for the testsuite to complete.
[b84342d6]203 </para>
[9d3d8a8]204
[b84342d6]205 <para>
206 Now, as the <systemitem class="username">root</systemitem> user:
207 </para>
[9d3d8a8]208
209<screen role="root"><userinput>make install</userinput></screen>
210
211 </sect2>
212
213 <sect2 role="commands">
214 <title>Command Explanations</title>
215
[f586237]216 <para revision="sysv">
[b4ec1126]217 <parameter>--enable-libsystemd-login=no</parameter>: This parameter fixes
218 building without <application>systemd</application>, which is not part
219 of LFS/BLFS. If you use <application>systemd</application>,
220 replace "no" by "yes".
[dbac0b14]221 </para>
222
[f586237]223 <para revision="sysv">
[01996ebb]224 <parameter>--with-authfw=shadow</parameter>: This parameter configures the
225 package to use the <application>Shadow</application> rather than the
[6d03f3e]226 <application>Linux-PAM</application> Authentication framework. Change
227 the argument to 'pam' if you would like to use
228 <application>Linux-PAM</application>.
[f586237]229 </para>
230
231 <para revision="systemd">
232 <option>--with-authfw=shadow</option>: This switch enables the
233 package to use the <application>Shadow</application> rather than the
234 <application>Linux PAM</application> Authentication framework. Use it
235 if you have not installed <application>Linux PAM</application>.
[b84342d6]236 </para>
237
238 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
239 href="../../xincludes/static-libraries.xml"/>
[875b4070]240
[e05cd03f]241 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
[b84342d6]242 href="../../xincludes/gtk-doc-rebuild.xml"/>
[9d3d8a8]243
244 </sect2>
245
[a6bd736]246 <sect2 role="configuration">
[01996ebb]247 <title>Configuring Polkit</title>
[a6bd736]248
249 <sect3>
250 <title>PAM Configuration</title>
251
252 <note>
[b84342d6]253 <para>
[01996ebb]254 If you did not build <application>Polkit</application> with
[b84342d6]255 <application>Linux PAM</application> support, you can skip this section.
[a6bd736]256 </para>
257 </note>
258
[b84342d6]259 <para>
[0d7900a]260 If you have built <application>Polkit</application> with
261 <application>Linux PAM</application> support, you need to modify
[9ca304a]262 the default PAM configuration file which was installed by default to get
263 <application>Polkit</application> to work correctly with BLFS. Issue the
264 following commands as the <systemitem class="username">root</systemitem>
[b84342d6]265 user to create the configuration file for <application>Linux PAM</application>:
[a6bd736]266 </para>
267
268<screen role="root"><userinput>cat &gt; /etc/pam.d/polkit-1 &lt;&lt; "EOF"
269<literal># Begin /etc/pam.d/polkit-1
270
271auth include system-auth
272account include system-account
273password include system-password
274session include system-session
275
276# End /etc/pam.d/polkit-1</literal>
277EOF</userinput></screen>
278
279 </sect3>
280
281 </sect2>
282
[9d3d8a8]283 <sect2 role="content">
284 <title>Contents</title>
285
286 <segmentedlist>
287 <segtitle>Installed Programs</segtitle>
288 <segtitle>Installed Libraries</segtitle>
289 <segtitle>Installed Directories</segtitle>
290
291 <seglistitem>
[b84342d6]292 <seg>
[f342c0a9]293 pkaction, pkcheck, pk-example-frobnicate, pkexec,
294 pkttyagent and polkitd
[b84342d6]295 </seg>
296 <seg>
[0d7900a]297 libpolkit-agent-1.so and
[b84342d6]298 libpolkit-gobject-1.so
299 </seg>
[028759b]300 <seg>
[01996ebb]301 /etc/polkit-1,
302 /usr/include/polkit-1,
303 /usr/lib/polkit-1,
304 /usr/share/gtk-doc/html/polkit-1 and
[028759b]305 /usr/share/polkit-1
[b84342d6]306 </seg>
[9d3d8a8]307 </seglistitem>
308 </segmentedlist>
309
310 <variablelist>
311 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
312 <?dbfo list-presentation="list"?>
313 <?dbhtml list-presentation="table"?>
314
315 <varlistentry id="pkaction">
316 <term><command>pkaction</command></term>
317 <listitem>
[b84342d6]318 <para>
319 is used to obtain information about registered PolicyKit actions.
320 </para>
[9d3d8a8]321 <indexterm zone="polkit pkaction">
322 <primary sortas="b-pkaction">pkaction</primary>
323 </indexterm>
324 </listitem>
325 </varlistentry>
326
327 <varlistentry id="pkcheck">
328 <term><command>pkcheck</command></term>
329 <listitem>
[b84342d6]330 <para>
331 is used to check whether a process is authorized for action.
332 </para>
[9d3d8a8]333 <indexterm zone="polkit pkcheck">
334 <primary sortas="b-pkcheck">pkcheck</primary>
335 </indexterm>
336 </listitem>
337 </varlistentry>
338
[72d90b67]339 <varlistentry id="pk-example-frobnicate">
340 <term><command>pk-example-frobnicate</command></term>
341 <listitem>
342 <para>
343 is an example program to test the <command>pkexec</command>
344 command.
345 </para>
346 <indexterm zone="polkit pk-example-frobnicate">
347 <primary sortas="b-pk-example-frobnicate">pk-example-frobnicate</primary>
348 </indexterm>
349 </listitem>
350 </varlistentry>
351
[9d3d8a8]352 <varlistentry id="pkexec">
353 <term><command>pkexec</command></term>
354 <listitem>
[b84342d6]355 <para>
356 allows an authorized user to execute a command as another user.
357 </para>
[9d3d8a8]358 <indexterm zone="polkit pkexec">
359 <primary sortas="b-pkexec">pkexec</primary>
360 </indexterm>
361 </listitem>
362 </varlistentry>
363
[b84342d6]364 <varlistentry id="pkttyagent">
365 <term><command>pkttyagent</command></term>
[9d3d8a8]366 <listitem>
[b84342d6]367 <para>
368 is used to start a textual authentication agent for the subject.
369 </para>
370 <indexterm zone="polkit pkttyagent">
371 <primary sortas="b-pkttyagent">pkttyagent</primary>
[9d3d8a8]372 </indexterm>
373 </listitem>
[b84342d6]374 </varlistentry>
[9d3d8a8]375
[875b4070]376 <varlistentry id="polkitd">
[9d3d8a8]377 <term><command>polkitd</command></term>
378 <listitem>
[b84342d6]379 <para>
[0d7900a]380 provides the org.freedesktop.PolicyKit1 <application>D-Bus</application>
[b84342d6]381 service on the system message bus.
382 </para>
[875b4070]383 <indexterm zone="polkit polkitd">
[9d3d8a8]384 <primary sortas="b-polkitd">polkitd</primary>
385 </indexterm>
386 </listitem>
387 </varlistentry>
388
389 <varlistentry id="libpolkit-agent-1">
[b84342d6]390 <term><filename class='libraryfile'>libpolkit-agent-1.so</filename></term>
[9d3d8a8]391 <listitem>
[b84342d6]392 <para>
[01996ebb]393 contains the <application>Polkit</application> authentication
[b84342d6]394 agent API functions.
395 </para>
[9d3d8a8]396 <indexterm zone="polkit libpolkit-agent-1">
[b84342d6]397 <primary sortas="c-libpolkit-agent-1">libpolkit-agent-1.so</primary>
[9d3d8a8]398 </indexterm>
399 </listitem>
400 </varlistentry>
401
402 <varlistentry id="libpolkit-gobject-1">
[b84342d6]403 <term><filename class='libraryfile'>libpolkit-gobject-1.so</filename></term>
[9d3d8a8]404 <listitem>
[b84342d6]405 <para>
[01996ebb]406 contains the <application>Polkit</application> authorization API functions.
[b84342d6]407 </para>
[9d3d8a8]408 <indexterm zone="polkit libpolkit-gobject-1">
[b84342d6]409 <primary sortas="c-libpolkit-gobject-1">libpolkit-gobject-1.so</primary>
[9d3d8a8]410 </indexterm>
411 </listitem>
412 </varlistentry>
413
414 </variablelist>
415
416 </sect2>
417
418</sect1>
Note: See TracBrowser for help on using the repository browser.