Reloaded-Project / Reloaded.Hooks

Advanced native function hooks for x86, x64. Welcome to the next level!
GNU Lesser General Public License v3.0
213 stars 33 forks source link

Support Hook Deactivation #2

Closed Sewer56 closed 5 years ago

Sewer56 commented 5 years ago

Normal Hook Flow Diagram

 +-------------------+       +----------------+         
 | Original Function --------- ReverseWrapper |         
 | Start             |       +--------|-------+         
 +-------------------+                |                 
                                      |                 
                               +------|------+          
                               | C# Function |          
                               +------|------+          
                                      |                 
                                      |                 
                    +-----------------|----------------+
                    | Original Function Wrapper        |
                    |  Including x >= 6 bytes          |
                    |  long start of original function.|
                    +-----------------|----------------+
                                      |                 
                                      |                 
+-------------------+                 |                 
| Rest of Original  ------------------+                 
| Function          |                                   
+-------------------+                                   

Deactivated Hook Flow Diagram

 +-------------------+       +----------------+         
 | Original Function --------- ReverseWrapper ---+      
 | Start             |       +----------------+  |      
 +-------------------+                           |      
                               +-------------+   |      
                               | C# Function |   |      
                               +-------------+   |      
                                                 |      
                                      +----------|      
                                      |                 
                    +-----------------|----------------+
                    | Original Function Wrapper        |
                    |  Including x >= 6 bytes          |
                    |  long start of original function.|
                    +-----------------|----------------+
                                      |                 
                                      |                 
+-------------------+                 |                 
| Rest of Original  ------------------+                 
| Function          |                                   
+-------------------+  

It is important that the deactivated hook makes no interaction with any C# code. See Issue 5 of Reloaded II for which this issue was created.

Sewer56 commented 5 years ago

Completed as of version 1.1.0.