Comments (5)
Could you please provide an example to help me understand what you mean by passing arguments to DLLs at injection time?
from hookshot.
Could you please provide an example to help me understand what you mean by passing arguments to DLLs at injection time?
I mean something like this tutorial I found
thank you
from hookshot.
If I understand correctly, the idea is to:
- Inject a DLL (by specifying it on an
Inject =
line in a Hookshot configuration file). - After the DLL is injected, call a function in the DLL and pass arguments to that function.
Is this right?
from hookshot.
If I understand correctly, the idea is to:
- Inject a DLL (by specifying it on an
Inject =
line in a Hookshot configuration file).- After the DLL is injected, call a function in the DLL and pass arguments to that function.
Is this right?
Yes, This is exactly what I have in mind
and also I think its good Idea to create some kind of library with HookShot to be able to use it inside of program
for now HookShot working very well, but its not good in term of easy use, because for that you need to include compiled binary to project... and its not ideal
you think its possible?
from hookshot.
Yes, This is exactly what I have in mind
Based on this use case, I suggest creating a hook module rather than relying on Inject =
to load your DLL. The Inject =
functionality is intended as a quick and convenient way for a user to inject a DLL that does not need much in the way of interaction.
Suppose you are trying to inject FancyLibrary.dll
into a program called App.exe
. Rather than using Inject = FancyLibrary.dll
to do it, you can write a hook module called (for example) FancyLibraryWrapper
. In the hook module's entry point, you could:
- Call the Windows API function
LoadLibrary
and passFancyLibrary.dll
as an argument. - Use
GetProcAddress
(or some other means) to locate the address of the function inFancyLibrary.dll
that you want to call. - Invoke the function with whatever arguments you want.
- Set up some IPC channels, spawn new threads, and do basically anything you want to make it possible to call functions in
FancyLibrary.dll
inApp.exe
from some other program, perhaps another program you wrote.
While hook modules are intended to set hooks using the Hookshot API, this is not strictly a requirement. The hook module entry point gives you an opportunity to run whatever code you want inside the space of App.exe
.
for that you need to include compiled binary to project... and its not ideal
Could you please explain this issue a little bit more? What "compiled binary" are you referring to, and why is including it not ideal?
from hookshot.
Related Issues (2)
- ThirdParty build fail HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hookshot.