mirror of
https://github.com/MacosPorters/betterxen.git
synced 2026-11-27 00:10:43 +00:00
Parse import directories with one bounded parser shared by the static probe and the binder, and resolve imports through one registry lookup. Refuse conflicting registrations, keep ordinals apart from names, match API sets exactly, and bind only when every import resolves. Generate typed Win64 adapters, metadata and a coverage report from a declarative service registry. Pass floating-point arguments and results in XMM registers, and stop the guest if a service changes a nonvolatile register. Make unimplemented generated wrappers fail explicitly. Verify 20 services by calling them from translated guest code through bound import slots, and the parser on damaged tables. Refs #201, #270 Signed-off-by: jelly013 <22855910+jelly013@users.noreply.github.com>
58 lines
1.9 KiB
Rust
58 lines
1.9 KiB
Rust
// SPDX-License-Identifier: GPL-3.0-or-later
|
|
|
|
//! Xenora Loader crate.
|
|
//!
|
|
//! Provides PE32+ parsing, isolated guest virtual memory, bounded x86-64 CPU
|
|
//! execution bootstrap, and read-only binary triage.
|
|
|
|
pub mod arm64;
|
|
pub mod cpu;
|
|
pub mod dbt;
|
|
pub mod graphics;
|
|
pub mod import_table;
|
|
pub mod imports;
|
|
pub mod jit;
|
|
pub mod memory;
|
|
pub mod pe;
|
|
pub mod probe;
|
|
pub mod reloc;
|
|
pub mod runtime;
|
|
#[rustfmt::skip]
|
|
pub mod runtime_table;
|
|
pub mod services;
|
|
pub mod softfloat;
|
|
pub mod startup;
|
|
pub mod tls;
|
|
pub mod triage;
|
|
pub mod x86_decode;
|
|
pub mod x86_exec;
|
|
pub mod x86_float;
|
|
pub mod x86_simd;
|
|
#[rustfmt::skip]
|
|
pub mod x86_table;
|
|
|
|
pub use arm64::Arm64Assembler;
|
|
pub use cpu::{CpuState, ExecutionResult, ExitReason, Interpreter, RFlags, Register};
|
|
pub use dbt::{DbtEngine, DbtMetrics};
|
|
pub use graphics::{
|
|
BackendRenderer, CommandListType, ExecutionOutcome, FramePresentation, GraphicsBackendId,
|
|
GraphicsCommand, GraphicsCommandAllocator, GraphicsCommandList, GraphicsCommandQueue,
|
|
GraphicsContext, GraphicsError, GraphicsHandle, GraphicsResource, ResourceDesc,
|
|
ResourceDimension, ResourceStates,
|
|
};
|
|
pub use imports::{ImportError, ImportRegistry, ServiceDescriptor, ServiceHandler, Win64Args};
|
|
pub use jit::{JitError, JitMemory};
|
|
pub use memory::{GuestMemory, MemoryError, MemoryPermissions};
|
|
pub use pe::{LoadedImage, ParsedPe, PeError, PeSection};
|
|
pub use probe::{
|
|
ImportedSymbol, InstructionRecord, ProbeConfig, ProbeReport, RelocationCensus, TlsCensus,
|
|
probe_pe_bytes, run_probe_and_export,
|
|
};
|
|
pub use reloc::{
|
|
IMAGE_REL_BASED_ABSOLUTE, IMAGE_REL_BASED_DIR64, RelocationError, RelocationReport,
|
|
apply_relocations,
|
|
};
|
|
pub use services::{Clock, MockClock, ServicesState, SystemClock, register_standard_services};
|
|
pub use tls::{TlsDirectory, TlsError, execute_tls_callbacks, parse_tls_directory, setup_tls};
|
|
pub use triage::{TriageReport, triage_bytes, triage_file};
|