def slaac(value, query=''):
 try:
  vtype = ipaddr(value, 'type')
  if (vtype == 'address'):
   v = ipaddr(value, 'cidr')
  elif (vtype == 'network'):
   v = ipaddr(value, 'subnet')
  if (ipaddr(value, 'version') != 6):
   return False
  value = netaddr.IPNetwork(v)
 except:
  return False
 if (not query):
  return False
 try:
  mac = hwaddr(query, alias='slaac')
  eui = netaddr.EUI(mac)
 except:
  return False
 return eui.ipv6(value.network)

def slaac ( value , query = '' ) : try : vtype = ipaddr ( value , 'type' ) if ( vtype == 'address' ) : v = ipaddr ( value , 'cidr' ) elif ( vtype == 'network' ) : v = ipaddr ( value , 'subnet' ) if ( ipaddr ( value , 'version' ) != 6 ) : return False value = netaddr . IPNetwork ( v ) except : return False if ( not query ) : return False try : mac = hwaddr ( query , alias = 'slaac' ) eui = netaddr . EUI ( mac ) except : return False return eui . ipv6 ( value . network )
get the slaac address within given network .