]> granicus.if.org Git - sudo/log
sudo
16 years agoUnset AUTHSTATE after calling authenticate() as it may not be correct for
Todd C. Miller [Thu, 6 Nov 2008 00:08:24 +0000 (00:08 +0000)]
Unset AUTHSTATE after calling authenticate() as it may not be correct for
the user we are running the command as.

16 years agoAdd isblank() function for systems without it. Needed for POSIX
Todd C. Miller [Thu, 6 Nov 2008 00:05:24 +0000 (00:05 +0000)]
Add isblank() function for systems without it.  Needed for POSIX
character class matching in fnmatch.c and glob.c.

16 years agoexpound on sudo and cd
Todd C. Miller [Wed, 5 Nov 2008 16:02:44 +0000 (16:02 +0000)]
expound on sudo and cd

16 years agoregen
Todd C. Miller [Tue, 4 Nov 2008 20:52:50 +0000 (20:52 +0000)]
regen

16 years agoregen
Todd C. Miller [Tue, 4 Nov 2008 20:46:21 +0000 (20:46 +0000)]
regen

16 years agomention defauts parse order
Todd C. Miller [Tue, 4 Nov 2008 20:45:45 +0000 (20:45 +0000)]
mention defauts parse order

16 years agoAdd isblank() function for systems without it. Needed for POSIX
Todd C. Miller [Mon, 3 Nov 2008 18:19:14 +0000 (18:19 +0000)]
Add isblank() function for systems without it.  Needed for POSIX
character class matching in fnmatch.c and glob.c.

16 years agoadd emul/charclass.h to HDRS
Todd C. Miller [Mon, 3 Nov 2008 17:54:30 +0000 (17:54 +0000)]
add emul/charclass.h to HDRS

16 years agocheckpoint
Todd C. Miller [Sun, 2 Nov 2008 19:08:42 +0000 (19:08 +0000)]
checkpoint

16 years agoMove update_defaults into defaults.c and call it properly from
Todd C. Miller [Sun, 2 Nov 2008 19:06:37 +0000 (19:06 +0000)]
Move update_defaults into defaults.c and call it properly from
visudo and testsudoers.

16 years agouse zero_bytes() instead of memset() for consistency
Todd C. Miller [Sun, 2 Nov 2008 14:51:16 +0000 (14:51 +0000)]
use zero_bytes() instead of memset() for consistency

16 years agoZero out sigaction_t before use in case it has non-standard entries.
Todd C. Miller [Sun, 2 Nov 2008 14:45:31 +0000 (14:45 +0000)]
Zero out sigaction_t before use in case it has non-standard entries.

16 years agoquiet gcc
Todd C. Miller [Sun, 2 Nov 2008 14:35:37 +0000 (14:35 +0000)]
quiet gcc

16 years agoShort circuit glob() checks if basename(pattern) != basename(command).
Todd C. Miller [Sun, 2 Nov 2008 14:28:03 +0000 (14:28 +0000)]
Short circuit glob() checks if basename(pattern) != basename(command).
Refactor code that checks for a command in a directory and use it in the
glob case if the resolved pattern ends in a '/'.

16 years agoDefer setting runas defaults until after runaspw/gr is setup.
Todd C. Miller [Sat, 1 Nov 2008 13:20:01 +0000 (13:20 +0000)]
Defer setting runas defaults until after runaspw/gr is setup.

16 years agoUse MAXHOSTNAMELEN+1 when allocating host/domain name since some
Todd C. Miller [Wed, 29 Oct 2008 17:26:42 +0000 (17:26 +0000)]
Use MAXHOSTNAMELEN+1 when allocating host/domain name since some
systems do not include space for the NUL in the size.  Also manually
NUL-terminate buffer from gethostname() since POSIX is wishy-washy on this.

16 years agoWhen setting the umask, use the union of the user's umask and the
Todd C. Miller [Sun, 26 Oct 2008 21:13:03 +0000 (21:13 +0000)]
When setting the umask, use the union of the user's umask and the
default value set in sudoers so that we never lower the user's umask
when running a command.

16 years agoDon't try to read from a zero-length sudoers file. Remove the bogus
Todd C. Miller [Sun, 26 Oct 2008 20:43:59 +0000 (20:43 +0000)]
Don't try to read from a zero-length sudoers file.  Remove the bogus
Solaris work-around for EAGAIN.  Since we now use fgetc() it should
not be a problem.

16 years agoIn update_defaults() check the return value of user*_matches against
Todd C. Miller [Sat, 25 Oct 2008 13:22:41 +0000 (13:22 +0000)]
In update_defaults() check the return value of user*_matches against
ALLOW so we don't inadvertantly match on UNSPEC.

16 years agoregen man pages; no more hyphenation
Todd C. Miller [Fri, 24 Oct 2008 13:52:19 +0000 (13:52 +0000)]
regen man pages; no more hyphenation

16 years agoDon't error out on a zero-length sudoers file. With the advent of
Todd C. Miller [Fri, 24 Oct 2008 13:49:10 +0000 (13:49 +0000)]
Don't error out on a zero-length sudoers file.  With the advent of
#include the user could create a situation where sudo is unusable.

16 years agoNewer heimdal has 2-argument krb5_get_init_creds_opt_free() like MIT krb5.
Todd C. Miller [Thu, 23 Oct 2008 16:06:23 +0000 (16:06 +0000)]
Newer heimdal has 2-argument krb5_get_init_creds_opt_free() like MIT krb5.
Really old heimdal has no krb5_get_init_creds_opt_alloc() at all.  Add
configure tests to handle all the cases.

16 years agoresort ENVIRONMENT
Todd C. Miller [Wed, 8 Oct 2008 21:28:48 +0000 (21:28 +0000)]
resort ENVIRONMENT

16 years agodocument sudoers_locale
Todd C. Miller [Wed, 8 Oct 2008 21:09:07 +0000 (21:09 +0000)]
document sudoers_locale

16 years agoadd SUDO_EDITOR variable that sudoedit uses in preference to VISUAL or EDITOR
Todd C. Miller [Wed, 8 Oct 2008 20:56:17 +0000 (20:56 +0000)]
add SUDO_EDITOR variable that sudoedit uses in preference to VISUAL or EDITOR

16 years agoIn fill_cmnd(), collapse any escaped sudo-specific characters.
Todd C. Miller [Wed, 8 Oct 2008 18:27:35 +0000 (18:27 +0000)]
In fill_cmnd(), collapse any escaped sudo-specific characters.
Allows character classes to be used in pathnames.

16 years agofix typo in non-C89 function declaration
Todd C. Miller [Fri, 3 Oct 2008 20:02:00 +0000 (20:02 +0000)]
fix typo in non-C89 function declaration

16 years agoMention POSIX characters classes now that out fnmatch() and glob()
Todd C. Miller [Fri, 3 Oct 2008 19:56:40 +0000 (19:56 +0000)]
Mention POSIX characters classes now that out fnmatch() and glob()
support them.

16 years agoReplace [A-z] (which won't match in UTF8) with [A-Za-z] which is
Todd C. Miller [Fri, 3 Oct 2008 19:55:57 +0000 (19:55 +0000)]
Replace [A-z] (which won't match in UTF8) with [A-Za-z] which is
locale agnostic.

16 years agouse __signed char if we are going to assign a negative value since on Power, char...
Todd C. Miller [Fri, 3 Oct 2008 14:02:31 +0000 (14:02 +0000)]
use __signed char if we are going to assign a negative value since on Power, char is unsigned by default

16 years agoAdd tests for __signed char and signed char.
Todd C. Miller [Fri, 3 Oct 2008 13:59:39 +0000 (13:59 +0000)]
Add tests for __signed char and signed char.

16 years agoFix AIX limit setting. getuserattr() returns values in disk blocks rather
Todd C. Miller [Fri, 3 Oct 2008 13:19:31 +0000 (13:19 +0000)]
Fix AIX limit setting.  getuserattr() returns values in disk blocks rather
than bytes.  The default hard stack size in newer AIX is RLIM_SAVED_MAX.
From Dale King.

16 years agoAdd character class support to included glob(3) and fnmatch(3).
Todd C. Miller [Fri, 26 Sep 2008 21:13:29 +0000 (21:13 +0000)]
Add character class support to included glob(3) and fnmatch(3).

16 years agoRemove UCB advertising clause and some compatibility defines.
Todd C. Miller [Tue, 16 Sep 2008 12:28:35 +0000 (12:28 +0000)]
Remove UCB advertising clause and some compatibility defines.

16 years agoCheck EDITOR/VISUAL to make sure sudoedit is not re-invoking itself or sudo.
Todd C. Miller [Sun, 14 Sep 2008 20:07:49 +0000 (20:07 +0000)]
Check EDITOR/VISUAL to make sure sudoedit is not re-invoking itself or sudo.
This allows one to set EDITOR to sudoedit without getting into an infinite
loop of sudoedit running itself until the path gets too big.

16 years agoAdd sudoers_locale Defaults option to override the default sudoers
Todd C. Miller [Sun, 14 Sep 2008 00:45:24 +0000 (00:45 +0000)]
Add sudoers_locale Defaults option to override the default sudoers
locale of "C".

16 years agoSet locale to system default except for during sudoers parse.
Todd C. Miller [Sat, 13 Sep 2008 18:09:28 +0000 (18:09 +0000)]
Set locale to system default except for during sudoers parse.

16 years agoRedo change in 1.34 to use pointer arithmetic.
Todd C. Miller [Fri, 12 Sep 2008 13:34:27 +0000 (13:34 +0000)]
Redo change in 1.34 to use pointer arithmetic.

16 years agoFix a dereference (read) of a freed pointer. Reported by Patrick Williams.
Todd C. Miller [Thu, 11 Sep 2008 11:06:37 +0000 (11:06 +0000)]
Fix a dereference (read) of a freed pointer.  Reported by Patrick Williams.

16 years agoSet locale to "C" to avoid interpretation issues with character ranges
Todd C. Miller [Sat, 23 Aug 2008 23:09:13 +0000 (23:09 +0000)]
Set locale to "C" to avoid interpretation issues with character ranges
in sudoers.  May want to make the locale a sudoers option in the future.

16 years agowe no longer use setproctitle
Todd C. Miller [Wed, 20 Aug 2008 11:45:15 +0000 (11:45 +0000)]
we no longer use setproctitle

16 years agoremove #if 1
Todd C. Miller [Wed, 20 Aug 2008 11:41:22 +0000 (11:41 +0000)]
remove #if 1

16 years agoUse my replacement mkstemp() from the mktemp package.
Todd C. Miller [Wed, 20 Aug 2008 11:40:15 +0000 (11:40 +0000)]
Use my replacement mkstemp() from the mktemp package.

16 years agoregen with yacc skeleton bug fixed
Todd C. Miller [Sat, 12 Jul 2008 12:53:05 +0000 (12:53 +0000)]
regen with yacc skeleton bug fixed

16 years agoRemove duplicate "as root". From Martin Toft.
Todd C. Miller [Sat, 12 Jul 2008 12:48:21 +0000 (12:48 +0000)]
Remove duplicate "as root".  From Martin Toft.

16 years agoFlesh out the fake passwd entry used for running commands as a uid not
Todd C. Miller [Wed, 2 Jul 2008 10:27:57 +0000 (10:27 +0000)]
Flesh out the fake passwd entry used for running commands as a uid not
listed in the passwd database.  Fixes an issue with some PAM modules.

16 years agoError out in -i mode if the user has no shell. This can happen when
Todd C. Miller [Tue, 1 Jul 2008 11:57:55 +0000 (11:57 +0000)]
Error out in -i mode if the user has no shell.  This can happen when
running commands as a uid with no password entry.

16 years agoBetter fix for line continuation inside double quotes. Now accepts
Todd C. Miller [Thu, 26 Jun 2008 11:49:16 +0000 (11:49 +0000)]
Better fix for line continuation inside double quotes.  Now accepts
whitespace between the backslash and the newline like the main lexer.

16 years agoFix line continuation in strings. It was only being honored if preceded by
Todd C. Miller [Wed, 25 Jun 2008 18:31:19 +0000 (18:31 +0000)]
Fix line continuation in strings.  It was only being honored if preceded by
whitespace.

16 years agoReplace the double fork with a fork + daemonize.
Todd C. Miller [Sun, 22 Jun 2008 20:19:42 +0000 (20:19 +0000)]
Replace the double fork with a fork + daemonize.

16 years agoThe -i flag should imply env_reset. This got broken in sudo 1.6.9.
Todd C. Miller [Sat, 21 Jun 2008 18:59:36 +0000 (18:59 +0000)]
The -i flag should imply env_reset.  This got broken in sudo 1.6.9.

16 years agoChange how the mailer is waited for. Instead of having a SIGCHLD
Todd C. Miller [Sat, 21 Jun 2008 00:34:47 +0000 (00:34 +0000)]
Change how the mailer is waited for.  Instead of having a SIGCHLD
handler, use the double fork trick to orphan the child that opens
the pipe to sendmail.  Fixes a problem running su on some Linux distros.

16 years agoFix configure test for dirfd() on Linux where DIR is opaque.
Todd C. Miller [Fri, 20 Jun 2008 21:16:09 +0000 (21:16 +0000)]
Fix configure test for dirfd() on Linux where DIR is opaque.

16 years agoGet rid of the QNX TCSAFLUSH -> TCSADRAIN hack. If QNX still has this
Todd C. Miller [Tue, 17 Jun 2008 21:42:41 +0000 (21:42 +0000)]
Get rid of the QNX TCSAFLUSH -> TCSADRAIN hack.  If QNX still has this
problem we'll need to revisit this again.

16 years agoIgnore SIGPIPE instead of blocking it when piping to the mailer. If we
Todd C. Miller [Wed, 11 Jun 2008 01:13:39 +0000 (01:13 +0000)]
Ignore SIGPIPE instead of blocking it when piping to the mailer.  If we
only block the signal it may be delivered later when we unblock.
Also, there is no need to block SIGCHLD since we no longer do the
double fork.  The normal SIGCHLD handler is sufficient.

16 years agoAdd description for NO_PAM_SESSION, from a redhat patch.
Todd C. Miller [Sun, 8 Jun 2008 21:37:25 +0000 (21:37 +0000)]
Add description for NO_PAM_SESSION, from a redhat patch.

16 years agoFix typos in -i usage
Todd C. Miller [Fri, 6 Jun 2008 13:36:58 +0000 (13:36 +0000)]
Fix typos in -i usage

16 years agoRedo the test for dgettext() in a way that hopefully will work around
Todd C. Miller [Sun, 18 May 2008 17:54:48 +0000 (17:54 +0000)]
Redo the test for dgettext() in a way that hopefully will work around
the libintl_dgettext() undefined problem.

16 years agochange filename in comment
Todd C. Miller [Sun, 11 May 2008 13:21:09 +0000 (13:21 +0000)]
change filename in comment

16 years agoReference schema.ActiveDirectory
Todd C. Miller [Sat, 10 May 2008 13:18:47 +0000 (13:18 +0000)]
Reference schema.ActiveDirectory

16 years agoMark sudoRunAs as deprecated.
Todd C. Miller [Fri, 9 May 2008 18:49:25 +0000 (18:49 +0000)]
Mark sudoRunAs as deprecated.

16 years agoadd sudoRunAsUser and sudoRunAsGroup
Todd C. Miller [Fri, 9 May 2008 18:48:18 +0000 (18:48 +0000)]
add sudoRunAsUser and sudoRunAsGroup

16 years agoActive Directory schema by Chantal Paradis and Eric Paquet
Todd C. Miller [Fri, 9 May 2008 18:01:04 +0000 (18:01 +0000)]
Active Directory schema by Chantal Paradis and Eric Paquet

16 years agoremove an XXX that was fixed
Todd C. Miller [Thu, 8 May 2008 21:54:09 +0000 (21:54 +0000)]
remove an XXX that was fixed

16 years agosync
Todd C. Miller [Thu, 8 May 2008 16:53:09 +0000 (16:53 +0000)]
sync

16 years agoInitialize tags to UNSPEC instead of def_* in "sudo -l" mode.
Todd C. Miller [Thu, 8 May 2008 16:49:12 +0000 (16:49 +0000)]
Initialize tags to UNSPEC instead of def_* in "sudo -l" mode.
This fixes a problem where the tag value printed was influenced
by defaults set in the first pass through the parser.

16 years agoNo point in packaging the TODO file
Todd C. Miller [Sun, 4 May 2008 01:29:08 +0000 (01:29 +0000)]
No point in packaging the TODO file

16 years agosync
Todd C. Miller [Sun, 4 May 2008 01:24:30 +0000 (01:24 +0000)]
sync

16 years agoAdd env_file Defaults option that is similar to /etc/environment on some
Todd C. Miller [Sat, 3 May 2008 00:53:21 +0000 (00:53 +0000)]
Add env_file Defaults option that is similar to /etc/environment on some
systems.

16 years agochange version to 1.7.0
Todd C. Miller [Fri, 2 May 2008 20:38:08 +0000 (20:38 +0000)]
change version to 1.7.0

16 years agoinitial valgrind pass done
Todd C. Miller [Fri, 2 May 2008 20:37:43 +0000 (20:37 +0000)]
initial valgrind pass done

16 years agoFix typo/think in sudo_ldap_read_secret() when storing the secret.
Todd C. Miller [Wed, 23 Apr 2008 12:30:07 +0000 (12:30 +0000)]
Fix typo/think in sudo_ldap_read_secret() when storing the secret.

16 years agodefine LDAPS_PORT if the system headers do not
Todd C. Miller [Fri, 11 Apr 2008 14:03:30 +0000 (14:03 +0000)]
define LDAPS_PORT if the system headers do not

16 years agoFix another memory leak in init_parser().
Todd C. Miller [Thu, 10 Apr 2008 18:54:50 +0000 (18:54 +0000)]
Fix another memory leak in init_parser().

16 years agoThere was a missing space before the ldap libs in SUDO_LIBS for
Todd C. Miller [Thu, 10 Apr 2008 16:51:17 +0000 (16:51 +0000)]
There was a missing space before the ldap libs in SUDO_LIBS for
some configurations.

16 years agoClean up some memory leaks pointed out by valgrind.
Todd C. Miller [Thu, 10 Apr 2008 15:28:10 +0000 (15:28 +0000)]
Clean up some memory leaks pointed out by valgrind.

16 years agofix "sudo -s" broken by mode/flags breakout
Todd C. Miller [Mon, 7 Apr 2008 18:39:05 +0000 (18:39 +0000)]
fix "sudo -s" broken by mode/flags breakout

16 years agoremove duplicate check for dgettext
Todd C. Miller [Mon, 7 Apr 2008 18:26:13 +0000 (18:26 +0000)]
remove duplicate check for dgettext

16 years agoFall back to default stanza if no user-specific limit is found.
Todd C. Miller [Sat, 5 Apr 2008 19:54:11 +0000 (19:54 +0000)]
Fall back to default stanza if no user-specific limit is found.

16 years agoinclude stdint.h if present
Todd C. Miller [Wed, 2 Apr 2008 19:56:40 +0000 (19:56 +0000)]
include stdint.h if present

16 years agoUse LLONG_MAX, not the old QUAD_MAX
Todd C. Miller [Wed, 2 Apr 2008 19:28:27 +0000 (19:28 +0000)]
Use LLONG_MAX, not the old QUAD_MAX

16 years agofix cut and pasto
Todd C. Miller [Tue, 1 Apr 2008 23:18:21 +0000 (23:18 +0000)]
fix cut and pasto

16 years agoAdd #ifdef PURITY
Todd C. Miller [Mon, 31 Mar 2008 15:24:28 +0000 (15:24 +0000)]
Add #ifdef PURITY

16 years agoremove useless cast
Todd C. Miller [Sun, 30 Mar 2008 21:36:51 +0000 (21:36 +0000)]
remove useless cast

16 years agosync
Todd C. Miller [Thu, 27 Mar 2008 23:07:57 +0000 (23:07 +0000)]
sync

16 years agosync
Todd C. Miller [Thu, 27 Mar 2008 23:04:22 +0000 (23:04 +0000)]
sync

16 years agoSplit MODE_* defines into primary and flags.
Todd C. Miller [Thu, 27 Mar 2008 23:01:04 +0000 (23:01 +0000)]
Split MODE_* defines into primary and flags.

16 years agoIt turns out the logic for getting AIX limits is more convoluted
Todd C. Miller [Wed, 26 Mar 2008 17:11:53 +0000 (17:11 +0000)]
It turns out the logic for getting AIX limits is more convoluted
than I realized and differs depending on whether the soft and/or
hard limits are defined.

16 years agoBack out AIX-specific change to set the sudo_noexec path to the .a
Todd C. Miller [Sun, 23 Mar 2008 14:18:56 +0000 (14:18 +0000)]
Back out AIX-specific change to set the sudo_noexec path to the .a
file, we do really want to use the .so file.  Since libtool doesn't
do that correctly, just install the .so file ourselves in the Makefile.

16 years agoIf the file given to install is a path, only use the basename of the
Todd C. Miller [Sun, 23 Mar 2008 14:12:19 +0000 (14:12 +0000)]
If the file given to install is a path, only use the basename of the
file when building the destination path.

16 years agoparse_args() cleanup:
Todd C. Miller [Tue, 18 Mar 2008 20:08:46 +0000 (20:08 +0000)]
parse_args() cleanup:
Sort command line options in the getopt() switch
The -U option requires a parameter
Normalize a few ISSET calls
Split mode into mode and flags and retire the now-obsolete excl variable

16 years agoAdd -n (non-interactive) flag.
Todd C. Miller [Tue, 18 Mar 2008 20:04:41 +0000 (20:04 +0000)]
Add -n (non-interactive) flag.

16 years agoMove version printing, etc. into a separate function.
Todd C. Miller [Tue, 18 Mar 2008 19:59:37 +0000 (19:59 +0000)]
Move version printing, etc. into a separate function.

16 years agoDon't try to cleanup nsswitch if it has not been initialized.
Todd C. Miller [Tue, 18 Mar 2008 19:57:40 +0000 (19:57 +0000)]
Don't try to cleanup nsswitch if it has not been initialized.

16 years agoBlock SIGPIPE in send_mail() so sudo is not killed by a problem
Todd C. Miller [Mon, 17 Mar 2008 15:09:38 +0000 (15:09 +0000)]
Block SIGPIPE in send_mail() so sudo is not killed by a problem
executing the mailer.

16 years agoAIX shared libs end in .a, not .so.
Todd C. Miller [Fri, 14 Mar 2008 12:11:57 +0000 (12:11 +0000)]
AIX shared libs end in .a, not .so.

16 years agoPreserve HOME by default too. Matches documentation and previous behavior.
Todd C. Miller [Thu, 13 Mar 2008 11:34:31 +0000 (11:34 +0000)]
Preserve HOME by default too. Matches documentation and previous behavior.

16 years agoUse getopt() to parse the command line. We need to be able to
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.

16 years agosync
Todd C. Miller [Thu, 6 Mar 2008 19:46:10 +0000 (19:46 +0000)]
sync

16 years agoupdate to libtool-1.5.26
Todd C. Miller [Thu, 6 Mar 2008 19:43:25 +0000 (19:43 +0000)]
update to libtool-1.5.26