Created
July 12, 2017 06:46
-
-
Save denmojo/697c671c820b35c369f65230ec56758e to your computer and use it in GitHub Desktop.
Spoof MAC address on macOS
This file contains hidden or 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
| #!/bin/sh | |
| sudo ifconfig en0 ether $(openssl rand -hex 6 | sed 's%\(..\)%\1:%g; s%.$%%') |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If you get a "unable to write 'random state' message when attempting this, try looking for a file ~./rnd and see if it's owned by root. Delete this file and try again.
This spoofing seemed to work and confuses the heck out of existing wifi connections as defined in System Preferences -> Networking. Set before initially connecting. Hardware reset will reset to normal MAC.
See also: https://github.com/feross/SpoofMAC