diff --git a/lib/cuckoo/common/demux.py b/lib/cuckoo/common/demux.py index fa42507f698..e2a0efef8d4 100644 --- a/lib/cuckoo/common/demux.py +++ b/lib/cuckoo/common/demux.py @@ -185,6 +185,7 @@ def _sf_children(child: sfFile): # -> bytes: _ = path_write_file(path_to_extract, child.contents) except Exception as e: log.error(e, exc_info=True) + # ToDo AttributeError: 'File' object has no attribute 'get_type' return (path_to_extract.encode(), child.platform, child.get_type(), child.get_size()) diff --git a/utils/rooter.py b/utils/rooter.py index 571db39f6ee..20f464ce050 100644 --- a/utils/rooter.py +++ b/utils/rooter.py @@ -49,16 +49,16 @@ def run(*args): def enable_ip_forwarding(sysctl="/usr/sbin/sysctl"): log.debug("Enabling IPv4 forwarding") - run([sysctl, "-w" "net.ipv4.ip_forward=1"]) + run(sysctl, "-w" "net.ipv4.ip_forward=1") def check_tuntap(vm_name, main_iface): """Create tuntap device for qemu vms""" try: - run([s.ip, "tuntap", "add", "dev", f"tap_{vm_name}", "mode", "tap", "user", username]) - run([s.ip, "link", "set", "tap_{vm_name}", "master", main_iface]) - run([s.ip, "link", "set", "dev", "tap_{vm_name}", "up"]) - run([s.ip, "link", "set", "dev", main_iface, "up"]) + run(s.ip, "tuntap", "add", "dev", f"tap_{vm_name}", "mode", "tap", "user", username) + run(s.ip, "link", "set", "tap_{vm_name}", "master", main_iface) + run(s.ip, "link", "set", "dev", "tap_{vm_name}", "up") + run(s.ip, "link", "set", "dev", main_iface, "up") return True except subprocess.CalledProcessError: return False