[cf341b4] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
| 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
|
---|
| 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
| 7 | <!ENTITY sudo-download-http "http://www.courtesan.com/sudo/dist/sudo-&sudo-version;.tar.gz">
|
---|
| 8 | <!ENTITY sudo-download-ftp " ">
|
---|
| 9 | <!ENTITY sudo-md5sum "b29893c06192df6230dd5f340f3badf5">
|
---|
| 10 | <!ENTITY sudo-size "576 KB">
|
---|
| 11 | <!ENTITY sudo-buildsize "3.6 MB">
|
---|
| 12 | <!ENTITY sudo-time "less than 0.1 SBU">
|
---|
| 13 | ]>
|
---|
| 14 |
|
---|
| 15 | <sect1 id="sudo" xreflabel="sudo-&sudo-version;">
|
---|
| 16 | <?dbhtml filename="sudo.html"?>
|
---|
| 17 |
|
---|
| 18 | <sect1info>
|
---|
[e19ad480] | 19 | <othername>$LastChangedBy$</othername>
|
---|
| 20 | <date>$Date$</date>
|
---|
| 21 | <keywordset>
|
---|
| 22 | <keyword role="package">sudo-&sudo-version;.tar</keyword>
|
---|
[9084c2eb] | 23 | <keyword role="ftpdir">sudo</keyword>
|
---|
[e19ad480] | 24 | </keywordset>
|
---|
[cf341b4] | 25 | </sect1info>
|
---|
| 26 |
|
---|
| 27 | <title>Sudo-&sudo-version;</title>
|
---|
| 28 |
|
---|
| 29 | <indexterm zone="sudo">
|
---|
| 30 | <primary sortas="a-sudo">sudo</primary>
|
---|
| 31 | </indexterm>
|
---|
| 32 |
|
---|
| 33 | <sect2 role="package">
|
---|
| 34 | <title>Introduction to Sudo</title>
|
---|
| 35 |
|
---|
| 36 | <para>The <application>sudo</application> package allows a system
|
---|
| 37 | administrator to give certain users (or groups of users) the ability to run
|
---|
[33d90fe] | 38 | some (or all) commands as
|
---|
| 39 | <systemitem class="username">root</systemitem> or another user while
|
---|
| 40 | logging the commands and arguments.</para>
|
---|
[cf341b4] | 41 |
|
---|
| 42 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 43 | <itemizedlist spacing="compact">
|
---|
| 44 | <listitem>
|
---|
| 45 | <para>Download (HTTP): <ulink url="&sudo-download-http;"/></para>
|
---|
| 46 | </listitem>
|
---|
| 47 | <listitem>
|
---|
| 48 | <para>Download (FTP): <ulink url="&sudo-download-ftp;"/></para>
|
---|
| 49 | </listitem>
|
---|
| 50 | <listitem>
|
---|
| 51 | <para>Download MD5 sum: &sudo-md5sum;</para>
|
---|
| 52 | </listitem>
|
---|
| 53 | <listitem>
|
---|
| 54 | <para>Download size: &sudo-size;</para>
|
---|
| 55 | </listitem>
|
---|
| 56 | <listitem>
|
---|
| 57 | <para>Estimated disk space required: &sudo-buildsize;</para>
|
---|
| 58 | </listitem>
|
---|
| 59 | <listitem>
|
---|
| 60 | <para>Estimated build time: &sudo-time;</para>
|
---|
| 61 | </listitem>
|
---|
| 62 | </itemizedlist>
|
---|
| 63 |
|
---|
| 64 | <!--
|
---|
| 65 | <bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
---|
| 66 | <itemizedlist spacing='compact'>
|
---|
| 67 | <listitem>
|
---|
| 68 | <para>Required patch: <ulink
|
---|
| 69 | url="&patch-root;/sudo-&sudo-version;-xxxx-1.patch"/></para>
|
---|
| 70 | </listitem>
|
---|
| 71 | </itemizedlist>
|
---|
| 72 | <bridgehead renderas="sect3">Sudo Dependencies</bridgehead>
|
---|
| 73 |
|
---|
| 74 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
[bccbdaea] | 75 |
|
---|
| 76 |
|
---|
[cf341b4] | 77 | -->
|
---|
| 78 | </sect2>
|
---|
| 79 |
|
---|
| 80 | <sect2 role="installation">
|
---|
| 81 | <title>Installation of Sudo</title>
|
---|
| 82 |
|
---|
| 83 | <para>Install <application>sudo</application> by running
|
---|
| 84 | the following commands:</para>
|
---|
| 85 |
|
---|
[3c0f868f] | 86 | <screen><userinput>./configure --prefix=/usr --libexecdir=/usr/lib \
|
---|
[74169a7c] | 87 | --enable-noargs-shell --with-ignore-dot --with-all-insults \
|
---|
| 88 | --enable-shell-sets-home &&
|
---|
[cf341b4] | 89 | make</userinput></screen>
|
---|
| 90 |
|
---|
| 91 | <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
|
---|
| 92 |
|
---|
| 93 | <screen role="root"><userinput>make install</userinput></screen>
|
---|
| 94 |
|
---|
| 95 | </sect2>
|
---|
| 96 |
|
---|
| 97 | <sect2 role="commands">
|
---|
| 98 | <title>Command Explanations</title>
|
---|
| 99 |
|
---|
[33d90fe] | 100 | <para><option>--enable-noargs-shell</option>: This switch allows
|
---|
| 101 | <application>sudo</application> to run a shell if invoked with no
|
---|
| 102 | arguments.</para>
|
---|
[cf341b4] | 103 |
|
---|
| 104 | <para><option>--with-ignore-dot</option>: This switch causes
|
---|
| 105 | <application>sudo</application> to ignore '.' in the PATH.</para>
|
---|
| 106 |
|
---|
| 107 | <para><option>--with-all-insults</option>: This switch includes all the
|
---|
[33d90fe] | 108 | <application>sudo</application> insult sets.</para>
|
---|
[cf341b4] | 109 |
|
---|
[74169a7c] | 110 | <para><option>--enable-shell-sets-home</option>: This switch sets HOME to
|
---|
| 111 | the target user in shell mode.</para>
|
---|
| 112 |
|
---|
[33d90fe] | 113 | <note>
|
---|
| 114 | <para>There are many options to <application>sudo</application>'s
|
---|
| 115 | <command>configure</command> command. Check the
|
---|
| 116 | <command>configure --help</command> output for a complete list.</para>
|
---|
| 117 | </note>
|
---|
[cf341b4] | 118 |
|
---|
| 119 | </sect2>
|
---|
| 120 |
|
---|
| 121 | <sect2 role="configuration">
|
---|
| 122 | <title>Configuring Sudo</title>
|
---|
| 123 |
|
---|
| 124 | <sect3 id="sudo-config">
|
---|
| 125 | <title>Config File</title>
|
---|
| 126 |
|
---|
| 127 | <para><filename>/etc/sudoers</filename></para>
|
---|
| 128 |
|
---|
| 129 | <indexterm zone="sudo sudo-config">
|
---|
| 130 | <primary sortas="e-etc-sudoers">/etc/sudoers</primary>
|
---|
| 131 | </indexterm>
|
---|
| 132 |
|
---|
| 133 | </sect3>
|
---|
| 134 |
|
---|
| 135 | <sect3>
|
---|
| 136 | <title>Configuration Information</title>
|
---|
| 137 |
|
---|
| 138 | <para>The <filename>sudoers</filename> file can be quite complicated. It
|
---|
| 139 | is composed of two types of entries: aliases (basically variables) and
|
---|
| 140 | user specifications (which specify who may run what). The installation
|
---|
| 141 | installs a default configuration that has no privileges installed for any
|
---|
| 142 | user.</para>
|
---|
| 143 |
|
---|
| 144 | <para>One example usage is to allow the system administrator to execute
|
---|
| 145 | any program without typing a password each time root privileges are
|
---|
| 146 | needed. This can be configured as:</para>
|
---|
[bccbdaea] | 147 |
|
---|
[cf341b4] | 148 | <screen># User alias specification
|
---|
| 149 | User_Alias ADMIN = YourLoginId
|
---|
| 150 |
|
---|
| 151 | # Allow people in group ADMIN to run all commands without a password
|
---|
| 152 | ADMIN ALL = NOPASSWD: ALL</screen>
|
---|
| 153 |
|
---|
| 154 | <para>For details, see <command>man sudoers</command>.</para>
|
---|
| 155 |
|
---|
[3c0f868f] | 156 | <note>
|
---|
| 157 | <para>The <application>Sudo</application> developers highly recommend
|
---|
| 158 | using the <command>visudo</command> program to edit the
|
---|
| 159 | <filename>sudoers</filename> file. This will provide basic sanity
|
---|
| 160 | checking like syntax parsing and file permission to avoid some possible
|
---|
| 161 | mistakes that could lead to a vulnerable configuration.</para>
|
---|
| 162 | </note>
|
---|
| 163 |
|
---|
[cf341b4] | 164 | </sect3>
|
---|
| 165 |
|
---|
| 166 | </sect2>
|
---|
| 167 |
|
---|
| 168 | <sect2 role="content">
|
---|
| 169 | <title>Contents</title>
|
---|
| 170 |
|
---|
| 171 | <segmentedlist>
|
---|
| 172 | <segtitle>Installed Programs</segtitle>
|
---|
| 173 | <segtitle>Installed Library</segtitle>
|
---|
| 174 | <segtitle>Installed Directories</segtitle>
|
---|
| 175 |
|
---|
| 176 | <seglistitem>
|
---|
[3c0f868f] | 177 | <seg>sudo, sudoedit, and visudo</seg>
|
---|
[cf341b4] | 178 | <seg>sudo_noexec.so</seg>
|
---|
| 179 | <seg>None</seg>
|
---|
| 180 | </seglistitem>
|
---|
| 181 | </segmentedlist>
|
---|
| 182 |
|
---|
| 183 | <variablelist>
|
---|
| 184 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 185 | <?dbfo list-presentation="list"?>
|
---|
| 186 | <?dbhtml list-presentation="table"?>
|
---|
| 187 |
|
---|
| 188 | <varlistentry id="sudo_prog">
|
---|
| 189 | <term><command>sudo</command></term>
|
---|
| 190 | <listitem>
|
---|
| 191 | <para>executes a command as another user as permitted by
|
---|
[33d90fe] | 192 | the <filename>/etc/sudoers</filename> configuration file.
|
---|
[cf341b4] | 193 | </para>
|
---|
| 194 | <indexterm zone="sudo sudo">
|
---|
| 195 | <primary sortas="b-sudo">sudo</primary>
|
---|
| 196 | </indexterm>
|
---|
| 197 | </listitem>
|
---|
| 198 | </varlistentry>
|
---|
| 199 |
|
---|
| 200 | <varlistentry id="sudoedit">
|
---|
| 201 | <term><command>sudoedit</command></term>
|
---|
| 202 | <listitem>
|
---|
| 203 | <para>is a hard link to <command>sudo</command> that implies
|
---|
[33d90fe] | 204 | the <option>-e</option> option to invoke an editor as another
|
---|
| 205 | user.</para>
|
---|
[cf341b4] | 206 | <indexterm zone="sudo sudoedit">
|
---|
| 207 | <primary sortas="b-sudoedit">sudoedit</primary>
|
---|
| 208 | </indexterm>
|
---|
| 209 | </listitem>
|
---|
| 210 | </varlistentry>
|
---|
| 211 |
|
---|
[3c0f868f] | 212 | <varlistentry id="visudo">
|
---|
| 213 | <term><command>visudo</command></term>
|
---|
| 214 | <listitem>
|
---|
| 215 | <para>allows for safer editing of the <filename>sudoers</filename>
|
---|
| 216 | file.</para>
|
---|
| 217 | <indexterm zone="sudo visudo">
|
---|
| 218 | <primary sortas="b-visudo">visudo</primary>
|
---|
| 219 | </indexterm>
|
---|
| 220 | </listitem>
|
---|
| 221 | </varlistentry>
|
---|
| 222 |
|
---|
| 223 |
|
---|
[cf341b4] | 224 | <varlistentry id="sudo_noexec">
|
---|
| 225 | <term><filename class='libraryfile'>sudo_noexec.so</filename></term>
|
---|
| 226 | <listitem>
|
---|
| 227 | <para>enables support for the "noexec" functionality which prevents
|
---|
| 228 | a dynamically-linked program being run by sudo from executing
|
---|
| 229 | another program (think shell escapes).</para>
|
---|
| 230 | <indexterm zone="sudo sudo_noexec">
|
---|
| 231 | <primary sortas="c-sudo_noexec">sudo_noexec.so</primary>
|
---|
| 232 | </indexterm>
|
---|
| 233 | </listitem>
|
---|
| 234 | </varlistentry>
|
---|
| 235 |
|
---|
| 236 | </variablelist>
|
---|
| 237 |
|
---|
| 238 | </sect2>
|
---|
| 239 |
|
---|
| 240 | </sect1>
|
---|