Created
May 11, 2013 04:23
-
-
Save salexkidd/5558885 to your computer and use it in GitHub Desktop.
Random MAC ADDR Generator
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
def make_mac_addr(): | |
def random_hexer_gen(): | |
""" random hex num """ | |
while True: | |
yield "{:02x}".format(randint(0x00, 0xFF)).upper() | |
g = random_hexer_gen() | |
return ":".join([g.next() for i in range(0, 6)]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment