How to Change Your Wireless MAC Address
Learn how to change or spoof your MacBook's wireless MAC address. This recipe make use of on-demand event with Power Manager.
When your Mac connects to a wireless network, your Mac is identified by its MAC address. This address allows hotels and other wireless hotspot providers to identify and track your Mac.
If your Mac’s wireless MAC address changes, the hotspot provider will likely consider your Mac to be a new previously unseen device. Being able to do this is good for security and likely useful where Internet access is time limited per device.
This technique is often called spoofing your MAC address.
To see your current MAC wireless address, use the following Terminal.app command:
ifconfig en1 | grep ether
In this recipe, we will create an on-demand Power Manager event to randomly assign a new MAC address to your Mac. This change is temporary and reset when your Mac is next restarted.
Reassigning MAC On-Demand
Launch Power Manager.
Select Add… to create a new event.
Choose the Run a script on-demand task.
Continue to the Script step.
Copy and paste in the following
perl
script into the Script to run field:#!/usr/bin/perl # Disconnect from the network system('/System/Library/PrivateFrameworks/Apple80211.framework/Versions/Current/Resources/airport -z'); # Create a random ethernet address my @mac; for ($i=0;$i<6;$i++) { @mac[$i]=int(rand(256)); } my $mac = sprintf("%02x:%02x:%02x:%02x:%02x:%02x\n",@mac); # Apply the random ethernet address `ifconfig en1 ether $mac`;
Select Super User (root) in the Environment: pop-up.
Continue through the Constraints step.
Continue to Why and name your new event.
Continue to Confirm and Add your new event.
The new on-demand event is available immediately. You can trigger the event through the Power Manager status menu, or through the Power Manager application.