Advertisement

**Intercepting an applications winsock calls**

Started by July 11, 2002 04:22 PM
3 comments, last by wrathgame 22 years, 6 months ago
Hi all, This is a hard one.. I have seen a app which does this ( SocksCap .. http://www.socks.nec.com/reference/sockscap.html if your interested) Basically it runs a program and intercepts all of the TCP/UDP send/recieves and re directs them in this case to a SOCKS server (this then allows net games to be played from a PC withing a LAN connected to the net, but the game doesnt support socks) What i really really want to know is how does such a program intercept the winsock calls ! Please help anyone who can help or point me in the right direction Thanks a lot ~ tim ~ wrathgame
~ Tim
would be probaly easier to create a WinSock pass-thru DLL, you replace the winsock dll with your own which passes the dll calls onto the real dll, such techniques could be used to create a simple firewall.
Advertisement
that may not be practical, I would have to make a pass through call for Every function in winsock dll.

It would also be a global version and not specific to a single program :-/

One of the reasons I want to do this (among others) is to make a game think computers on 2 seperate LANs connected over the internet were on the same LAN.. is there any easy way to do that ? cuz that would solve one problem at least

Thanks for the reply

~ tim
~ Tim
Try googling for api hooks.
---visit #directxdev on afternet <- not just for directx, despite the name
Create a VPN (Virtual Private Network) between the two computers. This is what me and my friend did to play Tony Hawk 2 over the net, which only supported LAN play. It''s pretty easy to set up.

This topic is closed to new replies.

Advertisement