Skip to content

Generate a random Mac address. There are some rules like qemu/kvm, xen, apple, huawei etc.

License

Notifications You must be signed in to change notification settings

kyyee/random-mac

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

random-mac

Generate a random Mac address. There are six method for you.

Method introduction

  • randomMac() generate a totally random mac address.
  • randomMacWithOui() generate a random mac address with three number in the front like {0x32, 0x21, 0xa2}.
  • randomMac4Qemu() generate a random mac address for qemu/kvm, because the oui of qemu/kvm is {52, 54, 00}.
  • invoke randomMac4Xen(), randomMac4Apple(), randomMac4Huawei() reference randomMac4Qemu

Reference

The OUI list is available.

About

Generate a random Mac address. There are some rules like qemu/kvm, xen, apple, huawei etc.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages