Being a kali user, You will need to spoof or change your MAC address several times. MAC (Media Access Control) address is a unique address assigned to every network interface to be used for communication within network segments.
It is a 12-digit hexadecimal number commonly used in IEEE802 network technologies including Wi-Fi, Bluetooth, and Ethernet. It is also known as the physical address or hardware address of a network. Kali Linux is mostly used for penetration testing. Sometimes, It is necessary to change the MAC address to remain anonymous or to remain secured.
macchanger is a tool used to change the MAC address of the network interfaces to a desired or random address temporarily. Once the device is rebooted, it will revert back to the original MAC address. In this article, We will see how to change the MAC address using the macchanger tool in Kali Linux.
Install macchanger
Kali Linux already has the macchanger tool installed. If it is not installed, you can install it by executing the following commands:
sudo apt update
sudo apt install macchanger

Change the MAC address to a random address
To change the MAC address, We need to turn off the network interface. It can be done using the ifconfig command. Here, we have a wifi network interface wlan0 whose MAC address we have to change. Execute the following command to turn off the network interface:
sudo ifconfig wlan0 down
Now, use macchanger with the -r parameter to change the MAC address to a random address.
sudo macchanger -r wlan0
Once the MAC address is changed, turn on the network interface by executing the following command:
sudo ifconfig wlan0 up

Now, Check the current MAC address by executing the following command:
macchanger -s wlan0

Other Features of macchanger
Note: Always turn off the network interface (as we did above) for every command that we will discuss below using the ifconfig command.
Change MAC address to a specific address
To change the MAC address to a specific address, -s parameter is used. You can enter the MAC address of your choice. Execute the following command to set the MAC address:
sudo macchanger -m XX:XX:XX:XX:XX:XX <network_interface>
sudo macchanger -m 00:2t:d0:f0:r3:ee wlan0

Change MAC address to a random address (known vendor)
To change the MAC address to a random address but with a known vendor, -A is used. Don’t confuse it with -r parameter, -r also changes to a random address but with no vendor. Execute the following command with -A parameter:
sudo macchanger -A wlan0

Change MAC address to a random address (same vendor)
To change the MAC address to a random address with the same vendor, -a is used. Execute the following command:
sudo macchangern -a wlan0

Print a list of known vendors
To print the list of all the known vendors available, Execute the following command with -l parameter:
sudo macchanger -l

To list only the wireless network, Just type the keyword followed by the –list parameter,
macchanger --list wifi

Reset to the original MAC address
To change back to the original MAC address, execute the following command:
sudo macchanger -p wlan0

However, once you reboot the system, your spoofed MAC address will change back to its original MAC address automatically.
Conclusion
So, We discussed how to change the MAC address using macchanger in Kali Linux. We also covered the different parameters that can be used with the macchanger tool. We can also change the MAC address using the if config command (without macchanger tool). But using macchanger is easy, especially for beginners. Thank you for reading!