cn="$1"
pass=`tr -dc A-Za-z0-9_ < /dev/urandom | head -c 6`
exists=`grep -w $1 /tmp/users | wc -l`
dets=`grep -w $1 /tmp/users`
if [ $exists = 1 ]
then
echo "User exists"
echo $dets
else
useradd -d /home/$1 -e $(date -d "+14 day" +%D) -s /usr/libexec/openssh/sftp-server -M -N -p `mkpasswd $pass` -g sftpusers $1
mkdir -p /home/$1/uploads /home/$1/downloads /home/$1/.ssh
chown $1:sftpusers /home/$1/uploads /home/$1/downloads /home/$1/.ssh
chmod 700 /home/$1/.ssh
echo $pass
echo $(whoami) $(date +"%D %R") $1 $pass >> /tmp/users
fi
Page 1 of 1
AUTHOR
honk honk honk honk
honkity honkity honk honk
i need a command list interface to understand all of this
MCCCXXXVII quote:
i need a command list interface to understand all of this
first you need to download vmware so you can run windows on your macintosh so you can run putty
SPUTNIK quote:Are we sure he wasn't referring to command line interface? Either way, he was a stupid piece of shit.
first you need to download vmware so you can run windows on your macintosh so you can run putty
This is why I love networking so much. Because routers only do what I tell them to do.
RootKit quote:that's exactly what he was attempting to refer to
Are we sure he wasn't referring to command line interface? Either way, he was a stupid piece of shit.
This is why I love networking so much. Because routers only do what I tell them to do.
RootKit quote:most of the timne
Are we sure he wasn't referring to command line interface? Either way, he was a stupid piece of shit.
This is why I love networking so much. Because routers only do what I tell them to do.
i'm so lazy i can't even be bothered to think up random passwords anymore
SPUTNIK quote:The tempting thing about cisco catalyst IOS is that it would let me set the password to 'password' if I wanted to.
i'm so lazy i can't even be bothered to think up random passwords anymore
Page 1 of 1
Quick reply
Sign in to post a message.Times shown in Eastern Time (ET).
