PyPeLoader (version 0.0.1)
index
pypeloader.py

This package implements a basic PE loader in python (can load simple
executable like calc.exe, net1.exe, little malwares...)

 
Modules
       
ctypes
ctypes.wintypes

 
Functions
       
load(file: _io._BufferedIOBase) -> None
This function does all steps to load and execute the PE program in memory.
load_headers(file: _io._BufferedIOBase) -> PyPeLoader.PeHeaders
This function returns all PE headers structure from file.
load_imports(pe_headers: PyPeLoader.PeHeaders, ImageBase: int) -> None
This function loads imports (DLL, libraries), finds the functions addresses
and write them in the IAT (Import Address Table).
load_in_memory(file: _io._BufferedIOBase, pe_headers: PyPeLoader.PeHeaders) -> int
This function loads the PE program in memory
using the file and all PE headers.
load_relocations(pe_headers: PyPeLoader.PeHeaders, ImageBase: int) -> None
This function overwrites the relocations with the difference between image
base in memory and image base in PE headers.
main() -> int
This is the main function to start the program from command line.

 
Data
        __all__ = ['main', 'load', 'load_headers', 'load_in_memory', 'load_imports', 'load_relocations']
__author_email__ = 'mauricelambert434@gmail.com'
__copyright__ = '\nPyPeLoader Copyright (C) 2025 Maurice Lambert...ome to redistribute it\nunder certain conditions.\n'
__description__ = '\nThis package implements a basic PE loader in py...ble like calc.exe, net1.exe, little malwares...)\n'
__license__ = 'GPL-3.0 License'
__maintainer__ = 'Maurice Lambert'
__maintainer_email__ = 'mauricelambert434@gmail.com'
__url__ = 'https://github.com/mauricelambert/PyPeLoader'

 
Author
        Maurice Lambert