[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
|
---|
[b84342d6] | 8 | "http://www.freedesktop.org/software/polkit/releases/polkit-&polkit-version;.tar.gz">
|
---|
[9d3d8a8] | 9 | <!ENTITY polkit-download-ftp " ">
|
---|
[7d511f08] | 10 | <!ENTITY polkit-md5sum "4b77776c9e4f897dcfe03b2c34198edf">
|
---|
[78e2a40] | 11 | <!ENTITY polkit-size "1.4 MB">
|
---|
[7d511f08] | 12 | <!ENTITY polkit-buildsize "15 MB">
|
---|
[7e900ba6] | 13 | <!ENTITY polkit-time "0.2 SBU">
|
---|
[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 |
|
---|
[df72afb4] | 39 | &lfs78_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>
|
---|
| 74 |
|
---|
[7d511f08] | 75 | <!-- <bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
---|
[ac38e9dc] | 76 | <itemizedlist spacing="compact">
|
---|
| 77 | <listitem>
|
---|
| 78 | <para>
|
---|
| 79 | Required patch:
|
---|
| 80 | <ulink url="&patch-root;/polkit-&polkit-version;-upstream_fixes-1.patch"/>
|
---|
| 81 | </para>
|
---|
| 82 | </listitem>
|
---|
[7d511f08] | 83 | </itemizedlist> -->
|
---|
[ac38e9dc] | 84 |
|
---|
[01996ebb] | 85 | <bridgehead renderas="sect3">Polkit Dependencies</bridgehead>
|
---|
[9d3d8a8] | 86 |
|
---|
| 87 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
[bb947c32] | 88 | <para role="required">
|
---|
[56605b9] | 89 | <xref linkend="glib2"/>, and
|
---|
[4cbfd95] | 90 | <xref linkend="JS"/>
|
---|
[4c2be438] | 91 | </para>
|
---|
| 92 |
|
---|
[459c449] | 93 | <bridgehead renderas="sect4">Recommended</bridgehead>
|
---|
[4da2d9f] | 94 | <para role="recommended">
|
---|
| 95 | <xref linkend="linux-pam"/>
|
---|
| 96 | </para>
|
---|
| 97 |
|
---|
| 98 | <note>
|
---|
| 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 |
|
---|
[4c2be438] | 107 | <bridgehead renderas="sect4">Optional (Required if building GNOME)</bridgehead>
|
---|
| 108 | <para role="optional">
|
---|
| 109 | <xref linkend="gobject-introspection"/>
|
---|
| 110 | </para>
|
---|
[9d3d8a8] | 111 |
|
---|
| 112 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
[bb947c32] | 113 | <para role="optional">
|
---|
[0d7900a] | 114 | <xref linkend="DocBook"/>,
|
---|
| 115 | <xref linkend="docbook-xsl"/>,
|
---|
[4da2d9f] | 116 | <xref linkend="gtk-doc"/>, and
|
---|
| 117 | <xref linkend="libxslt"/>
|
---|
| 118 | </para>
|
---|
| 119 |
|
---|
| 120 | <bridgehead renderas="sect4">Required Runtime Dependencies</bridgehead>
|
---|
| 121 | <para role="required">
|
---|
[ac38e9dc] | 122 | <xref linkend="systemd"/>
|
---|
[4c2be438] | 123 | </para>
|
---|
[875b4070] | 124 |
|
---|
| 125 | <note>
|
---|
[b84342d6] | 126 | <para>
|
---|
[9ca304a] | 127 | If <xref linkend="libxslt"/> is installed, then <xref linkend="DocBook"/>
|
---|
[3bbf74c5] | 128 | and <xref linkend="docbook-xsl"/> are required. If you have installed
|
---|
| 129 | <xref linkend="libxslt"/>, but you do not want to install any of the
|
---|
| 130 | DocBook packages mentioned, you will need to use
|
---|
| 131 | <option>--disable-man-pages</option> in the instructions below.
|
---|
[b84342d6] | 132 | </para>
|
---|
[875b4070] | 133 | </note>
|
---|
[9d3d8a8] | 134 |
|
---|
| 135 | <para condition="html" role="usernotes">User Notes:
|
---|
[37aba7f] | 136 | <ulink url="&blfs-wiki;/polkit"/>
|
---|
| 137 | </para>
|
---|
[9d3d8a8] | 138 | </sect2>
|
---|
| 139 |
|
---|
| 140 | <sect2 role="installation">
|
---|
[01996ebb] | 141 | <title>Installation of Polkit</title>
|
---|
[9d3d8a8] | 142 |
|
---|
[b84342d6] | 143 | <para>
|
---|
[01996ebb] | 144 | There should be a dedicated user and group to take control
|
---|
| 145 | of the <command>polkitd</command> daemon after it is
|
---|
| 146 | started. Issue the following commands as the
|
---|
| 147 | <systemitem class="username">root</systemitem> user:
|
---|
| 148 | </para>
|
---|
| 149 |
|
---|
| 150 | <screen role="root"><userinput>groupadd -fg 27 polkitd &&
|
---|
| 151 | useradd -c "PolicyKit Daemon Owner" -d /etc/polkit-1 -u 27 \
|
---|
| 152 | -g polkitd -s /bin/false polkitd</userinput></screen>
|
---|
| 153 |
|
---|
[5c198a0] | 154 | <note>
|
---|
| 155 | <para>
|
---|
| 156 | When building <application>Polkit</application> with
|
---|
| 157 | <application>systemd</application> logind support, the
|
---|
| 158 | <command>configure</command> script explicitly checks if
|
---|
| 159 | system is booted using <application>systemd</application>.
|
---|
| 160 | This can cause problems if building the package in chroot,
|
---|
| 161 | where the <command>configure</command> would fail to
|
---|
| 162 | detect <application>systemd</application>. To workaround
|
---|
[afab991a] | 163 | the problem, simply run the following command:
|
---|
[5c198a0] | 164 | </para>
|
---|
| 165 |
|
---|
| 166 | <screen><userinput>sed -i "s:/sys/fs/cgroup/systemd/:/sys:g" configure</userinput></screen>
|
---|
| 167 | </note>
|
---|
| 168 |
|
---|
[01996ebb] | 169 | <para>
|
---|
| 170 | Install <application>Polkit</application> by running the following
|
---|
[37aba7f] | 171 | commands:
|
---|
[b84342d6] | 172 | </para>
|
---|
[9d3d8a8] | 173 |
|
---|
[7d511f08] | 174 | <screen><userinput>./configure --prefix=/usr \
|
---|
| 175 | --sysconfdir=/etc \
|
---|
| 176 | --localstatedir=/var \
|
---|
| 177 | --disable-static &&
|
---|
[9d3d8a8] | 178 | make</userinput></screen>
|
---|
| 179 |
|
---|
[b84342d6] | 180 | <para>
|
---|
[01996ebb] | 181 | To test the results, issue: <command>make check</command>.
|
---|
[3bbf74c5] | 182 | Note that system <application>D-Bus</application> daemon
|
---|
| 183 | must be running for the testsuite to complete. There is
|
---|
| 184 | also a warning about <application>ConsoleKit</application>
|
---|
| 185 | database not present, but that one can be safely ignored.
|
---|
[b84342d6] | 186 | </para>
|
---|
[9d3d8a8] | 187 |
|
---|
[b84342d6] | 188 | <para>
|
---|
| 189 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 190 | </para>
|
---|
[9d3d8a8] | 191 |
|
---|
| 192 | <screen role="root"><userinput>make install</userinput></screen>
|
---|
| 193 |
|
---|
| 194 | </sect2>
|
---|
| 195 |
|
---|
| 196 | <sect2 role="commands">
|
---|
| 197 | <title>Command Explanations</title>
|
---|
| 198 |
|
---|
[4da2d9f] | 199 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
| 200 | href="../../xincludes/static-libraries.xml"/>
|
---|
[dbac0b14] | 201 |
|
---|
[b84342d6] | 202 | <para>
|
---|
[4da2d9f] | 203 | <option>--with-authfw=shadow</option>: This switch enables the
|
---|
[01996ebb] | 204 | package to use the <application>Shadow</application> rather than the
|
---|
[4da2d9f] | 205 | <application>Linux PAM</application> Authentication framework. Use it
|
---|
| 206 | if you have not installed <application>Linux PAM</application>.
|
---|
[b84342d6] | 207 | </para>
|
---|
| 208 |
|
---|
| 209 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
| 210 | href="../../xincludes/gtk-doc-rebuild.xml"/>
|
---|
[9d3d8a8] | 211 |
|
---|
| 212 | </sect2>
|
---|
| 213 |
|
---|
[a6bd736] | 214 | <sect2 role="configuration">
|
---|
[01996ebb] | 215 | <title>Configuring Polkit</title>
|
---|
[a6bd736] | 216 |
|
---|
| 217 | <sect3>
|
---|
| 218 | <title>PAM Configuration</title>
|
---|
| 219 |
|
---|
| 220 | <note>
|
---|
[b84342d6] | 221 | <para>
|
---|
[01996ebb] | 222 | If you did not build <application>Polkit</application> with
|
---|
[b84342d6] | 223 | <application>Linux PAM</application> support, you can skip this section.
|
---|
[a6bd736] | 224 | </para>
|
---|
| 225 | </note>
|
---|
| 226 |
|
---|
[b84342d6] | 227 | <para>
|
---|
[0d7900a] | 228 | If you have built <application>Polkit</application> with
|
---|
| 229 | <application>Linux PAM</application> support, you need to modify
|
---|
[9ca304a] | 230 | the default PAM configuration file which was installed by default to get
|
---|
| 231 | <application>Polkit</application> to work correctly with BLFS. Issue the
|
---|
| 232 | following commands as the <systemitem class="username">root</systemitem>
|
---|
[b84342d6] | 233 | user to create the configuration file for <application>Linux PAM</application>:
|
---|
[a6bd736] | 234 | </para>
|
---|
| 235 |
|
---|
| 236 | <screen role="root"><userinput>cat > /etc/pam.d/polkit-1 << "EOF"
|
---|
| 237 | <literal># Begin /etc/pam.d/polkit-1
|
---|
| 238 |
|
---|
| 239 | auth include system-auth
|
---|
| 240 | account include system-account
|
---|
| 241 | password include system-password
|
---|
| 242 | session include system-session
|
---|
| 243 |
|
---|
| 244 | # End /etc/pam.d/polkit-1</literal>
|
---|
| 245 | EOF</userinput></screen>
|
---|
| 246 |
|
---|
| 247 | </sect3>
|
---|
| 248 |
|
---|
| 249 | </sect2>
|
---|
| 250 |
|
---|
[9d3d8a8] | 251 | <sect2 role="content">
|
---|
| 252 | <title>Contents</title>
|
---|
| 253 |
|
---|
| 254 | <segmentedlist>
|
---|
| 255 | <segtitle>Installed Programs</segtitle>
|
---|
| 256 | <segtitle>Installed Libraries</segtitle>
|
---|
| 257 | <segtitle>Installed Directories</segtitle>
|
---|
| 258 |
|
---|
| 259 | <seglistitem>
|
---|
[b84342d6] | 260 | <seg>
|
---|
[f342c0a9] | 261 | pkaction, pkcheck, pk-example-frobnicate, pkexec,
|
---|
| 262 | pkttyagent and polkitd
|
---|
[b84342d6] | 263 | </seg>
|
---|
| 264 | <seg>
|
---|
[0d7900a] | 265 | libpolkit-agent-1.so and
|
---|
[b84342d6] | 266 | libpolkit-gobject-1.so
|
---|
| 267 | </seg>
|
---|
[028759b] | 268 | <seg>
|
---|
[01996ebb] | 269 | /etc/polkit-1,
|
---|
| 270 | /usr/include/polkit-1,
|
---|
| 271 | /usr/lib/polkit-1,
|
---|
| 272 | /usr/share/gtk-doc/html/polkit-1 and
|
---|
[028759b] | 273 | /usr/share/polkit-1
|
---|
[b84342d6] | 274 | </seg>
|
---|
[9d3d8a8] | 275 | </seglistitem>
|
---|
| 276 | </segmentedlist>
|
---|
| 277 |
|
---|
| 278 | <variablelist>
|
---|
| 279 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 280 | <?dbfo list-presentation="list"?>
|
---|
| 281 | <?dbhtml list-presentation="table"?>
|
---|
| 282 |
|
---|
| 283 | <varlistentry id="pkaction">
|
---|
| 284 | <term><command>pkaction</command></term>
|
---|
| 285 | <listitem>
|
---|
[b84342d6] | 286 | <para>
|
---|
| 287 | is used to obtain information about registered PolicyKit actions.
|
---|
| 288 | </para>
|
---|
[9d3d8a8] | 289 | <indexterm zone="polkit pkaction">
|
---|
| 290 | <primary sortas="b-pkaction">pkaction</primary>
|
---|
| 291 | </indexterm>
|
---|
| 292 | </listitem>
|
---|
| 293 | </varlistentry>
|
---|
| 294 |
|
---|
| 295 | <varlistentry id="pkcheck">
|
---|
| 296 | <term><command>pkcheck</command></term>
|
---|
| 297 | <listitem>
|
---|
[b84342d6] | 298 | <para>
|
---|
| 299 | is used to check whether a process is authorized for action.
|
---|
| 300 | </para>
|
---|
[9d3d8a8] | 301 | <indexterm zone="polkit pkcheck">
|
---|
| 302 | <primary sortas="b-pkcheck">pkcheck</primary>
|
---|
| 303 | </indexterm>
|
---|
| 304 | </listitem>
|
---|
| 305 | </varlistentry>
|
---|
| 306 |
|
---|
[cb0bbd2] | 307 | <varlistentry id="pk-example-frobnicate">
|
---|
| 308 | <term><command>pk-example-frobnicate</command></term>
|
---|
| 309 | <listitem>
|
---|
| 310 | <para>
|
---|
| 311 | is an example program to test the <command>pkexec</command>
|
---|
| 312 | command.
|
---|
| 313 | </para>
|
---|
| 314 | <indexterm zone="polkit pk-example-frobnicate">
|
---|
| 315 | <primary sortas="b-pk-example-frobnicate">pk-example-frobnicate</primary>
|
---|
| 316 | </indexterm>
|
---|
| 317 | </listitem>
|
---|
| 318 | </varlistentry>
|
---|
| 319 |
|
---|
[9d3d8a8] | 320 | <varlistentry id="pkexec">
|
---|
| 321 | <term><command>pkexec</command></term>
|
---|
| 322 | <listitem>
|
---|
[b84342d6] | 323 | <para>
|
---|
| 324 | allows an authorized user to execute a command as another user.
|
---|
| 325 | </para>
|
---|
[9d3d8a8] | 326 | <indexterm zone="polkit pkexec">
|
---|
| 327 | <primary sortas="b-pkexec">pkexec</primary>
|
---|
| 328 | </indexterm>
|
---|
| 329 | </listitem>
|
---|
| 330 | </varlistentry>
|
---|
| 331 |
|
---|
[b84342d6] | 332 | <varlistentry id="pkttyagent">
|
---|
| 333 | <term><command>pkttyagent</command></term>
|
---|
[9d3d8a8] | 334 | <listitem>
|
---|
[b84342d6] | 335 | <para>
|
---|
| 336 | is used to start a textual authentication agent for the subject.
|
---|
| 337 | </para>
|
---|
| 338 | <indexterm zone="polkit pkttyagent">
|
---|
| 339 | <primary sortas="b-pkttyagent">pkttyagent</primary>
|
---|
[9d3d8a8] | 340 | </indexterm>
|
---|
| 341 | </listitem>
|
---|
[b84342d6] | 342 | </varlistentry>
|
---|
[9d3d8a8] | 343 |
|
---|
[875b4070] | 344 | <varlistentry id="polkitd">
|
---|
[9d3d8a8] | 345 | <term><command>polkitd</command></term>
|
---|
| 346 | <listitem>
|
---|
[b84342d6] | 347 | <para>
|
---|
[0d7900a] | 348 | provides the org.freedesktop.PolicyKit1 <application>D-Bus</application>
|
---|
[b84342d6] | 349 | service on the system message bus.
|
---|
| 350 | </para>
|
---|
[875b4070] | 351 | <indexterm zone="polkit polkitd">
|
---|
[9d3d8a8] | 352 | <primary sortas="b-polkitd">polkitd</primary>
|
---|
| 353 | </indexterm>
|
---|
| 354 | </listitem>
|
---|
| 355 | </varlistentry>
|
---|
| 356 |
|
---|
| 357 | <varlistentry id="libpolkit-agent-1">
|
---|
[b84342d6] | 358 | <term><filename class='libraryfile'>libpolkit-agent-1.so</filename></term>
|
---|
[9d3d8a8] | 359 | <listitem>
|
---|
[b84342d6] | 360 | <para>
|
---|
[01996ebb] | 361 | contains the <application>Polkit</application> authentication
|
---|
[b84342d6] | 362 | agent API functions.
|
---|
| 363 | </para>
|
---|
[9d3d8a8] | 364 | <indexterm zone="polkit libpolkit-agent-1">
|
---|
[b84342d6] | 365 | <primary sortas="c-libpolkit-agent-1">libpolkit-agent-1.so</primary>
|
---|
[9d3d8a8] | 366 | </indexterm>
|
---|
| 367 | </listitem>
|
---|
| 368 | </varlistentry>
|
---|
| 369 |
|
---|
| 370 | <varlistentry id="libpolkit-gobject-1">
|
---|
[b84342d6] | 371 | <term><filename class='libraryfile'>libpolkit-gobject-1.so</filename></term>
|
---|
[9d3d8a8] | 372 | <listitem>
|
---|
[b84342d6] | 373 | <para>
|
---|
[01996ebb] | 374 | contains the <application>Polkit</application> authorization API functions.
|
---|
[b84342d6] | 375 | </para>
|
---|
[9d3d8a8] | 376 | <indexterm zone="polkit libpolkit-gobject-1">
|
---|
[b84342d6] | 377 | <primary sortas="c-libpolkit-gobject-1">libpolkit-gobject-1.so</primary>
|
---|
[9d3d8a8] | 378 | </indexterm>
|
---|
| 379 | </listitem>
|
---|
| 380 | </varlistentry>
|
---|
| 381 |
|
---|
| 382 | </variablelist>
|
---|
| 383 |
|
---|
| 384 | </sect2>
|
---|
| 385 |
|
---|
| 386 | </sect1>
|
---|