Hey there!
This is my first attempt at creating a guide, I think :p, so please bare with me. As you will probably be able to tell i'm just beginning my adventure into the assembly world, so please let me know if there are more efficient ways to go about doing this. Thanks to Angelius i'm digging into hooks/patching and in-line asm. If anyone wants to lend me a hand on overwriting an asm line using C++ that would be great! Finally, all criticism is welcome but, please, keep it constructive and professional. Lets begin!
First off, I did all of my testing with a 5065 client, i'd imagine it would be a similar process with newer/older patches. I don't have a newer client and don't plan to download it tonight.
Problem:
The client typically does not allow you to directly connect to a local IP address, be it 127.x.x.x, any loop-back, or hamachi. When developing a private server or bot this is very problematic. Sure, you could use Nullables loader but that's a hassle if you want to develop your own loader or memory based bot.
What this does:This allows you to connect to any IP address without getting the annoying "Failed to load Server.dat" message.
Step 1:
Open up Conquer.exe using ollydbg or simple attach olly to an already opened client.
Step 2:
Make sure you are viewing the Conquer module in the cpu window. To do this hit Alt+E and find conquer.exe in the list that pops up. It's usually located towards the top of the list.
Digging through the client I discovered that they compare the first part of the ip (eg. 127 in 127.0.0.1) to 0x7F, or 127, using the CMP op-code.
Step 3:
Right-Click in the CPU window. Select "Search For -> All Commands..." In the window that appears type CMP AL, 7F. Another window should now appear with all the locations that command was found. In my case it is 2 places.
Step 4:
Double click on the first occurrence in the window that appeared, it should take you to op-code, highlighting it, in the CPU window. Just below this op-code you will have a jump command (JNE or JE in my case).
Step 5:In the CPU window, Right-Click -> Search for -> All intermodular calls. Along the top click "Dest Name" to sort it using that data. Next, Type connect
.I will finish this guide tomorrow, if people would like itm if I have the chance. Ran out of time today, sorry. I know, the formatting is terrible, its making my OCD yell at me haha.
This is my first attempt at creating a guide, I think :p, so please bare with me. As you will probably be able to tell i'm just beginning my adventure into the assembly world, so please let me know if there are more efficient ways to go about doing this. Thanks to Angelius i'm digging into hooks/patching and in-line asm. If anyone wants to lend me a hand on overwriting an asm line using C++ that would be great! Finally, all criticism is welcome but, please, keep it constructive and professional. Lets begin!
First off, I did all of my testing with a 5065 client, i'd imagine it would be a similar process with newer/older patches. I don't have a newer client and don't plan to download it tonight.
Problem:
The client typically does not allow you to directly connect to a local IP address, be it 127.x.x.x, any loop-back, or hamachi. When developing a private server or bot this is very problematic. Sure, you could use Nullables loader but that's a hassle if you want to develop your own loader or memory based bot.
What this does:This allows you to connect to any IP address without getting the annoying "Failed to load Server.dat" message.
Step 1:
Open up Conquer.exe using ollydbg or simple attach olly to an already opened client.
Step 2:
Make sure you are viewing the Conquer module in the cpu window. To do this hit Alt+E and find conquer.exe in the list that pops up. It's usually located towards the top of the list.
Digging through the client I discovered that they compare the first part of the ip (eg. 127 in 127.0.0.1) to 0x7F, or 127, using the CMP op-code.
Step 3:
Right-Click in the CPU window. Select "Search For -> All Commands..." In the window that appears type CMP AL, 7F. Another window should now appear with all the locations that command was found. In my case it is 2 places.
Step 4:
Double click on the first occurrence in the window that appeared, it should take you to op-code, highlighting it, in the CPU window. Just below this op-code you will have a jump command (JNE or JE in my case).
Case 1: JNE SHORT XXXXXXJNE stands for, I believe "jump if not equal." If you set a breakpoint and debug this function you would see that it takes the jump if the first part of your IP does not equal 127.
Step 4.1a:Double-Click JNE SHORT XXXXXX.
Step 4.1b:In the window that appears change JNE to JMP so it will always take the jump, not matter what the IP.
Case 2: JE SHORT XXXXXXAlright, if you just wanted to be able to use 127.x.x.x to log-in to your server or w/e this is where you could stop.JE stands for, I believe "jump if equal." Again, debug it to see if the jump is taken, if you want.
Step 4.2a:Double-Click JE SHORT XXXXXX
Step 4.2b:In the window that appears, change JE SHORT XXXXXX to NOP so no jump is taken and the code continues along like nothing happened.
Step 5:In the CPU window, Right-Click -> Search for -> All intermodular calls. Along the top click "Dest Name" to sort it using that data. Next, Type connect
.I will finish this guide tomorrow, if people would like itm if I have the chance. Ran out of time today, sorry. I know, the formatting is terrible, its making my OCD yell at me haha.