def is_valid_mac(addr):
addrs = addr.split('<STR_LIT::>')<EOL>if len(addrs) != <NUM_LIT:6>:<EOL><INDENT>return False<EOL><DEDENT>for m in addrs:<EOL><INDENT>try:<EOL><INDENT>if int(m, <NUM_LIT:16>) > <NUM_LIT:255>:<EOL><INDENT>return False<EOL><DEDENT><DEDENT>except ValueError:<EOL><INDENT>return False<EOL><DEDENT><DEDENT>return True<EOL>
Check the syntax of a given mac address.

    The acceptable format is xx:xx:xx:xx:xx:xx