Created
January 20, 2016 19:34
-
-
Save nixpulvis/d83c0ae70a4c3a06797b to your computer and use it in GitHub Desktop.
Change your MAC address on OS X.
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/bash | |
ssid=$(networksetup -getairportnetwork en0 | cut -d ":" -f 2 | sed "s/^[ \t]*//") | |
sudo airport -z | |
sudo ifconfig en0 ether $(openssl rand -hex 6 | sed "s/\(..\)/\1:/g; s/.\$//") | |
networksetup -setairportnetwork en0 "$ssid" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Useful for coffee shops and airports alike!