Last active
December 9, 2023 06:53
-
-
Save ajinabraham/dcdf6b7118f0e9eeba95d8d99ddfd394 to your computer and use it in GitHub Desktop.
macOS WiFi MAC Address Spoofer
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
interface=en0 | |
echo "Disconnecting from WiFi SSID" | |
sudo /System/Library/PrivateFrameworks/Apple80211.framework/Versions/Current/Resources/airport -z | |
echo "Turning down ${interface}" | |
sudo ifconfig -d $interface | |
mac=$(printf '02:00:00:%02X:%02X:%02X\n' $((RANDOM%256)) $((RANDOM%256)) $((RANDOM%256))) | |
echo "Generated Random MAC Address: ${mac}" | |
sudo ifconfig $interface ether $mac | |
echo "MAC address spoofed" | |
ifconfig $interface lladdr | grep ether |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Run
sudo ./mac-spoofer.sh
Tested on macOS Sonoma 14.1.2