Todd C. Miller [Wed, 12 Mar 2008 23:42:32 +0000 (23:42 +0000)]
Use getopt() to parse the command line. We need to be able to
intersperse env variables and options yet still honor "--""
which complicates things slightly.
Todd C. Miller [Wed, 5 Mar 2008 20:19:50 +0000 (20:19 +0000)]
When adding a default, only call list2tq() once to do the list to
tq conversion. It is not legal to call list2tq multiple times on
the same list since list2tq consumes and modifies the list argument.
Todd C. Miller [Wed, 27 Feb 2008 14:26:28 +0000 (14:26 +0000)]
Disable use of gss_krb5_ccache_name() by default and add
--enable-gss-krb5-ccache-name configure option to enable it. It
seems that gss_krb5_ccache_name() doesn't work properly with some
combinations of Heimdal and OpenLDAP.
Todd C. Miller [Fri, 22 Feb 2008 20:19:34 +0000 (20:19 +0000)]
Only set std_prompt for the PAM_PROMPT_* cases. The conversation function
may be called for non-password reading purposes so we must be careful
not to use def_prompt in cases where it may not be set.
Todd C. Miller [Mon, 18 Feb 2008 15:42:43 +0000 (15:42 +0000)]
Remove the =cut on the first line (above the copyright notice) to quiet
pod2man. Also remove the hackery in the FILES section and just deal
with the fact that there will a newline between each pathname.
Todd C. Miller [Wed, 13 Feb 2008 12:28:37 +0000 (12:28 +0000)]
Remove dependence on VALIDATE_NOT_OK in logging functions.
Split log_auth() into log_allowed() and log_denial()
Replace mail_auth() with should_mail() and a call to send_mail()
Todd C. Miller [Sat, 9 Feb 2008 14:30:07 +0000 (14:30 +0000)]
Add support for SELinux RBAC. Sudoers entries may specify a role and type.
There are also role and type defaults that may be used. To make sure a
transition occurs, when using RBAC commands are executed via the new sesh
binary. Based on initial changes from Dan Walsh.
Todd C. Miller [Sat, 9 Feb 2008 14:30:06 +0000 (14:30 +0000)]
Add support for SELinux RBAC. Sudoers entries may specify a role and type.
There are also role and type defaults that may be used. To make sure a
transition occurs, when using RBAC commands are executed via the new sesh
binary. Based on initial changes from Dan Walsh.
Todd C. Miller [Sat, 9 Feb 2008 14:30:06 +0000 (14:30 +0000)]
Add support for SELinux RBAC. Sudoers entries may specify a role and type.
There are also role and type defaults that may be used. To make sure a
transition occurs, when using RBAC commands are executed via the new sesh
binary. Based on initial changes from Dan Walsh.
Todd C. Miller [Sun, 3 Feb 2008 15:43:38 +0000 (15:43 +0000)]
Unify the -l output for file and ldap based sudoers and use lbufs for both.
The ldap output does not currently include options that cannot be represented
as tags. This will be remedied in a long list output mode to come.
Todd C. Miller [Sun, 27 Jan 2008 21:37:54 +0000 (21:37 +0000)]
Use a specific error message for errno == EAGAIN when setuid() et al fails.
On Linux systems setuid() will fail with errno set to EAGAIN if changing
to the new uid would result in a resource limit violation.
Todd C. Miller [Sun, 27 Jan 2008 21:34:41 +0000 (21:34 +0000)]
Unlimit nproc on Linux systems where calling the setuid() family
of syscalls causes the nroc resource limit to be checked. The
limits will be reset by pam_limits.so when PAM is used. In the
non-PAM case the nproc limit will remain unlimited but there doesn't
seem to be a way around that other than having sudo parse
/etc/security/limits.conf directly.
Todd C. Miller [Wed, 23 Jan 2008 11:33:27 +0000 (11:33 +0000)]
Use SUDO_DEFINE_UNQUOTED instead of AC_DEFINE_UNQUOTED to prevent
ldap.conf and ldap.secret paths from going into config.h.
Avoid single quotes in variable expansion when using SUDO_DEFINE_UNQUOTED
since in some versions of bash they will end up literally in the resulting
define.
Todd C. Miller [Fri, 18 Jan 2008 22:32:52 +0000 (22:32 +0000)]
When copying gr_mem we must guarantee that the storage space for
gr_mem is properly aligned. The simplest way to do this is to
simply store gr_mem directly after struct group. This is not a
problem for gr_passwd or gr_name as they are simple strings.