(Mar 15, 2025 02:35 PM)bytespm Wrote: Im currently trying to develop a client program that opens shell and continuously sends commands that comes from server and sends output to the server. its basically a reverse shell but theres gonna be more than 1 computer so i need a client-server architecture. My client program needs to start everytime a computer starts (win10) and waits server input everysecond (if i put input in a while true will it work?). Does anyone know how to do it ? Im open to every kind of tip, thanks!
It depends on what language you're using there's many functions that does this... like sleep(), delay(), wait().
If you don't want to use those you can use while and just have a counter in miliseconds.
However, in a client-server relationship. You wouldn't need to pause. You need to bind your application to an ip address and listen on a specific port.
both software needs to do this. You need to build the system to interrupt the current state and jump to running the commands from the server.
if it's a reverse shell your shell program would have to dial out to a server which means it needs to have either an ip address or a domain name.
and port. The server will have to bind on that specific port and listen for commands.
for the client software to start when the target computer boots. you either need to put it in the startup older for windows 10 or make modifications to registry. It's hard to have this work on systems that computer experts run because they can defeat this process.
hope this helps any.
I would create a function and use a while loop that way you can customize how you want it to work.
and you can add in interrupts to it so that while waiting if you get a response from the other side it will stop the waiting function.
process the commands and then go back and restart the waiting function.