#! /bin/sh #---------------------------------------------------------------------------- # list-users - list users # # Copyright (c) 2001-2003 Frank Meyer # # Creation: 04.11.2001 fm # Last Update: 15.08.2003 fm # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. #---------------------------------------------------------------------------- gotoyx () { echo -e "\033[$1;$2H\c"; } echoyx () { echo -e "\033[$1;$2H\c"; shift; shift; echo -e "$*\c"; } IFS=':' while read line do set -- $line eval group_$3=$1 done /dev/null` password=`grep "^$user:" /etc/shadow | sed 's/:\*:/:\\\*:/g' | sed 's/:!:/:\\\*:/g'` set -- $password password="$2" shells=`grep "^$shell\$" /etc/shells` if [ "$ftpusers" != "" -o $uid = 0 -o "$password" = '\*' -o "$shells" = "" ] then echoyx $row 49 "no" else echoyx $row 49 "yes" fi echoyx $row 54 $name # name row=`expr $row + 1` if [ $row = 21 ] then echo echo /var/install/bin/anykey <$tty clrhome colecho "List users" gn echo colecho " User Uid Group Gid FTP Name" x x br row=4 fi done