(ifaceid)
return ":".join(l)
Extract the mac address from provided iface ID. Iface ID is provided 
    in printable format ("XXXX:XXFF:FEXX:XXXX", eventually compressed). None 
    is returned on error.
Extract the mac address from provided iface ID. Iface ID is provided 
    in printable format ("XXXX:XXFF:FEXX:XXXX", eventually compressed). None 
    is returned on error.
Extract the mac address from provided iface ID . Iface ID is provided in printable format ( XXXX : XXFF : FEXX : XXXX eventually compressed ) . None is returned on error .
def in6_ifaceidtomac(ifaceid): # TODO: finish commenting function behavior
    """
    Extract the mac address from provided iface ID. Iface ID is provided 
    in printable format ("XXXX:XXFF:FEXX:XXXX", eventually compressed). None 
    is returned on error.
    """
    try:
        ifaceid = inet_pton(socket.AF_INET6, "::"+ifaceid)[8:16]
    except:
        return None
    if ifaceid[3:5] != '\xff\xfe':
        return None
    first = struct.unpack("B", ifaceid[:1])[0]
    ulbit = 2*[1,'-',0][first & 0x02]
    first = struct.pack("B", ((first & 0xFD) | ulbit))
    oui = first + ifaceid[1:3]
    end = ifaceid[5:]
    l = map(lambda x: "%.02x" % struct.unpack("B", x)[0], list(oui+end))
    return ":".join(l)
def in6_ifaceidtomac ( ifaceid ) : # TODO: finish commenting function behavior try : ifaceid = inet_pton ( socket . AF_INET6 , "::" + ifaceid ) [ 8 : 16 ] except : return None if ifaceid [ 3 : 5 ] != '\xff\xfe' : return None first = struct . unpack ( "B" , ifaceid [ : 1 ] ) [ 0 ] ulbit = 2 * [ 1 , '-' , 0 ] [ first & 0x02 ] first = struct . pack ( "B" , ( ( first & 0xFD ) | ulbit ) ) oui = first + ifaceid [ 1 : 3 ] end = ifaceid [ 5 : ] l = map ( lambda x : "%.02x" % struct . unpack ( "B" , x ) [ 0 ] , list ( oui + end ) ) return ":" . join ( l )