flat assembler
Message board for the users of flat assembler.
Index
> Windows > .. |
Author |
|
pool 18 Aug 2012, 19:55
..
Last edited by pool on 17 Mar 2013, 12:09; edited 1 time in total |
|||
18 Aug 2012, 19:55 |
|
Enko 18 Aug 2012, 20:01
What about WinExec?
http://msdn.microsoft.com/en-us/library/windows/desktop/ms687393(v=vs.85).aspx |
|||
18 Aug 2012, 20:01 |
|
pool 18 Aug 2012, 20:07
..
Last edited by pool on 17 Mar 2013, 12:09; edited 1 time in total |
|||
18 Aug 2012, 20:07 |
|
pool 18 Aug 2012, 20:40
..
Last edited by pool on 17 Mar 2013, 12:09; edited 1 time in total |
|||
18 Aug 2012, 20:40 |
|
Enko 18 Aug 2012, 21:02
Works fine for me on xp 32bit.
Code: section ".data" data readable writeable prog db 'mspaint.exe',0 param db '',0 section ".code" code readable writeable executable start: invoke WinExec, prog, param invoke ExitProcess, 0 or you can use the c runtime. http://msdn.microsoft.com/en-us/library/431x4c1w(v=vs.80).aspx you will need to import the function from mvcrt.dll and use cinvoke insted of invoke. Code: import msvcrt,\ _wexecl,'_wexecl',\ _wexecle,'_wexecle',\ _wexeclp,'_wexeclp',\ _wexeclpe,'_wexeclpe',\ _wexecv,'_wexecv',\ _wexecve,'_wexecve',\ _wexecvp,'_wexecvp',\ _wexecvpe,'_wexecvpe',\ |
|||
18 Aug 2012, 21:02 |
|
pool 18 Aug 2012, 21:33
..
Last edited by pool on 17 Mar 2013, 12:09; edited 1 time in total |
|||
18 Aug 2012, 21:33 |
|
pool 18 Aug 2012, 23:25
..
Last edited by pool on 17 Mar 2013, 12:09; edited 1 time in total |
|||
18 Aug 2012, 23:25 |
|
Goplat 19 Aug 2012, 19:06
Windows never kills a process just because the process that created it exited, regardless of the API used for creation. However, if the "parent" and "child" processes share a console window, then certain actions the user might take to kill the parent (pressing Ctrl-C/Ctrl-Break or closing the console window) would also affect the child.
If the child is not supposed to use the console, then it should be linked as a GUI application instead of a console application (in fasm: "format PE GUI"). If the child is supposed to use the console but you want to create it in its own console window, have the parent use the CREATE_NEW_CONSOLE flag with CreateProcess. Enko wrote:
|
|||
19 Aug 2012, 19:06 |
|
pool 19 Aug 2012, 23:40
..
Last edited by pool on 17 Mar 2013, 12:09; edited 1 time in total |
|||
19 Aug 2012, 23:40 |
|
typedef 20 Aug 2012, 22:40
Additionally you can try
Code:
ShellExecuteA /ShellExecuteW
|
|||
20 Aug 2012, 22:40 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.