Aux*_*ary 14 merge exe code-injection
有没有办法以编程方式将两个exe文件合并为一个,以便运行它将同时执行两个较旧的exe文件.我在google上发现了一些关于注入代码或dll文件的东西但是有可能两个合并两个exe文件或者将exe注入exe吗?
提前致谢.
[编辑] 谢谢大家.只是对于那些说不可能的人,我不得不说我最近按照一些建议的方式做了.它几乎就是这样(我不记得所有这一切,因为很久以前):
[当心:此算法与某些蠕虫和病毒的算法非常相似.我不是黑客或病毒作家!并且这仅用于实验或无害的原因 - 在代码中出错会破坏目录中的可执行文件.
1- Exe检查自身的大小以检测是否有任何附加到自身的内容.如果还没有:
1.1- The exe finds other executable files in its directory (lets call one of them as victim!)
1.2- it makes a copy of itself (lets call it newMe)
1.3- it copies the other executable found in the directory to the end of newMe.
1.4- it deletes the other executable file found and renames newMe to its victim's name.
Run Code Online (Sandbox Code Playgroud)
2-如果exe检测到已添加某些内容,则:
2.1- Then it copies data from itself (from ORIGINAL_FILE_SIZE to the end of file) to a new file (lets call it newBorn.exe)
2.2- It runs itself's code and then executes the newBorn.
Run Code Online (Sandbox Code Playgroud)
我说我几乎用这种方式做了它,因为exe会为自己添加另一个exe.但是这可以重复用于将2个甚至3个或更多个可执行文件追加并执行到一个中.你只需要知道编写程序的ORIGINAL_FILE_SIZE.
不,你最好的办法是创建一个运行两个可执行文件的.bat文件(Windows).
@echo off
c:\path\to\first\exe\file1.exe
c:\path\to\second\exe\file2.exe
Run Code Online (Sandbox Code Playgroud)
您也可以在Linux中创建一个shell脚本来执行相同的操作
#!/bin/sh
/path/to/first/exe/file1
/path/to/second/exe/file2
Run Code Online (Sandbox Code Playgroud)
注意,这将在file2之前执行file1.
理论上这是可能的,但需要你的一些努力.
您可以将数据附加到exe文件,这就是自解压存档的工作方式.但是,您需要自己的数据格式,类似于文件系统,因为您只有一个平面.exe文件.
请参阅此Microsoft文章(谷歌上有很多内容)http://support.microsoft.com/?scid=kb%3Ben-us%3B84062&x=12&y=13
你打包两个文件的exe必须提取这些文件,最后运行它们.
祝好运.
| 归档时间: |
|
| 查看次数: |
37565 次 |
| 最近记录: |