Computing

Mac Address Changer

Submitted by ZiZien, , Thread ID: 78937

Thread Closed

RE: Mac Address Changer

This post was last modified: 11-03-2018, 03:26 PM by Bassdrop
#4
Since a network device can't be active/in-use while its MAC address is being changed, you'll be constantly disabling/re-enabling your network connection by doing it every minute...

That said, to do it in Linux,you can install "macchanger" from your regular repository (or grab it from http://gnu.org/software/macchanger/ ).

Assuming the networkinterfaceyou want to change is "eth0", from a shellprompt you'll want to do the following (with root permisisons):

Code:
ifconfig eth0 down
macchanger -r eth0
ifconfig eth0 up


"ifconfig eth0 down" to disable the eth0 interface.
"macchanger -r eth0" to assign a new address (the -r flag randomizes it, or use -e instead to assign assign a random address using the same vendor.)
"ifconfig eth0 up" to bring the interface back up.

If it's a wireless card as opposed to an ethernet card, the interfacewill probablybe "wlan0" instead of "eth0" but you can list the availableinterfaces by typing "ip link show" or "ifconfig".


Then justadd a cron job (sudo crontab -e) toschedule it to runas frequently as you want.

Cheers,
B

Life is like a box of chocolates, it doesn't last as long for fat people.

Users browsing this thread: 1 Guest(s)