mirror of
https://github.com/sudo-project/sudo.git
synced 2025-08-22 01:49:11 +00:00
Move sample.* files to a sudo examples dir
This commit is contained in:
parent
6e8b84fda2
commit
b91a91d289
10
INSTALL
10
INSTALL
@ -55,11 +55,11 @@ For most systems and configurations it is possible simply to:
|
|||||||
install-doc, and install-sudoers make targets.
|
install-doc, and install-sudoers make targets.
|
||||||
|
|
||||||
6) Edit the sudoers file with `visudo' as necessary for your
|
6) Edit the sudoers file with `visudo' as necessary for your
|
||||||
site. You will probably want to refer the sample.sudoers
|
site. You will probably want to refer the example sudoers
|
||||||
file and sudoers man page included with the sudo package.
|
file and sudoers man page included with the sudo package.
|
||||||
|
|
||||||
7) If you want to use syslogd(8) to do the logging, you'll need
|
7) If you want to use syslogd(8) to do the logging, you'll need
|
||||||
to update your /etc/syslog.conf file. See the sample.syslog.conf
|
to update your /etc/syslog.conf file. See the example syslog.conf
|
||||||
file included in the distribution for an example.
|
file included in the distribution for an example.
|
||||||
|
|
||||||
Available configure options
|
Available configure options
|
||||||
@ -425,8 +425,8 @@ Authentication options:
|
|||||||
Linux, Solaris and HP-UX (version 11 and higher).
|
Linux, Solaris and HP-UX (version 11 and higher).
|
||||||
|
|
||||||
NOTE: on RedHat Linux and Fedora you *must* have an /etc/pam.d/sudo
|
NOTE: on RedHat Linux and Fedora you *must* have an /etc/pam.d/sudo
|
||||||
file install. You may either use the sample.pam file included with
|
file install. You may either use the example pam.conf file included
|
||||||
sudo or use /etc/pam.d/su as a reference. The sample.pam file
|
with sudo or use /etc/pam.d/su as a reference. The pam.conf file
|
||||||
included with sudo may or may not work with other Linux distributions.
|
included with sudo may or may not work with other Linux distributions.
|
||||||
On Solaris and HP-UX 11 systems you should check (and understand)
|
On Solaris and HP-UX 11 systems you should check (and understand)
|
||||||
the contents of /etc/pam.conf. Do a "man pam.conf" for more
|
the contents of /etc/pam.conf. Do a "man pam.conf" for more
|
||||||
@ -676,7 +676,7 @@ Options that set runtime-changeable default values:
|
|||||||
How you want to do your logging. You may choose "syslog",
|
How you want to do your logging. You may choose "syslog",
|
||||||
"file", or "both". Setting this to "syslog" is nice because
|
"file", or "both". Setting this to "syslog" is nice because
|
||||||
you can keep all of your sudo logs in one place (see the
|
you can keep all of your sudo logs in one place (see the
|
||||||
sample.syslog.conf file). The default is "syslog".
|
example syslog.conf file). The default is "syslog".
|
||||||
Sudoers options: syslog and logfile
|
Sudoers options: syslog and logfile
|
||||||
|
|
||||||
--with-loglen=NUMBER
|
--with-loglen=NUMBER
|
||||||
|
9
MANIFEST
9
MANIFEST
@ -21,10 +21,6 @@ doc/TROUBLESHOOTING
|
|||||||
doc/UPGRADE
|
doc/UPGRADE
|
||||||
doc/fixman.sh
|
doc/fixman.sh
|
||||||
doc/fixmdoc.sh
|
doc/fixmdoc.sh
|
||||||
doc/sample.pam
|
|
||||||
doc/sample.sudo.conf
|
|
||||||
doc/sample.sudoers
|
|
||||||
doc/sample.syslog.conf
|
|
||||||
doc/schema.ActiveDirectory
|
doc/schema.ActiveDirectory
|
||||||
doc/schema.OpenLDAP
|
doc/schema.OpenLDAP
|
||||||
doc/schema.iPlanet
|
doc/schema.iPlanet
|
||||||
@ -49,6 +45,11 @@ doc/sudoreplay.mdoc.in
|
|||||||
doc/visudo.cat
|
doc/visudo.cat
|
||||||
doc/visudo.man.in
|
doc/visudo.man.in
|
||||||
doc/visudo.mdoc.in
|
doc/visudo.mdoc.in
|
||||||
|
examples/Makefile.in
|
||||||
|
examples/pam.conf
|
||||||
|
examples/sudo.conf
|
||||||
|
examples/sudoers
|
||||||
|
examples/syslog.conf
|
||||||
include/Makefile.in
|
include/Makefile.in
|
||||||
include/compat/charclass.h
|
include/compat/charclass.h
|
||||||
include/compat/endian.h
|
include/compat/endian.h
|
||||||
|
@ -32,6 +32,7 @@ datarootdir = @datarootdir@
|
|||||||
localedir = @localedir@
|
localedir = @localedir@
|
||||||
localstatedir = @localstatedir@
|
localstatedir = @localstatedir@
|
||||||
docdir = @docdir@
|
docdir = @docdir@
|
||||||
|
exampledir = $(datarootdir)/examples/$(PACKAGE_TARNAME)
|
||||||
mandir = @mandir@
|
mandir = @mandir@
|
||||||
rundir = @rundir@
|
rundir = @rundir@
|
||||||
vardir = @vardir@
|
vardir = @vardir@
|
||||||
@ -48,7 +49,7 @@ sudoers_mode = @SUDOERS_MODE@
|
|||||||
shlib_mode = @SHLIB_MODE@
|
shlib_mode = @SHLIB_MODE@
|
||||||
|
|
||||||
SUBDIRS = lib/util @ZLIB_SRC@ plugins/group_file plugins/sudoers \
|
SUBDIRS = lib/util @ZLIB_SRC@ plugins/group_file plugins/sudoers \
|
||||||
plugins/system_group src include doc
|
plugins/system_group src include doc examples
|
||||||
|
|
||||||
SAMPLES = plugins/sample
|
SAMPLES = plugins/sample
|
||||||
|
|
||||||
@ -306,6 +307,7 @@ package: sudo.pp
|
|||||||
mandir=$(mandir) \
|
mandir=$(mandir) \
|
||||||
localedir=$(localedir) \
|
localedir=$(localedir) \
|
||||||
docdir=$(docdir) \
|
docdir=$(docdir) \
|
||||||
|
exampledir=$(exampledir) \
|
||||||
sysconfdir=$(sysconfdir) \
|
sysconfdir=$(sysconfdir) \
|
||||||
sudoersdir=$(sudoersdir) \
|
sudoersdir=$(sudoersdir) \
|
||||||
sudoers_uid=$(sudoers_uid) \
|
sudoers_uid=$(sudoers_uid) \
|
||||||
|
7
configure
vendored
7
configure
vendored
@ -23204,7 +23204,7 @@ test "$localedir" = '${datarootdir}/locale' && localedir='$(datarootdir)/locale'
|
|||||||
test "$localstatedir" = '${prefix}/var' && localstatedir='$(prefix)/var'
|
test "$localstatedir" = '${prefix}/var' && localstatedir='$(prefix)/var'
|
||||||
test "$sysconfdir" = '${prefix}/etc' -a X"$with_stow" != X"yes" && sysconfdir='/etc'
|
test "$sysconfdir" = '${prefix}/etc' -a X"$with_stow" != X"yes" && sysconfdir='/etc'
|
||||||
|
|
||||||
ac_config_files="$ac_config_files Makefile doc/Makefile include/Makefile init.d/aix.sh init.d/hpux.sh lib/util/Makefile lib/util/util.exp src/sudo_usage.h src/Makefile plugins/sample/Makefile plugins/group_file/Makefile plugins/system_group/Makefile plugins/sudoers/Makefile plugins/sudoers/sudoers"
|
ac_config_files="$ac_config_files Makefile doc/Makefile examples/Makefile include/Makefile init.d/aix.sh init.d/hpux.sh lib/util/Makefile lib/util/util.exp src/sudo_usage.h src/Makefile plugins/sample/Makefile plugins/group_file/Makefile plugins/system_group/Makefile plugins/sudoers/Makefile plugins/sudoers/sudoers"
|
||||||
|
|
||||||
cat >confcache <<\_ACEOF
|
cat >confcache <<\_ACEOF
|
||||||
# This file is a shell script that caches the results of configure
|
# This file is a shell script that caches the results of configure
|
||||||
@ -24193,6 +24193,7 @@ do
|
|||||||
"lib/zlib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/zlib/Makefile" ;;
|
"lib/zlib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/zlib/Makefile" ;;
|
||||||
"Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
|
"Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
|
||||||
"doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
|
"doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
|
||||||
|
"examples/Makefile") CONFIG_FILES="$CONFIG_FILES examples/Makefile" ;;
|
||||||
"include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;;
|
"include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;;
|
||||||
"init.d/aix.sh") CONFIG_FILES="$CONFIG_FILES init.d/aix.sh" ;;
|
"init.d/aix.sh") CONFIG_FILES="$CONFIG_FILES init.d/aix.sh" ;;
|
||||||
"init.d/hpux.sh") CONFIG_FILES="$CONFIG_FILES init.d/hpux.sh" ;;
|
"init.d/hpux.sh") CONFIG_FILES="$CONFIG_FILES init.d/hpux.sh" ;;
|
||||||
@ -25288,8 +25289,8 @@ $as_echo "$as_me: sudo session required libpam_hpsec.so.1 bypass_umask bypass_la
|
|||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
linux*)
|
linux*)
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: You will need to customize sample.pam and install it as /etc/pam.d/sudo" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: You will need to customize examples/pam.conf and install it as /etc/pam.d/sudo" >&5
|
||||||
$as_echo "$as_me: You will need to customize sample.pam and install it as /etc/pam.d/sudo" >&6;}
|
$as_echo "$as_me: You will need to customize examples/pam.conf and install it as /etc/pam.d/sudo" >&6;}
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
@ -4020,7 +4020,7 @@ test "$sysconfdir" = '${prefix}/etc' -a X"$with_stow" != X"yes" && sysconfdir='/
|
|||||||
dnl
|
dnl
|
||||||
dnl Substitute into the Makefile and man pages
|
dnl Substitute into the Makefile and man pages
|
||||||
dnl
|
dnl
|
||||||
AC_CONFIG_FILES([Makefile doc/Makefile include/Makefile init.d/aix.sh init.d/hpux.sh lib/util/Makefile lib/util/util.exp src/sudo_usage.h src/Makefile plugins/sample/Makefile plugins/group_file/Makefile plugins/system_group/Makefile plugins/sudoers/Makefile plugins/sudoers/sudoers])
|
AC_CONFIG_FILES([Makefile doc/Makefile examples/Makefile include/Makefile init.d/aix.sh init.d/hpux.sh lib/util/Makefile lib/util/util.exp src/sudo_usage.h src/Makefile plugins/sample/Makefile plugins/group_file/Makefile plugins/system_group/Makefile plugins/sudoers/Makefile plugins/sudoers/sudoers])
|
||||||
AC_OUTPUT
|
AC_OUTPUT
|
||||||
|
|
||||||
dnl
|
dnl
|
||||||
@ -4035,7 +4035,7 @@ if test "$with_pam" = "yes"; then
|
|||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
linux*)
|
linux*)
|
||||||
AC_MSG_NOTICE([You will need to customize sample.pam and install it as /etc/pam.d/sudo])
|
AC_MSG_NOTICE([You will need to customize examples/pam.conf and install it as /etc/pam.d/sudo])
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
@ -23,7 +23,6 @@ srcdir = @srcdir@
|
|||||||
docdir = @docdir@
|
docdir = @docdir@
|
||||||
top_builddir = @top_builddir@
|
top_builddir = @top_builddir@
|
||||||
top_srcdir = @top_srcdir@
|
top_srcdir = @top_srcdir@
|
||||||
cross_compiling = @CROSS_COMPILING@
|
|
||||||
|
|
||||||
# Tools to use
|
# Tools to use
|
||||||
SED = @SED@
|
SED = @SED@
|
||||||
@ -84,9 +83,8 @@ DEVDOCS = $(srcdir)/sudo.man.in $(srcdir)/sudo.cat \
|
|||||||
|
|
||||||
OTHER_DOCS = $(top_srcdir)/ChangeLog $(top_srcdir)/README \
|
OTHER_DOCS = $(top_srcdir)/ChangeLog $(top_srcdir)/README \
|
||||||
$(top_srcdir)/NEWS $(srcdir)/HISTORY $(srcdir)/CONTRIBUTORS \
|
$(top_srcdir)/NEWS $(srcdir)/HISTORY $(srcdir)/CONTRIBUTORS \
|
||||||
$(srcdir)/LICENSE $(srcdir)/TROUBLESHOOTING $(srcdir)/UPGRADE \
|
$(srcdir)/LICENSE $(srcdir)/TROUBLESHOOTING $(srcdir)/UPGRADE
|
||||||
$(srcdir)/sample.*
|
|
||||||
|
|
||||||
OTHER_DOCS_LDAP = $(top_srcdir)/README.LDAP $(srcdir)/schema.*
|
OTHER_DOCS_LDAP = $(top_srcdir)/README.LDAP $(srcdir)/schema.*
|
||||||
|
|
||||||
VERSION = @PACKAGE_VERSION@
|
VERSION = @PACKAGE_VERSION@
|
||||||
|
@ -42,9 +42,9 @@ A) The owner and permissions on the sudo binary appear to be OK but when
|
|||||||
Q) Sudo never gives me a chance to enter a password using PAM, it just
|
Q) Sudo never gives me a chance to enter a password using PAM, it just
|
||||||
says 'Sorry, try again.' three times and exits.
|
says 'Sorry, try again.' three times and exits.
|
||||||
A) You didn't setup PAM to work with sudo. On RedHat Linux or Fedora
|
A) You didn't setup PAM to work with sudo. On RedHat Linux or Fedora
|
||||||
Core this generally means installing sample.pam as /etc/pam.d/sudo.
|
Core this generally means installing the sample pam.conf file as
|
||||||
See the sample.pam file for hints on what to use for other Linux
|
/etc/pam.d/sudo. See the example pam.conf file for hints on what
|
||||||
systems.
|
to use for other Linux systems.
|
||||||
|
|
||||||
Q) Sudo says 'Account expired or PAM config lacks an "account"
|
Q) Sudo says 'Account expired or PAM config lacks an "account"
|
||||||
section for sudo, contact your system administrator' and exits
|
section for sudo, contact your system administrator' and exits
|
||||||
@ -57,7 +57,7 @@ A) Your PAM config lacks an "account" specification. On Linux this
|
|||||||
Q) Sudo is setup to log via syslog(3) but I'm not getting any log
|
Q) Sudo is setup to log via syslog(3) but I'm not getting any log
|
||||||
messages.
|
messages.
|
||||||
A) Make sure you have an entry in your syslog.conf file to save
|
A) Make sure you have an entry in your syslog.conf file to save
|
||||||
the sudo messages (see the sample.syslog.conf file). The default
|
the sudo messages (see the example syslog.conf file). The default
|
||||||
log facility is authpriv (changeable via configure or in sudoers).
|
log facility is authpriv (changeable via configure or in sudoers).
|
||||||
Don't forget to send a SIGHUP to your syslogd so that it re-reads
|
Don't forget to send a SIGHUP to your syslogd so that it re-reads
|
||||||
its conf file. Also, remember that syslogd does *not* create
|
its conf file. Also, remember that syslogd does *not* create
|
||||||
@ -143,7 +143,7 @@ A) Sudo removes the following "dangerous" environment variables
|
|||||||
Q) How can I keep sudo from asking for a password?
|
Q) How can I keep sudo from asking for a password?
|
||||||
A) To specify this on a per-user (and per-command) basis, use the
|
A) To specify this on a per-user (and per-command) basis, use the
|
||||||
'NOPASSWD' tag right before the command list in sudoers. See
|
'NOPASSWD' tag right before the command list in sudoers. See
|
||||||
the sudoers man page and sample.sudoers for details. To disable
|
the sudoers man page and examples/sudoers for details. To disable
|
||||||
passwords completely, add !authenticate" to the Defaults line
|
passwords completely, add !authenticate" to the Defaults line
|
||||||
in /etc/sudoers. You can also turn off authentication on a
|
in /etc/sudoers. You can also turn off authentication on a
|
||||||
per-user or per-host basis using a user or host-specific Defaults
|
per-user or per-host basis using a user or host-specific Defaults
|
||||||
|
@ -128,9 +128,9 @@ o Upgrading from a version prior to 1.8.0:
|
|||||||
|
|
||||||
The sudo.conf file, usually stored in /etc, is used to configure
|
The sudo.conf file, usually stored in /etc, is used to configure
|
||||||
plugins. This file is optional--if no plugins are specified
|
plugins. This file is optional--if no plugins are specified
|
||||||
in sudo.conf, the "sudoers" plugin is used. See the sample.sudo.conf
|
in sudo.conf, the "sudoers" plugin is used. See the example
|
||||||
file in the doc directory or refer to the updated sudo manual
|
sudo.conf file in the doc directory or refer to the updated
|
||||||
to see how to configure sudo.conf.
|
sudo manual to see how to configure sudo.conf.
|
||||||
|
|
||||||
The "askpass" setting has moved from the sudoers file to the
|
The "askpass" setting has moved from the sudoers file to the
|
||||||
sudo.conf file. If you have a sudoers file that uses the
|
sudo.conf file. If you have a sudoers file that uses the
|
||||||
|
94
examples/Makefile.in
Normal file
94
examples/Makefile.in
Normal file
@ -0,0 +1,94 @@
|
|||||||
|
#
|
||||||
|
# Copyright (c) 2014 Todd C. Miller <Todd.Miller@courtesan.com>
|
||||||
|
#
|
||||||
|
# Permission to use, copy, modify, and distribute this software for any
|
||||||
|
# purpose with or without fee is hereby granted, provided that the above
|
||||||
|
# copyright notice and this permission notice appear in all copies.
|
||||||
|
#
|
||||||
|
# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
|
#
|
||||||
|
# @configure_input@
|
||||||
|
#
|
||||||
|
|
||||||
|
#### Start of system configuration section. ####
|
||||||
|
|
||||||
|
srcdir = @srcdir@
|
||||||
|
exampledir = $(datarootdir)/examples/$(PACKAGE_TARNAME)
|
||||||
|
top_builddir = @top_builddir@
|
||||||
|
top_srcdir = @top_srcdir@
|
||||||
|
|
||||||
|
# Our install program supports extra flags...
|
||||||
|
INSTALL = $(SHELL) $(top_srcdir)/install-sh -c
|
||||||
|
INSTALL_OWNER = -o $(install_uid) -g $(install_gid)
|
||||||
|
|
||||||
|
# Where to install things...
|
||||||
|
prefix = @prefix@
|
||||||
|
exec_prefix = @exec_prefix@
|
||||||
|
bindir = @bindir@
|
||||||
|
sbindir = @sbindir@
|
||||||
|
sysconfdir = @sysconfdir@
|
||||||
|
libexecdir = @libexecdir@
|
||||||
|
datarootdir = @datarootdir@
|
||||||
|
localstatedir = @localstatedir@
|
||||||
|
|
||||||
|
# User and group ids the installed files should be "owned" by
|
||||||
|
install_uid = 0
|
||||||
|
install_gid = 0
|
||||||
|
|
||||||
|
#### End of system configuration section. ####
|
||||||
|
|
||||||
|
SHELL = @SHELL@
|
||||||
|
|
||||||
|
EXAMPLES = $(srcdir)/pam.conf $(srcdir)/sudo.conf $(srcdir)/sudoers \
|
||||||
|
$(srcdir)/syslog.conf
|
||||||
|
|
||||||
|
VERSION = @PACKAGE_VERSION@
|
||||||
|
PACKAGE_TARNAME = @PACKAGE_TARNAME@
|
||||||
|
|
||||||
|
all: $(EXAMPLES)
|
||||||
|
|
||||||
|
Makefile: $(srcdir)/Makefile.in
|
||||||
|
(cd $(top_builddir) && ./config.status --file examples/Makefile)
|
||||||
|
|
||||||
|
pre-install:
|
||||||
|
|
||||||
|
install: install-doc
|
||||||
|
|
||||||
|
install-dirs:
|
||||||
|
$(SHELL) $(top_srcdir)/mkinstalldirs $(DESTDIR)$(exampledir)
|
||||||
|
|
||||||
|
install-binaries:
|
||||||
|
|
||||||
|
install-includes:
|
||||||
|
|
||||||
|
install-doc: install-dirs
|
||||||
|
for f in $(EXAMPLES); do $(INSTALL) $(INSTALL_OWNER) -m 0644 $$f $(DESTDIR)$(exampledir); done
|
||||||
|
|
||||||
|
install-plugin:
|
||||||
|
|
||||||
|
uninstall:
|
||||||
|
-rm -rf $(DESTDIR)$(exampledir)
|
||||||
|
|
||||||
|
cppcheck:
|
||||||
|
|
||||||
|
check:
|
||||||
|
|
||||||
|
clean:
|
||||||
|
|
||||||
|
mostlyclean: clean
|
||||||
|
|
||||||
|
distclean: clean
|
||||||
|
-rm -rf Makefile
|
||||||
|
|
||||||
|
clobber: distclean
|
||||||
|
|
||||||
|
realclean: distclean
|
||||||
|
|
||||||
|
cleandir: distclean
|
2
sudo.pp
2
sudo.pp
@ -279,6 +279,8 @@ still allow people to get their work done."
|
|||||||
$docdir/ChangeLog ignore,ignore-others
|
$docdir/ChangeLog ignore,ignore-others
|
||||||
%endif
|
%endif
|
||||||
$docdir/* 0644
|
$docdir/* 0644
|
||||||
|
$exampledir/ 0755
|
||||||
|
$exampledir/* 0644
|
||||||
$localedir/*/ - optional
|
$localedir/*/ - optional
|
||||||
$localedir/*/LC_MESSAGES/ - optional
|
$localedir/*/LC_MESSAGES/ - optional
|
||||||
$localedir/*/LC_MESSAGES/* 0644 optional
|
$localedir/*/LC_MESSAGES/* 0644 optional
|
||||||
|
Loading…
x
Reference in New Issue
Block a user