code: func IsMAC(str string) bool {
  	_, err := net.ParseMAC(str)
  	return err == nil
  }
docs: // IsMAC check if a string is valid MAC address.
  // Possible MAC formats:
  // 01:23:45:67:89:ab
  // 01:23:45:67:89:ab:cd:ef
  // 01-23-45-67-89-ab
  // 01-23-45-67-89-ab-cd-ef
  // 0123.4567.89ab
  // 0123.4567.89ab.cdef