Commit Graph

2169 Commits

Author SHA1 Message Date
Todd C. Miller
0acdc98f1d reference samples.sylog.conf 1999-08-17 09:32:43 +00:00
Todd C. Miller
1451404baf Sample entries for syslog.conf 1999-08-14 15:50:49 +00:00
Todd C. Miller
2e8eaae774 recent changes 1999-08-14 15:40:58 +00:00
Todd C. Miller
d40947c0b0 In struct sudo_auth, turn need_root and configured into flags and
add a flag to specify an auth method is running alone (the only
one).  Pass auth methods their sudo_auth pointer, not the data
pointer.  This allows us to get at the flags and tell if we are the
only auth method.  That, in turn, allows the method to be able to
decide what should/should not be a fatal error.  Currently only
rfc1938 uses it this way, which allows us to kill the OTP_ONLY
define and te hackery that went with it.  With access to the
sudo_auth struct, methods can also get at a string holding their
cannonical name (useful in error messages).
1999-08-14 15:36:47 +00:00
Todd C. Miller
3a8b0be635 o --with-otp deprecated, use --without-passwd instead
o real dependencies in the Makefile
o --with-devel option to enable yacc, lex, and -Wall
o style -- "foo -> bar" becomes "foo->bar"
o ALL goes back to being a token, not a string but don't leak memory
o rename hsotspec -> host in parse.yacc
1999-08-14 15:34:55 +00:00
Todd C. Miller
c2d088ebe1 recent changes 1999-08-12 16:26:25 +00:00
Todd C. Miller
d7ebfe06d1 o Digital UNIX needs to check for *snprintf() before -ldb is added to LIBS
since -ldb includes a bogus snprintf().
o Add forward refs for struct mbuf and struct rtentry for Digital UNIX.
o Reorder some functions in snprintf.c to fix -Wall
o Add missing includes to fix more -Wall
1999-08-12 16:24:10 +00:00
Todd C. Miller
2386dc1b45 o Add a "pedentic" flag to the parser. This makes sudo warn in cases
where an alias may be used before it is defined.  Only turned on for visudo
and testsudoers.
o Add --disable-authentication option that makes sudo not require
authentication by default.  The PASSWD tag can be used to require
authentication for an entry.  We no longer overload --without-passwd.
1999-08-12 14:37:27 +00:00
Todd C. Miller
f14dd25b01 Break 'WORD' regexp def into HOSTNAME and USERNAME. These days a
username can contain just about anything so be very permissive.
Also drop the unused \. punctuation.
1999-08-12 14:29:12 +00:00
Todd C. Miller
2ce523cd1f o add a 'val' element to aliasinfo struct and move -> parse.h
o find_alias() now returns an aliasinfo * instead of boolean
o add_alias() now takes a value parameter to store in the aliasinfo.val
o The cmnd, hostspec, runasuser, and user rules now return:
1) positive match
0) negative match (due to '!')
-1) no match
This means setting $$ explicitly in all cases, which I should have done in
the first place.  It also means that we always store a value that is != -1
and when we see a '!' we can set *_matches to !rv if rv != -1.
The upshot of all of this is that '!' now works the way it should in
lists and some of the rules are more uniform and sensible.
1999-08-09 22:25:17 +00:00
Todd C. Miller
518eec0abb add parse.h dependency 1999-08-09 22:17:27 +00:00
Todd C. Miller
b18495e627 kill unused *_matched macros 1999-08-09 22:17:05 +00:00
Todd C. Miller
76c801a685 Allow a list of users as the first thing in a user spec, not just a
single entry.  This makes things more uniform, though it does allow
you to write user specs that are hard to read.
1999-08-09 14:35:53 +00:00
Todd C. Miller
b4a7c5507a parse.yacc 1999-08-09 14:34:23 +00:00
Todd C. Miller
d2dcea30cb regen 1999-08-09 14:08:19 +00:00
Todd C. Miller
7bb2d52e95 fix check for crypt() in libufc 1999-08-09 14:08:03 +00:00
Todd C. Miller
609851d851 sudo-users list now exists 1999-08-07 18:03:19 +00:00
Todd C. Miller
be4e87f666 Update to reality. 1999-08-07 11:46:39 +00:00
Todd C. Miller
76148d5316 o Move lock_file() and touch() into fileops.c so visudo can use them
o Visudo now locks the sudoers temp file instead of bailing when
the temp file already exists.  This fixes the problem of stale
temp files but it does *require* that you not try to put the
temp file in a world-writable directory.  This shoud not be
an issue as the temp file should live in the same dir as sudoers.
o Visudo now only installs the temp file as sudoers if it changed.
1999-08-07 09:59:43 +00:00
Todd C. Miller
68a2b16781 add fcntl locking 1999-08-06 13:49:26 +00:00
Todd C. Miller
925f4eabc2 Lock the log file. 1999-08-06 13:33:03 +00:00
Todd C. Miller
145992dce2 o /etc/stmp -> /etc/sudoers.tmp since solaris uses stmp as shadow temp file
o _PATH_SUDO_SUDOERS -> _PATH_SUDOERS and _PATH_SUDO_STMP -> _PATH_SUDOERS_TMP
1999-08-06 09:37:03 +00:00
Todd C. Miller
7c53b74961 o Kill *_MESSAGE and replace with NO_LECTURE
o Add more things to root sudo -V config reporting
1999-08-05 21:38:19 +00:00
Todd C. Miller
61dc1ddf61 aix_auth.o not authenticate.o 1999-08-05 14:56:07 +00:00
Todd C. Miller
ae96a4f1ad Add --with-goodpri and --with-badpri configure options to specify the
syslog priority to use.
1999-08-05 14:48:35 +00:00
Todd C. Miller
d47ddf6a9d Add --with-goodpri and --with-badpri configure options to specify the
syslog priority to use.
1999-08-05 14:30:57 +00:00
Todd C. Miller
fdb5da47ae kill crufty AIX stuff 1999-08-05 14:25:35 +00:00
Todd C. Miller
93c2367743 Sigh, some versions of make (like Solaris's) don't deal with $< like
I would expect.  Both GNU and BSD makes get this right but...
So, we just expand $< inline at the cost of some ugliness.
1999-08-05 10:55:14 +00:00
Todd C. Miller
fd16d8e77f If the invoking user is root, sudo will now print configure info in
-V mode.  Currently just prints logging info, to be expanded later.
1999-08-05 10:52:33 +00:00
Todd C. Miller
27d6f353e2 o new defines for syslog facility and priority
o use new print_version() functino for -V mode
1999-08-05 10:51:02 +00:00
Todd C. Miller
9283524123 Don't need version.c 1999-08-05 10:49:24 +00:00
Todd C. Miller
e966a6b3e0 Add check for syslog facilities and priorities tables in syslog.h 1999-08-05 10:21:28 +00:00
Todd C. Miller
a7acfdb683 o authenticate -> aix_auth
o add version.c
1999-08-05 09:23:39 +00:00
Todd C. Miller
5e72465522 Missed a prompt -> user_prompt conversion 1999-08-05 09:21:38 +00:00
Todd C. Miller
4aa1fb7fea sudo should lock its logfile 1999-08-04 17:32:24 +00:00
Todd C. Miller
16ab377018 o Add '!' correctly when expanding Aliases.
o Add shortcut macros for append() to make things more readable.
o The separator in append() is now a string instead of a char.
o In append(), only prepend the separator if the last char is not a '!'.
  This is a hack but it greatly simplifies '!' handling.
o In -l mode, Runas lists and NOPASSWD/PASSWD tags are now inherited
  across entries in a list (matches current behavior).
o Fix formatting in -l mode such that items in a list are separated by
  a space.  Greatlt improves readability.
o Space for name field in struct aliasinfo is now allocated dyanically
  instead of using a (big) buffer.
o In add_alias(), only search the list once (lsearch instead of lfind + lsearch)
1999-08-04 17:28:47 +00:00
Todd C. Miller
0d5a675f5b regen 1999-08-04 15:31:47 +00:00
Todd C. Miller
1a4ebcf2f5 Solais pam doesn't require anye xtra setup 1999-08-04 14:54:34 +00:00
Todd C. Miller
716e0b5433 o Simpler '!' support now that the lexer deals with multiple !'s for us.
o In the case of opFOO, have FOO give a boolean return value and set
  foo_matches in opFOO, not FOO.
o Treat 'ALL' as a string since it gets fill()'d in parse.lex--fixes a
  small memory leak.  In the long run it may be better to just fix parse.lex
  and make ALL back into a token.  However, having it be a string is useful
  since it can be easily passed back to the parent rule if we so desire.
1999-08-04 09:35:56 +00:00
Todd C. Miller
d1a6fa810e o Remove some unnecessary backslashes
o collapse multiple !'s by using !+ and checking if yyleng is even or odd.
  this allows us to simplify ! handling in parse.yacc
1999-08-04 07:54:34 +00:00
Todd C. Miller
014bd22934 -u flag was being ignored 1999-08-04 07:53:04 +00:00
Todd C. Miller
3fc0ab7680 correct fix 1999-08-01 17:04:05 +00:00
Todd C. Miller
896c2748e1 work around pod2man stupididy 1999-08-01 16:37:07 +00:00
Todd C. Miller
3e8a6d4962 correct dependencies for .cat 1999-08-01 16:35:06 +00:00
Todd C. Miller
762fb6a664 regen 1999-08-01 16:26:16 +00:00
Todd C. Miller
29974bceb3 Add copyright
Update to reality
1999-08-01 16:25:25 +00:00
Todd C. Miller
6b3909c780 rename validate() to the more descriptive sudoers_lookup() 1999-08-01 15:42:12 +00:00
Todd C. Miller
ef4302501f use tgetpass 1999-08-01 10:49:41 +00:00
Todd C. Miller
ff7b468661 updates 1999-07-31 16:32:56 +00:00
Todd C. Miller
5a51e05e63 Sudo, not CU Sudo 1999-07-31 16:31:27 +00:00