SplitScript reference / Module / peExport

Module.peExport

Method

Module.peExport(name: String) -> address!

Resolves a named function exported by a Windows PE module.

The parser validates the DOS, PE, optional, export-directory, name, ordinal, and function tables before returning the mapped function address. Forwarded exports are rejected because they name another module and function rather than code within this module.

Parameters

  • name: Exact case-sensitive export name.

Effects: reads process memory, requires an attached process

Runtime behavior: available while a process is attached, except in onDetach; synchronous

Examples

Resolve a Mono runtime entry point

let mono = await process.module("mono-2.0-bdwgc.dll")
let assemblyForeach = mono.peExport("mono_assembly_foreach") else return