예제 #1
0
def ios(input: str, rules: str, net_sniffer: bool, no_resource: bool,
        all: bool, threads: int) -> None:
    try:
        # 初始化全局对象
        bootstrapper = Bootstrapper(__file__)
        bootstrapper.init()

        task = iOSTask(input, rules, net_sniffer, no_resource, all, threads)
        # 让内层代码直接抛出异常,不做rollback。
        task.start()
    except Exception as e:
        raise e
예제 #2
0
 def __tast_control__(self):
     task_info = {}
     # 调用Android 相关处理逻辑
     if self.types == "Android":
         task_info = AndroidTask(self.path, self.no_resource,
                                 self.package).start()
     # 调用iOS 相关处理逻辑
     elif self.types == "iOS":
         task_info = iOSTask(self.path, self.no_resource).start()
     # 调用Web 相关处理逻辑
     else:
         task_info = WebTask(self.path).start()
     return task_info
예제 #3
0
    def __tast_control__(self):
        task_info = {}
        # 自动根据文件后缀名称进行修正
        cache_info = DownloadTask().start(self.path,self.types)
        cacar_path = cache_info["path"]
        types = cache_info["type"]
        
        if (not os.path.exists(cacar_path) and cores.download_flag):
            print("[-] File download failed! Please download the file manually and try again.")
            return task_info

        # 调用Android 相关处理逻辑
        if types == "Android":
            task_info = AndroidTask(cacar_path,self.package).start()
        # 调用iOS 相关处理逻辑
        elif types == "iOS":
            task_info = iOSTask(cacar_path).start()
        # 调用Web 相关处理逻辑
        else:
            task_info = WebTask(cacar_path).start()
        return task_info