Managing users in Kali is not an everyday task, but you will probably use it occasionally. Personally, I rarely use the following commands, but sometimes, you might need to handle user management:
- To add a user with sudo capabilities in Kali, use the following command:
useradd -m [username] -G sudo -s /bin/bash
- If you're logged in and you want to elevate your privilege to a root user, try this command:
su - [desired root user name]
- If you're logged in and you want to execute a root command, use the following:
sudo [application name]
- To change the root (or any user's) password, use the following:
passwd [user name]
- The shadow file is important in Kali, because it stores the hashed passwords and some useful information about users. For example, I created a user called gus on Kali, so, to get his information, I should execute the following...