Revision a8434bc6

b/nfdhcpd/nfdhcpd
163 163
        elif line.startswith("EUI64="):
164 164
            eui64 = get_value(line)
165 165

  
166
    return Client(tap=tap, mac=mac, ip=ip, 
166
    return Client(tap=tap, mac=mac, ip=ip,
167 167
                  hostname=hostname, indev=indev, subnet=subnet,
168 168
                  gateway=gateway, subnet6=subnet6, gateway6=gateway6, eui64=eui64 )
169 169

  
......
190 190

  
191 191

  
192 192
class Client(object):
193
    def __init__(self, tap=None, indev=None, mac=None, ip=None, hostname=None, 
193
    def __init__(self, tap=None, indev=None, mac=None, ip=None, hostname=None,
194 194
                 subnet=None, gateway=None, subnet6=None, gateway6=None, eui64=None ):
195 195
        self.mac = mac
196 196
        self.ip = ip
......
449 449
        binding = parse_binding_file(path)
450 450
        if binding is None:
451 451
            return
452
        ifindex = self.get_ifindex(binding.indev)
452
        ifindex = self.get_ifindex(binding.tap)
453 453

  
454 454
        if ifindex is None:
455 455
            logging.warn("Stale configuration for %s found", tap)
......
475 475
        """
476 476
        # Decode the response - NFQUEUE relays IP packets
477 477
        pkt = IP(payload.get_data())
478
        logging.debug("IN DHCP RESPONCE")
479
        logging.debug(pkt.show())
478 480

  
479 481
        # Get the client MAC address
480 482
        resp = pkt.getlayer(BOOTP).copy()
......
573 575

  
574 576
        """
575 577
        pkt = IPv6(payload.get_data())
578
        logging.debug("IN RS RESPONCE")
579
        logging.debug(pkt.show())
576 580
        mac = pkt.lladdr
577 581
        logging.debug("rs for mac %s", mac)
578 582
        try:
......
584 588
            # handle it
585 589
            payload.set_verdict(nfqueue.NF_ACCEPT)
586 590
            return
587
  
591

  
588 592
        # Signal the kernel that it shouldn't further process the packet
589 593
        payload.set_verdict(nfqueue.NF_DROP)
590 594

  
......
615 619

  
616 620
        """
617 621
        ns = IPv6(payload.get_data())
622
        logging.debug("IN NS RESPONCE")
623
        logging.debug(ns.show())
618 624

  
619
        logging.debug("lladdr %s  src %sns.lladdr" , ns.lladdr, ns.src)
625
        logging.debug("dst %s  tgt %s" , ns.dst, ns.tgt)
620 626

  
621 627
        try:
622 628
          binding = self.clients[ns.lladdr]
......
627 633
          payload.set_verdict(nfqueue.NF_ACCEPT)
628 634
          return
629 635

  
630

  
631 636
        subnet = binding.net6
632 637
        if subnet.net is None:
633 638
          logging.debug("No IPv6 network assigned for the interface")

Also available in: Unified diff