The official Kali Linux VM comes with
ssh disabled. I like to have
ssh available so I can run commands from Terminal on my host to the VM. I only enable
ssh in testing environments. Follow the steps to enable
apt-get install ssh systemctl enable ssh service ssh start
Now we need to edit the config file to allow root logins. I use
vim, if you're new replace
nano in the command below to make editing easier.
Change the following line from
Make sure you remove the
# or else it won't work.
service ssh restart
After restarting the service, the root user can successfully