Top 10 Things to Do After Installing Kali Linux
Introduction
Kali Linux is a powerful operating system designed for Offensive Security, Digital forensics, and Penetration testing. Whether you’re a seasoned Cybersecurity professional, Ethical Hacker, Red Teamer, Security Researcher, or an aspiring hacker, setting up your Kali Linux machine is crucial for a smooth and enhanced experience.
After installing Kali Linux, there are several important steps you should take to enhance its security that we think you should try so you can improve its functionality and tailor it to your needs. This guide will walk you through the top 10 things you should do right after installing Kali Linux. From changing the default password to customizing your terminal, making it cool, and adding nice features, these steps will help you create a more efficient and personalized Kali Linux environment.
Remember, Kali Linux is a very powerful tool designed for ethical hacking and security researchers.
Have you just finished setting up a new Kali Linux machine? Great!
See Also: So you want to be a hacker?
Offensive Security and Ethical Hacking Course
Here are the top 10 things you should do to get it ready for use
1. Change the Default Password
The first thing you should do is change the default password. Security risk: Kali Linux uses “kali” for both the username and password by default. This is widely known, making it extremely easy for anyone to access your system if left unchanged. ‘root’ is the superuser account in Linux systems. It has unrestricted access to all commands, files, and resources.
To change it:
1. Open the terminal
2. Type `sudo su` and press Enter
3. Type `passwd root` and/or `passwd kali` and Press Enter
4. Follow the prompts to set a new, strong password for either username.
5. Restart your computer and log in as root or kali with your new password
2. Update the System
Keeping your system up-to-date is crucial for security and performance. Kali Linux releases a lot of updates frequently.
You can create also an automated script in Python that can rapidly run the whole process of updating the OS operation. To automate the process further, you can add this script to your cron jobs. This way, the system will update automatically without you needing to remember to run the process. Here’s how:
Automating the Update Process
1. Open the terminal
2. Type these commands one by one:
– `apt update` (checks for updates)
– `apt –list upgradable` (shows what can be upgraded)
– `apt-get full-upgrade -y` (installs updates)
– `apt dist-upgrade -y` (upgrades the distribution)
– `apt autoremove -y` (removes unnecessary packages)
– `apt autoclean -y` (cleans up the system)
Scheduling Automated Updates
- Open the crontab file
crontab -e
- Add a line to run the script weekly for example every Sunday at 2 AM
0 2 * * 0 /usr/bin/python3 /path/to/your/update_system.py
Bonus Tip:
Here is a one-liner that can also not just update your operating system, but perform cleaning and can be saved in a bash script for ease of use:
apt-get update -y && apt-get full-upgrade -y && apt-get dist-upgrade -y && apt autoremove -y && apt autoclean
See Also: Offensive Security Tool: TerminatorZ
3. Set Up SSH (If Needed)
By default, SSH (Secure Shell) is turned off in Kali Linux to minimize potential security vulnerabilities, particularly when you have the default open port on 22, it can be exploited in various ways. However, if you need to enable SSH for remote access, file transfer, or other secure communications, you can easily configure and start the SSH service. Here’s a step-by-step guide:
1. Open the terminal
2. Type `nano /etc/ssh/sshd_config` to edit the SSH config file
3. Make these changes:
– Set `Port 7` (or any port you prefer)
– Set `ListenAddress 0.0.0.0`
– Set `MaxAuthTries 3`
– Set `MaxSessions 7`
– Set `PasswordAuthentication yes`
– Set `PermitRootLogin yes`
4. Save and exit the file
5. Type `systemctl start ssh` to start SSH
6. Type `systemctl status ssh` to check if it’s running
4. Install Additional Drivers
After setting up SSH and ensuring secure remote access, you might find that some hardware components in your system, such as Wi-Fi cards, graphics cards, or other peripherals, require additional drivers to function properly. Kali Linux, being a specialized distribution, might not always come with all drivers pre-installed, especially for proprietary hardware.
1. Open the terminal
2. Type `apt install firmware-linux` to install additional firmware
3. Use these commands to check your hardware:
– `dmesg | grep -i firmware`
– `lspci -k`
– `hwinfo –short`
– `hwinfo bios`
5. Set Up Bash or ZSH Aliases
Aliases are a great way to simplify and speed up your workflow by creating shortcuts for frequently used commands. On Kali Linux, you can set up aliases to save time and avoid typing long commands repeatedly.
- Open the terminal
- Type `nano ~/.bashrc` or `nano ~/.zshrc` to edit your bash or ZSH config
- Add aliases like this: `alias findmyip=`curl ipecho.net/plain ; echo`
- Save and exit the file
- Type `source ~/.bashrc` or `source ~/.zshrc` to apply changes depending on the terminal you are using.
What this will do is whenever you type ‘findmyip, it will automatically display your external IP address.
6. How to List Available Metapackages
Kali Linux metapackages are bundles of related tools that cater to specific purposes or tasks, making it easier to install all the tools you need with a single command. This is particularly useful for setting up a tailored penetration testing environment, as you can choose from various metapackages based on your needs. For Example, you can convert your Kali into a Digital Forensics only machine, or a Full edition with every single offensive security tool installed.
What Are Metapackages?
Metapackages are essentially “toolkits” grouped by category. When you install a metapackage, you’re installing all the tools and software associated with that category. For example, there are metapackages for wireless testing, forensics, or web application testing.
- Open the terminal
- Type these commands:
– `apt update`
– `apt full-upgrade -y`
– `apt install -y kali-linux-default`
- Type `kali-tweaks` to open a menu for more customization options
For more options, you can check them here.
7. Customize the Kali Linux Interface
Customizing the Kali Linux interface can enhance your productivity and comfort, making your environment more suitable for your workflow. There are various ways to personalize the Kali interface, from tweaking the desktop environment to adding themes, changing icons, and setting up custom key bindings.
Make Kali look how you want:
- Go to Menu > Settings > LightDM GTK Greeter settings
- Change the background, icons, and other visual elements
- To change the login screen background, go to `/usr/share/desktop-base/kali-theme/login` in the file manager
To change the default XFCE to a nicer and more rich interface you can install the KDE version.
Open your terminal and type:
sudo apt install -y kali-desktop-kde
sudo update-alternatives –config x-session-manager
apt purge –autoremove kali-desktop-xfce
8. Install Useful Terminal Tools
Kali Linux provides a default terminal that is quite powerful, but sometimes you may need additional features or better functionality for more efficient workflow. Tools like guake and terminator can enhance your terminal experience.
Installing and Using guake
guake is a terminal multiplexer similar to tmux that allows for splitting windows, running multiple terminal sessions within a single window, and creating panes and tabs. It is lightweight and very customizable.
Some handy terminal tools to install:
- Open the terminal
- Type these commands:
– `apt install guake` (for a drop-down terminal)
– `apt install terminator` (for multiple terminals in one window)
To monitor your network, you can also install tools for bandwidth monitoring, such as bmon, bpytop, in the same way.
9. Add Fun Terminal Customizations
Customizing your terminal can make your daily work more enjoyable and personalized. There are a variety of fun and useful tools that can spice up your terminal experience in Kali Linux. Here are some tools to consider adding to your terminal setup.
Make your terminal more enjoyable with these fun tools:
- Open the terminal
- Type these commands:
– `apt install lolcat cowsay sl`
– `pip install lolcat`
– `apt install toilet`
- Try them out by typing `cowsay Hello | lolcat` or just `sl`, or `toilet hello world | lolcat`
10. Set Up Tor for Anonymous Browsing
To enhance privacy and anonymity online, setting up Tor on your Kali Linux system is a great option. Tor routes your internet traffic through a network of volunteer-operated servers (nodes) to conceal your location and usage from anyone conducting network surveillance or traffic analysis using Socks5 an internet protocol used by Tor itself.
For more private browsing:
- Open the terminal
- Type `apt install tor torbrowser-launcher`
- Once installed, you can launch Tor Browser from the application menu
We hope that this write up has taught you something new. If you enjoyed it, the best way that you can support us is to share it! If you’d like to hear more about us, you can find us on LinkedIn, Twitter, YouTube.
Are you a security researcher? Or a company that writes articles about Cyber Security, Offensive Security (related to Information Security in general) that match with our specific audience and is worth sharing? If you want to express your idea in an article contact us here for a quote: [email protected]