C ++ how to run a .exe file whose contents are stored in a char array?

I am making a specific program and I was just wondering if I can do this: run the file whose contents are stored in the char array in the WINDOWS window.

this is the code that reads the executable file and stores it in a char array:

filetoopen.open (C:\blahlbah.exe, ios::binary); filetoopen.seekg (0, ios::end); length = filetoopen.tellg(); filetoopen.seekg (0, ios::beg); buffer = new char [length]; filetoopen.read (buffer, length); filetoopen.close(); 

I heard something about RunPE, and I did some searching, I was unable to find any piece of C ++ code.

+4
source share
1 answer

Source: https://habr.com/ru/post/1389214/


All Articles