Creating network proxy

Posts 1619 of 19 · Page 2 of 2
So you want to capture incoming packets and then send them to a proxy server and then from the proxy server to the game server...

You will also need to figure out the handshake packets to when the proxy server connects to the game server , like some kind of authenication to say its a legit game client, does that make sense?
Quote Originally Posted by Anddos View Post
So you want to capture incoming packets and then send them to a proxy server and then from the proxy server to the game server...
Yeah, this is exactly what I'm trying to do.

Quote Originally Posted by Anddos View Post
You will also need to figure out the handshake packets to when the proxy server connects to the game server, like some kind of authenication to say its a legit game client, does that make sense?
That is already done, I know what data needs to be sent. The hard part is telling client socket to stop sending data to server and instead send it to proxy. So, basicly, the main question is how would I tell x to stop communicating with y and talk to z instead?
iOh i see now, that does seem kind of impossible without hooking the winsock functions, are you able to inject a dll and not get banned?, if so
in the send or sendto hook , you make the connection to the proxy server and send the hooked recv/recvfrom buffer to the proxy and make the hooked recv/recvfrom return 0;

here is a quick illistration

int WINAPI MySend(SOCKET s, const char*buf, int size, int flags)
{
//connect to the proxy
//send buf to the proxy

//return 0; , just return 0 back to send so it doesnt send the original
}
Ah, that's a pity. I've had very little experience with internal, but I guess learning something new is never a problem. Seems logical, that'll be my plan B I guess.

I wonder, is there any function to get all open socket descriptors? That way I would be able to play around with sockets without having to mess with game process. Also, don't firewalls do something similar? Like inspecting traffic and blocking connection if something's not right. Is it worth it too look for firewall source codes if there are any for what I'm trying to achieve?
Posts 1619 of 19 · Page 2 of 2

Post a Reply

Similar Threads

Tags for this Thread

None

Need help?