code: func (s *awsIPs) getCandidateNetworks(ip net.IP) []net.IPNet {
  	s.mutex.RLock()
  	defer s.mutex.RUnlock()
  	if ip.To4() != nil {
  		return s.ipv4
  	} else if ip.To16() != nil {
  		return s.ipv6
  	} else {
  		dcontext.GetLoggerWithFields(dcontext.Background(), map[interface{}]interface{}{
  			"ip": ip,
  		}).Error("unknown ip address format")
  		// assume mismatch, pass through cloudfront
  		return nil
  	}
  }
docs: // getCandidateNetworks returns either the ipv4 or ipv6 networks
  // that were last read from aws. The networks returned
  // have the same type as the ip address provided.