def do_implant(self, implant): '''implant [IP of implant] sets lp to use, defaults to 127.0.0.1 ''' if tools.checkIP(implant) == True: self.sfile['implant'] = implant self.logger.debug('implant IP has been changed to: ' + str(implant)) else: self.logger.error('the IP that you entered is not valid')
def do_lp(self, lp): '''lp [IP of lp] sets lp to use, defaults to 127.0.0.1 ''' if tools.checkIP(lp) == True: self.sfile['lp'] = lp self.logger.debug('LP IP has been changed to: ' + str(lp)) else: self.logger.error('the IP that you entered is not valid')
def do_attk_source(self, attk_source): '''attk_source [IP] IP of attacker''' if tools.checkIP(attk_source) == True: tunnel_dict = self.sfile['current_rule'] tunnel_dict['attk_source'] = attk_source self.sfile['current_rule'] = tunnel_dict self.logger.debug('changed attk_source to ' + str(attk_source)) else: self.logger.error('The IP you entered is not valid')
def do_tgt_source(self, tgt_source): '''tgt_source [IP] source IP of target (what IP the target will see)''' if tools.checkIP(tgt_source) == True: tunnel_dict = self.sfile['current_rule'] tunnel_dict['tgt_source'] = tgt_source self.sfile['current_rule'] = tunnel_dict self.logger.debug('changed tgt_source to ' + str(tgt_source)) else: self.logger.error('The IP you entered is not valid')
def do_attk_dest(self, attk_dest): '''attk_dest [IP] IP destination of attacker''' if tools.checkIP(attk_dest) == True: tunnel_dict = self.sfile['current_rule'] tunnel_dict['attk_dest'] = attk_dest self.sfile['current_rule'] = tunnel_dict self.logger.debug('changed attk_dest to ' + str(attk_dest)) else: self.logger.error('The IP you entered is not valid')
def do_tgt_dest(self, tgt_dest): '''tgt_dest [IP] targets IP''' if tools.checkIP(tgt_dest) == True: tunnel_dict = self.sfile['current_rule'] tunnel_dict['tgt_dest'] = tgt_dest self.sfile['current_rule'] = tunnel_dict self.logger.debug('changed tgt_dest to: ' + str(tgt_dest)) else: self.logger.error('The IP you entered is not valid')