![]() |
|
[C#] How programms copy themselves into executable file - Printable Version +- Hack Forums (https://hackforums.net) +-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444) +--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151) +---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118) +---- Thread: [C#] How programms copy themselves into executable file (/showthread.php?tid=6189000) Pages: Pages
1
2
|
How programms copy themselves into executable file - indetectable - Jan 13, 2022 Hi, I wonder how can a program can copy himself (or just a small part of his code) into a new executable file, and how can I do it with using c#. I know its possible RE: How programms copy themselves into executable file - Romeos - Jan 13, 2022 "copy himself into a new executable file". I am not quite sure I understand your question tbh. RE: How programms copy themselves into executable file - 0x9F - Jan 14, 2022 https://docs.microsoft.com/en-us/windows/win32/debug/pe-format RE: How programms copy themselves into executable file - indetectable - Jan 14, 2022 (Jan 13, 2022 05:30 PM)Romeos Wrote: "copy himself into a new executable file". I am not quite sure I understand your question tbh. Okay so I will take an example (not that I want to do but this is the best example I have). I want to know how can a program (made in c#) can create an executable with some code inside, for example when we use a GUI rat, we have the builder and it can create the executable that we want to spread, so how the builder (wich is inside the program) can create a second .exe file with the code that we want inside ? RE: How programms copy themselves into executable file - truco - Jan 14, 2022 it depends, if you simply want to create a builder you can use codedom or you can also have a stub (inside resources or w/e) and edit the necessary parts using mono.cecil or dnlib RE: How programms copy themselves into executable file - Joseph Ducreux - Jan 24, 2022 by binding data to the EOF of an executable and than patching the file image header or something to point to new breakpoint or simply by using cmd copy /b a.exe + b.exe = c.exe if you use extension polygots its possable to differentiate 2 seperate exe's from 1 result if done right RE: How programms copy themselves into executable file - indetectable - Jan 24, 2022 (Jan 24, 2022 04:13 AM)Joseph Ducreux Wrote: by binding data to the EOF of an executable and than patching the file image header or something to point to new breakpoint I dont understand this or simply by using cmd copy /b a.exe + b.exe = c.exe (Jan 24, 2022 04:13 AM)Joseph Ducreux Wrote: if you use extension polygots its possable to differentiate 2 seperate exe's from 1 result if done right This isn't exaclty what I want, to infect a computer the only way I know to do it it's to download another file from web (wich is I think more spoted than just creation another .exe file from nothing (just by clicking on the main program)) RE: How programms copy themselves into executable file - Endorphins - Jan 25, 2022 (Jan 24, 2022 11:27 AM)indetectable Wrote: I dont understand this It is not ethical to infect another machine that you don't own or you don't have permission to access. Regarding this quote, he is referring to append the additional information (configuration/settings/instructions in this context) to your stub (the executable you just created with the builder). Whenever the stub will get executed/launched, it will read the appended information. RE: How programms copy themselves into executable file - xHeaven - Jan 25, 2022 (Jan 25, 2022 04:04 AM)Endorphins Wrote: It is not ethical to infect another machine that you don't own or you don't have permission to access. Nobody cares. RE: How programms copy themselves into executable file - 0x9F - Jan 25, 2022 (Jan 25, 2022 07:30 AM)xHeaven Wrote: Nobody cares. law enforcements do 🙃 RE: How programms copy themselves into executable file - xHeaven - Jan 25, 2022 (Jan 25, 2022 08:06 AM)riscenjoyerx86 Wrote: law enforcements do 🙃 Catch me if you can, then, bad boy. This is still Hackforums, thinking and expecting that users will only infect PCs in their ownership is blatantly retarded and insanely naive. RE: How programms copy themselves into executable file - Vuln - Jan 25, 2022 If you're going to use C# then just access the compiler through CodeDOM, which is very noob-friendly. RE: How programms copy themselves into executable file - mose3c - Jan 26, 2022 yeb you can do it by reading self bytes and then use WriteAllBytes to write self to new directory RE: How programms copy themselves into executable file - JoseCmanXDII - Feb 4, 2022 (Jan 25, 2022 08:43 AM)xHeaven Wrote: Catch me if you can, then, bad boy. i will catch you. what a clown RE: How programms copy themselves into executable file - indetectable - Feb 13, 2022 (Jan 14, 2022 11:15 AM)Incog Wrote: CodeDOMFor me theses are too complex, sorry.. Code //here you would use replace on the string, and have anything inside the stub code written out like #thing# to prevent unwanted replacementsI dont understand this part, what should I do with #thing# and hello ?? Thanks |