[sudo-users] Negation problems

Aimon Bustardo abustardo at mor.ph
Fri Jul 25 06:47:07 EDT 2008


I am having troubles with getting sudo to properly negate on CentOS 5:

%spokes  ALL=(ALL) ALL, /usr/bin/su [!-]*, !/usr/bin/su *root*, 
/usr/bin/vim *[!/etc/sudoers]*

 From the docs, this should allow everything except the three commands 
at the end. If I remove the ALL and manually enter items that can be run 
it works fine. However the moment I enter the ALL it allows everything. 
The rest of the line is not processed or is ignored.


Here is the output from sudo -V:

Sudo version 1.6.8p12

Authentication methods: 'pam'
Syslog facility if syslog is being used for logging: authpriv
Syslog priority to use when user authenticates successfully: notice
Syslog priority to use when user authenticates unsuccessfully: alert
Ignore '.' in $PATH
Send mail if the user is not in sudoers
Use a separate timestamp for each user/tty combo
Lecture user the first time they run sudo
Require users to authenticate by default
Root may run sudo
Allow some information gathering to give useful error messages
Visudo will honor the EDITOR environment variable
Set the LOGNAME and USER environment variables
Length at which to wrap log file lines (0 for no wrap): 80
Authentication timestamp timeout: 5 minutes
Password prompt timeout: 5 minutes
Number of tries to enter a password: 3
Umask to use or 0777 to use user's: 022
Address to send mail to: root
Subject line for mail messages: *** SECURITY information for %h ***
Incorrect password message: Sorry, try again.
Path to authentication timestamp dir: /var/run/sudo
Default password prompt: Password:
Default user to run commands as: root
Path to the editor for use by visudo: /bin/vi
When to require a password for 'list' pseudocommand: any
When to require a password for 'verify' pseudocommand: all
File containing dummy exec functions: /usr/libexec/sudo_noexec.so
Environment variables to check for sanity:
        LANGUAGE
        LANG
        LC_*
Environment variables to remove:
        PERL5OPT
        PERL5LIB
        PERLLIB
        JAVA_TOOL_OPTIONS
        SHELLOPTS
        PS4
        BASH_ENV
        ENV
        TERMCAP
        TERMPATH
        TERMINFO_DIRS
        TERMINFO
        _RLD*
        LD_*
        PATH_LOCALE
        NLSPATH
        HOSTALIASES
        RES_OPTIONS
        LOCALDOMAIN
        CDPATH
        IFS





Thanks,


-- 
Aimon Bustardo
Senior IT Architect
Morph Labs
Cell:  +1 310 625 0608
Office: +1 310 437 4898

 




More information about the sudo-users mailing list