This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import pefile | |
import sys | |
from collections import defaultdict | |
checked_dlls = defaultdict(lambda: False) | |
def get_imported_dlls(pe): | |
"""Extract the list of imported DLLs from the PE file.""" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import logging | |
import subprocess | |
import sys | |
# Determine the log file name based on the script name | |
script_name = os.path.splitext(os.path.basename(__file__))[0] | |
log_filename = f"{script_name}.log" |