Zero Modification Export Hooking via Dynamic Proxy
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Existing methods for proxying target libraries in computer systems either modify the original files, leading to issues with digital signatures and compatibility, or fail to maintain the original deployment, causing disruptions during application repairs or updates.
Innovation Solution
The implementation of a template proxy library that can be dynamically tailored at runtime to act as a proxy for the target library, allowing for zero modification export hooking without altering the original library or application deployment.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Adaptability or versatility
If the original library files are modified to implement proxying, then the proxying functionality can be achieved, but digital signatures are compromised and compatibility issues arise
Solution Approach 1:
The patent introduces a proxy library as an intermediary component that sits between the application and the target library. The proxy library contains forwarding references that redirect calls to the target library without modifying the target library files themselves. This intermediary approach enables proxying functionality while preserving the original digital signatures and file integrity of the target library.
Solution Approach 2:
The patent creates a copy of the library import mechanism through the proxy library. Instead of modifying the original library files, the system creates a duplicate import structure in the proxy library that mirrors the target library's interface. This copy contains forwarding references that redirect to the actual target library, enabling functionality substitution without touching the original files.
2Adaptability or versatility
If the original library files are modified to implement proxying, then the proxying functionality can be achieved, but compatibility and deployment continuity are disrupted
Solution Approach 1:
The proxy library serves as a mediator that intercepts library loading requests and redirects them appropriately. When an application requests a library, the proxy library's forwarding references redirect the call to the target library. This intermediary mechanism enables proxying without modifying deployment structures, allowing seamless application repairs and updates.
Solution Approach 2:
The patent segments the library loading process into distinct components: the proxy library handling interception and forwarding, and the target library maintaining its original functionality. This segmentation allows the proxying mechanism to operate independently without affecting the target library's deployment, repair, or update processes.
3Adaptability or versatility
If a template proxy library is dynamically tailored at runtime, then zero modification export hooking is achieved, but system complexity increases
Solution Approach 1:
The patent implements dynamic tailoring of the template proxy library at runtime. The system detects which target library is being loaded and dynamically configures the proxy library's forwarding references to match the specific target library's export symbols. This dynamic adaptation enables zero-modification export hooking for different libraries without requiring separate static configurations for each library.
Solution Approach 2:
The system changes parameters of the proxy library at runtime based on the target library being proxied. The forwarding references in the proxy library are dynamically adjusted to point to the correct target library exports. This parameter change approach allows the same template proxy library to adapt to multiple different target libraries without modification to the target libraries themselves.
Data Source
AI summary
A first request may be received from a loader to create a first file handle corresponding to a first library, where the first request may include a first identifier corresponding to the first library, and where the loader may be part of an operating system of a computer system. It may be determined that the first library is to be proxied by a second library. The first identifier in the first request may be replaced with a second identifier corresponding to the second library. The first file handle may be created based on the first request. The first file handle may be provided to the loader. An export section of a first image corresponding to the first file handle may be customized when the first image is mapped into a memory.


