Skip to content

Instantly share code, notes, and snippets.

@FoxNeo
Created March 13, 2021 23:22
Show Gist options
  • Save FoxNeo/9822a2076b0c12db79fc8baacf4bf6e3 to your computer and use it in GitHub Desktop.
Save FoxNeo/9822a2076b0c12db79fc8baacf4bf6e3 to your computer and use it in GitHub Desktop.

Random MAC address Linux

If you are connected to a public Wifi and you want to change your MAC address to bypass 30 Minutes free sessions or for privacy, you can easily generate a random mac address every time.

Enable random MAC Address

sudo vi /etc/NetworkManager/conf.d/macchange.conf

Inside write the following lines:

#[device]
wifi.scan-rand-mac-address=yes

#[connection]
wifi.cloned-mac-address=random

Disable random MAC address

Just comment the lines with:

#wifi.scan-rand-mac-address=yes
#wifi.cloned-mac-address=random
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment