winapi - c++ PE injecting additional functionality -
for example have simple c++ main function
int main () { (int = 0; < 10; i++) sleep(10); return 0; }
so exe shuts down after 10 seconds start. question: there way join(concatenate) 2 pe-applications? trying program c++ unite 2 apps new one. example: ill run program parameter app:
my_app.exe %windir% / calc.exe
exe wrapper general description exe wrapper command line utility can compile , output “launcher” exe works input exe few additional features. wrapper must command line based on takes 3 input variables: 1. windows executable file 2. expiry datetime 3. url server instructions , “download exe” example command: wrapper.exe “input_exe.exe” “20150528 15:00:00” “http://pemainin. com/launch_askar.php?pid=2&tid=123&n=test” output wrapper new exe file appear similar possible input exe. if expiry time not set @ all, output exe should act if exe expired start. output exe should act follows
what trying build called "binder". can achieve effect want having wrapper "join" 2 pe files, stub
, decoy
. stub
implement main features outlined (downloading link, timeouts e.t.c) , responsible drop , execute decoy
pe file gets embedded wrapper. wrapper can embed decoy
pe file in resource section or append @ end of stub
file, , add configuration file telling stub
location , size of decoy file, url, timeout, e.t.c resource section. when stub
run, has locate , read configuration , drop , execute decoy
pe file new process. make "binded" executable decoy
pe file, wrapper can apply icon , version resource of decoy
pe file onto stub
.
here implementation of binder source code.
Comments
Post a Comment