source: postlfs/security/sudo.xml@ 310648f

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 6.2 6.2.0 6.2.0-rc1 6.2.0-rc2 6.3 6.3-rc1 6.3-rc2 6.3-rc3 7.10 7.4 7.5 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts krejzi/svn lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition systemd-11177 systemd-13485 trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since 310648f was 3597eb6, checked in by Randy McMurchy <randy@…>, 18 years ago

Added the 'User Notes' wiki link to each package page; changed all instances of .[so,a] to .{so,a} (brackets changed to braces); changed all replaceable tags to use angle brackets instead of square brackets to encapsulate the text - commit #7

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

  • Property mode set to 100644
File size: 7.8 KB
Line 
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>
19 <othername>$LastChangedBy$</othername>
20 <date>$Date$</date>
21 <keywordset>
22 <keyword role="package">sudo-&sudo-version;.tar</keyword>
23 <keyword role="ftpdir">sudo</keyword>
24 </keywordset>
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
38 some (or all) commands as
39 <systemitem class="username">root</systemitem> or another user while
40 logging the commands and arguments.</para>
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 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
65 <itemizedlist spacing='compact'>
66 <listitem>
67 <para>Required patch: <ulink
68 url="&patch-root;/sudo-&sudo-version;-envvar_fix-1.patch"/></para>
69 </listitem>
70 </itemizedlist>
71<!--
72 <bridgehead renderas="sect3">Sudo Dependencies</bridgehead>
73
74 <bridgehead renderas="sect4">Optional</bridgehead>
75-->
76
77 <para condition="html" role="usernotes">User Notes:
78 <ulink url="&blfs-wiki;/sudo"/></para>
79
80 </sect2>
81
82 <sect2 role="installation">
83 <title>Installation of Sudo</title>
84
85 <para>Install <application>sudo</application> by running
86 the following commands:</para>
87
88<screen><userinput>patch -Np1 -i ../sudo-&sudo-version;-envvar_fix-1.patch &amp;&amp;
89./configure --prefix=/usr --libexecdir=/usr/lib \
90 --enable-noargs-shell --with-ignore-dot --with-all-insults \
91 --enable-shell-sets-home &amp;&amp;
92make</userinput></screen>
93
94 <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
95
96<screen role="root"><userinput>make install</userinput></screen>
97
98 </sect2>
99
100 <sect2 role="commands">
101 <title>Command Explanations</title>
102
103 <para><option>--enable-noargs-shell</option>: This switch allows
104 <application>sudo</application> to run a shell if invoked with no
105 arguments.</para>
106
107 <para><option>--with-ignore-dot</option>: This switch causes
108 <application>sudo</application> to ignore '.' in the PATH.</para>
109
110 <para><option>--with-all-insults</option>: This switch includes all the
111 <application>sudo</application> insult sets.</para>
112
113 <para><option>--enable-shell-sets-home</option>: This switch sets HOME to
114 the target user in shell mode.</para>
115
116 <note>
117 <para>There are many options to <application>sudo</application>'s
118 <command>configure</command> command. Check the
119 <command>configure --help</command> output for a complete list.</para>
120 </note>
121
122 </sect2>
123
124 <sect2 role="configuration">
125 <title>Configuring Sudo</title>
126
127 <sect3 id="sudo-config">
128 <title>Config File</title>
129
130 <para><filename>/etc/sudoers</filename></para>
131
132 <indexterm zone="sudo sudo-config">
133 <primary sortas="e-etc-sudoers">/etc/sudoers</primary>
134 </indexterm>
135
136 </sect3>
137
138 <sect3>
139 <title>Configuration Information</title>
140
141 <para>The <filename>sudoers</filename> file can be quite complicated. It
142 is composed of two types of entries: aliases (basically variables) and
143 user specifications (which specify who may run what). The installation
144 installs a default configuration that has no privileges installed for any
145 user.</para>
146
147 <para>One example usage is to allow the system administrator to execute
148 any program without typing a password each time root privileges are
149 needed. This can be configured as:</para>
150
151 <screen># User alias specification
152User_Alias ADMIN = YourLoginId
153
154# Allow people in group ADMIN to run all commands without a password
155ADMIN ALL = NOPASSWD: ALL</screen>
156
157 <para>For details, see <command>man sudoers</command>.</para>
158
159 <note>
160 <para>The <application>Sudo</application> developers highly recommend
161 using the <command>visudo</command> program to edit the
162 <filename>sudoers</filename> file. This will provide basic sanity
163 checking like syntax parsing and file permission to avoid some possible
164 mistakes that could lead to a vulnerable configuration.</para>
165 </note>
166
167 </sect3>
168
169 </sect2>
170
171 <sect2 role="content">
172 <title>Contents</title>
173
174 <segmentedlist>
175 <segtitle>Installed Programs</segtitle>
176 <segtitle>Installed Library</segtitle>
177 <segtitle>Installed Directories</segtitle>
178
179 <seglistitem>
180 <seg>sudo, sudoedit, and visudo</seg>
181 <seg>sudo_noexec.so</seg>
182 <seg>None</seg>
183 </seglistitem>
184 </segmentedlist>
185
186 <variablelist>
187 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
188 <?dbfo list-presentation="list"?>
189 <?dbhtml list-presentation="table"?>
190
191 <varlistentry id="sudo_prog">
192 <term><command>sudo</command></term>
193 <listitem>
194 <para>executes a command as another user as permitted by
195 the <filename>/etc/sudoers</filename> configuration file.
196 </para>
197 <indexterm zone="sudo sudo">
198 <primary sortas="b-sudo">sudo</primary>
199 </indexterm>
200 </listitem>
201 </varlistentry>
202
203 <varlistentry id="sudoedit">
204 <term><command>sudoedit</command></term>
205 <listitem>
206 <para>is a hard link to <command>sudo</command> that implies
207 the <option>-e</option> option to invoke an editor as another
208 user.</para>
209 <indexterm zone="sudo sudoedit">
210 <primary sortas="b-sudoedit">sudoedit</primary>
211 </indexterm>
212 </listitem>
213 </varlistentry>
214
215 <varlistentry id="visudo">
216 <term><command>visudo</command></term>
217 <listitem>
218 <para>allows for safer editing of the <filename>sudoers</filename>
219 file.</para>
220 <indexterm zone="sudo visudo">
221 <primary sortas="b-visudo">visudo</primary>
222 </indexterm>
223 </listitem>
224 </varlistentry>
225
226
227 <varlistentry id="sudo_noexec">
228 <term><filename class='libraryfile'>sudo_noexec.so</filename></term>
229 <listitem>
230 <para>enables support for the "noexec" functionality which prevents
231 a dynamically-linked program being run by sudo from executing
232 another program (think shell escapes).</para>
233 <indexterm zone="sudo sudo_noexec">
234 <primary sortas="c-sudo_noexec">sudo_noexec.so</primary>
235 </indexterm>
236 </listitem>
237 </varlistentry>
238
239 </variablelist>
240
241 </sect2>
242
243</sect1>
Note: See TracBrowser for help on using the repository browser.