How to run a process from memory

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • securedsolution
    New Member
    • Mar 2013
    • 3

    How to run a process from memory

    I am looking for a way to run a process form memory, without having any executable. The application will be kept inside a resource and will be extracted during run time. It should be then started as a new process. I couldn't find a solution that works also on x64
  • weaknessforcats
    Recognized Expert Expert
    • Mar 2007
    • 9214

    #2
    Are you using Windows?

    If so, read Windows via C/C++ by Jeffrey Richter. There's a whole chapter on creating and managing processes.

    Comment

    • securedsolution
      New Member
      • Mar 2013
      • 3

      #3
      I am using Windows, and Visual c++ 2010.
      I don't understand your response. If there was a simple answer I wouldn't have published this question. It is very difficult to run a process from memory.

      Comment

      • weaknessforcats
        Recognized Expert Expert
        • Mar 2007
        • 9214

        #4
        Not true. Research CreateProcess.

        Comment

        • securedsolution
          New Member
          • Mar 2013
          • 3

          #5
          I did. However, if you could submit a code sample, that would be great. Just store a "hello world" executable as a "BINARY" resource and have the application extract the resource into memory, and launch a new process with the "hello world" application, without creating any physical file

          Comment

          • weaknessforcats
            Recognized Expert Expert
            • Mar 2007
            • 9214

            #6
            Sounds like a great problem. Just Google "CreateProc ess" and copy their example.

            Comment

            Working...