#!/bin/sh # # 'su' by itself runs su-shell to become root with the CURRENT # environment. Otherwise it's just like 'su whoever'. This corrects # the deficiencies of the su command on HP/UX and SGI machines # (at least sort of) # # Eric Myers : 27 October 1995 # Department of Physics, University of Michigan, Ann Arbor, MI # @(#) $Revision: 1.2 $ $Date: 1999/03/22 18:41:06 $ #======================================================================* if [ $# -lt 1 ]; then logger -i -t su -p auth.notice "su 'root' by '$USER'" /bin/su root -c /usr/local/adm/su-shell else logger -i -t su -p auth.notice "su '$1' by '$USER'" /bin/su $* fi