Connect to a proxy without editing server.dat

12/05/2008 23:29 unknownone#1
Pretty straight forward.
Extract to co directory and run apply_patch.bat

It's a winsock edit that forces connection to 127.0.0.1, so you'll need to "unapply" the patch to connect normally. Ie, by renaming ws2_32.dll to something else. I've stuck 2 launchers in there for normal/patched version, they're just plain batches. CBA writing a proper launcher.

The ws2mod is only needed if you have a problem making your own. Post a few down explains why.
12/06/2008 00:30 majick#2
if you use a proxy bot and you don't thank him for this slap yourself repeately
12/06/2008 00:45 KitsunePaws#3
Quote:
Originally Posted by unknownone View Post
Pretty straight forward.
Extract to co directory and run apply_patch.bat

It's a winsock edit that forces connection to 127.0.0.1, so you'll need to "unapply" the patch to connect normally. Ie, by renaming ws2_32.dll to something else. I've stuck 2 launchers in there for normal/patched version, they're just plain batches. CBA writing a proper launcher.
haha, you beat me to it, however, you might want to take a look at this


C:\Program Files\Conquer 2.0>xdelta3.0u.x86-32.exe -d -s c:/windows/system32/ws2
_32.dll ws2_mod_force_local.xdelta ws2mod.dll
xdelta3: source file too short: XD3_INTERNAL

C:\Program Files\Conquer 2.0>xdelta3.0u.x86-32.exe -d -s conquer.exe server_erro
r_bypass_5078.xdelta patched_conquer.exe
xdelta3: target window checksum mismatch: XD3_INVALID_INPUT

I was attemping a hosts file edit, but it failed as there was no host name to resolve, just an IP address.


Edit: Standby, I either have a bad file in my XP sp3 or something, however you CANT apply this patch over a hacked co.exe it would seem. Reapply your patch (edit version.dat to 75ish and let it auto update) then try again.
12/06/2008 01:12 unknownone#4
Seems some are having a problem with that. You need to have the same ws2_32.dll as I do (running WinXP SP2). I'll upload the patched dll instead of the delta.
12/06/2008 01:43 KitsunePaws#5
Quote:
Originally Posted by unknownone View Post
Seems some are having a problem with that. You need to have the same ws2_32.dll as I do (running WinXP SP2). I'll upload the patched dll instead of the delta.
Clean, and works like a charm. If you use a proxy of any kind, I suggest you give thanks to one of our longest standing members who has always helped, even when he no longer plays himself, good going unknown <3
12/06/2008 02:08 unknownone#6
This really isn't the best solution to the problem. (infact it's terrible). I'm just lazy and come up with the simple hacks :p. If anyone is interested in knowing what's going on here, I'm modifying the inet_addr() function to always return localhost.

Code:
71AB2C47     8B45 E4        MOV EAX,DWORD PTR SS:[EBP-1C]
71AB2C4A     E8 D1E5FFFF    CALL WS2_32.71AB1220
71AB2C4F     C2 0400        RETN 4
71AB2C52     90             NOP
71AB2C53     90             NOP
71AB2C54     90             NOP
71AB2C55     90             NOP
71AB2C56     90             NOP
71AB2C57     90             NOP
Code:
71AB2C47     B8 7F000001    MOV EAX,[color=red]100007F[/color]
71AB2C4C     E8 CFE5FFFF    CALL ws2_32.71AB1220
71AB2C51     C2 0400        RETN 4
71AB2C54     90             NOP
71AB2C55     90             NOP
71AB2C56     90             NOP
71AB2C57     90             NOP
You'd modify the value in red for your own IP etc.

For anyone interested in a better solution, you should make a simple DLL using the microsoft detours API. That way you wouldn't need to force a certain IP, and could manage things easily without the patching binaries. Something like this should work.
PHP Code:
#include <windows.h>
#include <winsock2.h>
#include <detours.h>

DETOUR_TRAMPOLINE(int WINAPI original_connect(SOCKET a0struct sockaddra1int a2), connect)

int WINAPI custom_connect(SOCKET sstruct sockaddrnameint namelen)
{
    
struct sockaddr_innewname = (struct sockaddr_in*)name;
    
newname->sin_addr.s_addr inet_addr("127.0.0.1");
    return 
original_send(snamenamelen);
}

BOOL WINAPI DllMain(HINSTANCE hinstDWORD reasonLPVOID reserved

    if ( 
reason == DLL_PROCESS_ATTACH 
    { 
        
DetourFunctionWithTrampoline((PBYTE)original_connect,(PBYTE)custom_connect);     
    } 
    else if ( 
reason == DLL_PROCESS_DETACH 
    { 
        
DetourRemove((PBYTE)original_connect,(PBYTE)custom_connect); 
    }     
    return 
true

12/06/2008 02:09 Acidburncx#7
can any1 help i seem cannot connect to cid proxy it say server damage what am i doing wrong?
12/06/2008 02:31 unknownone#8
You didn't do anything wrong, your parents did - by bringing you into the world.
12/06/2008 02:41 Acidburncx#9
f u dont wanna help u dont have to be rude just say so
12/06/2008 02:55 unknownone#10
Go troll in the cidproxy thread.

The server_error_bypass_5078.xdelta fixes what you want. apply_patch.bat should've fixed that.
Try again, and if it doesn't work, give some constructive feedback, such as why it didn't work.
12/06/2008 04:20 Frankie81#11
Ok I put everything where it needs to go but it doesnt say my char name on the side. Im using cid proxy. When i start up cid proxy then sign in my char it says welcome to proxy but no char name. If you could help me out bro. Thanks so much.
12/06/2008 05:51 majick#12
Quote:
Originally Posted by unknownone View Post
You didn't do anything wrong, your parents did - by bringing you into the world.
rofl that's epic!!!
12/06/2008 06:34 zaki...max#13
server damage
12/07/2008 23:07 MrGenious#14
Quote:
Originally Posted by unknownone View Post
Go troll in the cidproxy thread.

The server_error_bypass_5078.xdelta fixes what you want. apply_patch.bat should've fixed that.
Try again, and if it doesn't work, give some constructive feedback, such as why it didn't work.
Ok it doesn't work and here you got some constructive feedback ( don't see why no one else gives it -.-)

So basicly I copied all the content inside connect_local_patch to my co directory and I run the apply_patch. I get this following error :

xdelta3: target window checksum mismatch XD3_INVALID_INPUT

I hope that helps you, I am going to put ur ws2_32.dll file in my windows/system32 file and see if that works, I gotta go do it in safe mode or something (I will figure something out).

Uhm also I am using Windows XP SP 3.
12/07/2008 23:39 unknownone#15
Woah woah, don't do that. The ws2_32 I uploaded is the modded one, you should only stick it in the CO dir so it doesn't affect any other app.

The reason for that xdelta mismatch is you either have a different ws2_32.dll or you've already applied binary edits the conquer.exe. xdelta3 will only work if they're the same as the binaries I made the diffs with.

Just try putting the modded ws2_32.dll in the co dir, and apply the server.dat bypass manually.