(self)
return True
Shutdown the ARP spoofer
Shutdown the ARP spoofer
Shutdown the ARP spoofer
def shutdown(self):
        """ Shutdown the ARP spoofer
        """
        if not self.running:
            return
        Msg("Initiating ARP shutdown...")
        debug('initiating ARP shutdown')
        self.running = False
        time.sleep(2)  # give it a sec for the respoofer
        # rectify the ARP caches
        for target in self.targets:
            sendp(
                Ether(dst=self.victim[1], src=target[1]) / ARP(op='who-has', psrc=target[0], pdst=self.victim[0]),
                count=1)
            sendp(
                Ether(dst=target[1], src=self.victim[1]) / ARP(op='who-has', psrc=self.victim[0], pdst=target[0]),
                count=1)
        debug('ARP shutdown complete.')
        return True
def shutdown ( self ) : if not self . running : return Msg ( "Initiating ARP shutdown..." ) debug ( 'initiating ARP shutdown' ) self . running = False time . sleep ( 2 ) # give it a sec for the respoofer # rectify the ARP caches for target in self . targets : sendp ( Ether ( dst = self . victim [ 1 ] , src = target [ 1 ] ) / ARP ( op = 'who-has' , psrc = target [ 0 ] , pdst = self . victim [ 0 ] ) , count = 1 ) sendp ( Ether ( dst = target [ 1 ] , src = self . victim [ 1 ] ) / ARP ( op = 'who-has' , psrc = self . victim [ 0 ] , pdst = target [ 0 ] ) , count = 1 ) debug ( 'ARP shutdown complete.' ) return True