'Takes a number of network bits, and returns the corresponding netmask
as an IPAddr6.'

@staticmethod
def cidr_to_netmask(bits):

    v = ((1 << bits) - 1)
    v = (v << (128 - bits))
    return IPAddr6.from_num(v)
