Validates if the given string is a valid MAC address.
static bool isValidMacAddress(String mac) { final regex = RegExp(r'^[0-9A-Fa-f]{2}(:[0-9A-Fa-f]{2}){5}\$'); return regex.hasMatch(mac); }