Cara menambahkan user dengan akses root dan copy ssh key root
Di debian 10
1. #adduser masmalik
2. #usermod -aG sudo masmalik
3. #mkdir /home/masmalik/.ssh
4. #touch /home/masmalik/.ssh/authorized_keys
5. #cat /root/.ssh/authorized_keys > /home/masmalik/.ssh/authorized_keys
4. #chown -R masmalik:masmalik /home/masmalik/
5. #chown root:root /home/masmalik
6. #chmod 700 /home/masmalik/.ssh
7. #chmod 644 /home/masmalik/.ssh/authorized_keys
1. #adduser masmalik
2. #usermod -aG sudo masmalik
3. #mkdir /home/masmalik/.ssh
4. #touch /home/masmalik/.ssh/authorized_keys
5. #cat /root/.ssh/authorized_keys > /home/masmalik/.ssh/authorized_keys
4. #chown -R masmalik:masmalik /home/masmalik/
5. #chown root:root /home/masmalik
6. #chmod 700 /home/masmalik/.ssh
7. #chmod 644 /home/masmalik/.ssh/authorized_keys
Komentar
Posting Komentar