source: postlfs/security/polkit.xml@ c432bc2

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 c432bc2 was c432bc2, checked in by Ken Moffat <ken@…>, 3 years ago

polkit: omit -i from autoreconf and add -v

Removing -i prevents gtk-doc being required to run autoreconf.

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

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