Nmap Development mailing list archives
Re: --lua-exec stream redirection on Windows
From: Jacek Wielemborek <wielemborekj1 () gmail com>
Date: Mon, 24 Jun 2013 09:18:15 +0200
Another possibility is to actually create a new process--calling ncat.exe in a special way so as to make it a Lua interpreter. This would allow us to use CreateProcess and all the debugged and tested infrastructure we have for --exec and --sh-exec. What I mean is that you as a user would call ncat -l -k 5000 --lua-exec test.lua and the code in ncat_exec_win.c would do CreateProcess("ncat --lua-exec-internal test.lua", ...); The --lua-exec-internal option will cause Ncat to immediately become just a Lua interpreter. It would be basically the same as "lua test.lua". This is something like how scp has the undocumented -t option that makes it a file receiver: https://en.wikipedia.org/wiki/Secure_copy#How_it_works.
As for today, this is the approach implemented. I'm not really happy with this implementation (it just doesn't feel right), so if somebody more familiar with Windows could speak up, I'd be grateful. _______________________________________________ Sent through the dev mailing list http://nmap.org/mailman/listinfo/dev Archived at http://seclists.org/nmap-dev/
Current thread:
- --lua-exec stream redirection on Windows David Fifield (Jun 22)
- Re: --lua-exec stream redirection on Windows Jacek Wielemborek (Jun 22)
- Re: --lua-exec stream redirection on Windows Jacek Wielemborek (Jun 24)
- Re: --lua-exec stream redirection on Windows Patrick Donnelly (Jun 24)
- Re: --lua-exec stream redirection on Windows Jacek Wielemborek (Jun 24)