Ejemplo n.º 1
0
def extract_file_export_names(pe, file_path):
    base_address = pe.OPTIONAL_HEADER.ImageBase

    if hasattr(pe, "DIRECTORY_ENTRY_EXPORT"):
        for export in pe.DIRECTORY_ENTRY_EXPORT.symbols:
            try:
                name = export.name.partition(b"\x00")[0].decode("ascii")
            except UnicodeDecodeError:
                continue
            va = base_address + export.address
            yield Export(name), va
Ejemplo n.º 2
0
Archivo: file.py Proyecto: wisdark/capa
def extract_file_export_names():
    """extract function exports"""
    for (_, _, ea, name) in idautils.Entries():
        yield Export(name), ea
Ejemplo n.º 3
0
def extract_file_export_names(vw, file_path):
    for va, etype, name, _ in vw.getExports():
        yield Export(name), va
Ejemplo n.º 4
0
def extract_file_export_names(smda_report, file_path):
    lief_binary = lief.parse(file_path)
    if lief_binary is not None:
        for function in lief_binary.exported_functions:
            yield Export(function.name), function.address
Ejemplo n.º 5
0
Archivo: file.py Proyecto: clayne/capa
def extract_file_export_names(vw, **kwargs):
    for va, _, name, _ in vw.getExports():
        yield Export(name), va
Ejemplo n.º 6
0
def extract_file_export_names(data: DataUnit):
    for addr, name in data.obj.bin.export_functions.items():
        yield Export(name), addr
Ejemplo n.º 7
0
def extract_file_export_names(buf, **kwargs):
    lief_binary = lief.parse(buf)

    if lief_binary is not None:
        for function in lief_binary.exported_functions:
            yield Export(function.name), function.address