|
You last visited: Today at 15:51
Advertisement
Conquer Resource Wiki
Discussion on Conquer Resource Wiki within the CO2 Private Server forum part of the Conquer Online 2 category.
01/13/2010, 02:41
|
#46
|
elite*gold: 0
Join Date: Oct 2009
Posts: 8,783
Received Thanks: 5,304
|
Quote:
Originally Posted by Korvacs
Thats missing the most important peice of the packet, the string type, which defines the string that you put in the packet as a spousename, list of flowers, guild related etc.
As it stands, that structure is this one:
The only thing which is different is the string itself, and the type which is missing.
|
Oh well I just thought it'd help.
|
|
|
01/14/2010, 02:13
|
#47
|
elite*gold: 0
Join Date: Feb 2009
Posts: 12
Received Thanks: 0
|
sweet wiki but now all i need is a packet editor that matches the server send and request packets so i can tap right in there... any help? i just started learning about this stuff but as time goes by it get it.
plz point me to a good editor and how to use it. thank you.
|
|
|
01/15/2010, 10:15
|
#48
|
elite*gold: 20
Join Date: Jan 2008
Posts: 2,338
Received Thanks: 490
|
i would need some tutorials about adding new packets and its function =/
|
|
|
01/29/2010, 16:11
|
#49
|
elite*gold: 0
Join Date: Jan 2010
Posts: 116
Received Thanks: 33
|
good job korvacs!
|
|
|
02/05/2010, 09:31
|
#50
|
elite*gold: 0
Join Date: Sep 2009
Posts: 321
Received Thanks: 60
|
if elite pvpers opened a wiki for stuff like this im sure it would be a lot lot more popular.
|
|
|
02/19/2010, 23:56
|
#51
|
elite*gold: 0
Join Date: Jul 2006
Posts: 2,216
Received Thanks: 794
|
A suggestion if you don`t mind :P The encryption part only talks about 5018 and above, could we have the other public encryptions as well? Like 5065, 5017, 4351?
And another question, when a packet has only one version, like the at EntitySpawn packet the MobSpawn part, does that mean that it`s the same in older versions as well?(Obviously I`m not talking about things like mentor stuff)
|
|
|
02/20/2010, 00:20
|
#52
|
elite*gold: 20
Join Date: Mar 2006
Posts: 6,126
Received Thanks: 2,518
|
If we take this page as the example:
I have added the 5100 versions of the packet in both character and monster forms, however the 4267 version doesnt include the monster spawn form because i havent mapped those areas of the packet.
The idea is that at some point i will add the other client versions aswell, so there would also be a 5017 packet in there , however if there isnt a change between 4267 and 5100 then i wont add anouther packet in, so if your client version is between 2 existing packets then try the lower one first.
On the subject of the encryption, i do intend on adding the original encryption at some point, however its extremely common (its in every released source), so the demand for it is virtually none existant.
The 5018 and above encryption works for 5018+, so 5065 is covered, as is 5100, 5165 etc etc.
|
|
|
02/28/2010, 19:44
|
#53
|
elite*gold: 0
Join Date: Aug 2007
Posts: 180
Received Thanks: 158
|
Nullable > if would be nice if when u r done with non C# version to mail it to Korvacs with the tune-ups if you make any, cuz I believe I wouldn't be only one who might use it.
Korvacs > good luck at it. *fan*
rest> other idea was like post the pckts in the forum, if its only one, but that might spamm it out. mail/PMs is better.
about wiki edit, I guess this way if just one or bunch of both ways trusted admins do edits it will not going to get wild.
I guess bunch of peps which knows are more busy nowadays as me. And then u see those around 17y peps getting to places where we was while below age of 20
|
|
|
03/01/2010, 16:03
|
#54
|
elite*gold: 0
Join Date: Nov 2009
Posts: 390
Received Thanks: 321
|
Quote:
Originally Posted by galdik
Nullable > if would be nice if when u r done with non C# version to mail it to Korvacs with the tune-ups if you make any, cuz I believe I wouldn't be only one who might use it.
|
I only made a 5017 one, didn't want all those high versions, anyhow I'm not quite sure it works because I didn't have the chance to test it(abandoned project) so I will just paste it here:
Header File(coenc.h):
PHP Code:
#ifndef _COENC_H
#define _COENC_H
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
#include <iostream>
#include <stdio.h>
#include <stdlib.h>
#include <windows.h>
#define KEY_SIZE 256
typedef unsigned char byte;
namespace ConquerEncryptionClasses
{
static const byte Key1[] =
{
0x9D, 0x90, 0x83, 0x8A, 0xD1, 0x8C, 0xE7, 0xF6, 0x25, 0x28, 0xEB, 0x82, 0x99, 0x64, 0x8F, 0x2E,
0x2D, 0x40, 0xD3, 0xFA, 0xE1, 0xBC, 0xB7, 0xE6, 0xB5, 0xD8, 0x3B, 0xF2, 0xA9, 0x94, 0x5F, 0x1E,
0xBD, 0xF0, 0x23, 0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0xFC, 0xC9,
0x52, 0xBF, 0x58, 0x05, 0xCE, 0x5B, 0x74, 0x81, 0x0A, 0x37, 0x50, 0x3D, 0x06, 0x53, 0xEC, 0x39,
0xC2, 0xAF, 0x48, 0x75, 0x3E, 0x4B, 0x64, 0xF1, 0x7A, 0x27, 0x40, 0xAD, 0x76, 0x43, 0xDC, 0xA9,
0x32, 0x9F, 0x38, 0xE5, 0xAE, 0x3B, 0x54, 0x61, 0xEA, 0x17, 0x30, 0x1D, 0xE6, 0x33, 0xCC, 0x19,
0xA2, 0x8F, 0x28, 0x55, 0x1E, 0x2B, 0x44, 0xD1, 0x5A, 0x07, 0x20, 0x8D, 0x56, 0x23, 0xBC, 0x89,
0x12, 0x7F, 0x18, 0xC5, 0x8E, 0x1B, 0x34, 0x41, 0xCA, 0xF7, 0x10, 0xFD, 0xC6, 0x13, 0xAC, 0xF9,
0x82, 0x6F, 0x08, 0x35, 0xFE, 0x0B, 0x24, 0xB1, 0x3A, 0xE7, 0x00, 0x6D, 0x36, 0x03, 0x9C, 0x69,
0xF2, 0x5F, 0xF8, 0xA5, 0x6E, 0xFB, 0x14, 0x21, 0xAA, 0xD7, 0xF0, 0xDD, 0xA6, 0xF3, 0x8C, 0xD9
};
class ConquerEncryption
{
private:
byte * Key3, * Key4;
USHORT InPackets, OutPackets;
bool AlternateDec;
public:
ConquerEncryption();
~ConquerEncryption();
void Encrypt(byte * Packet, int PacketLength);
void Decrypt(byte * Packet, int PacketLength);
void SetKeys(UINT Key11, UINT Key22);
};
}
#endif
Source file (coenc.cpp):
PHP Code:
#include "coenc.h"
namespace ConquerEncryptionClasses
{
ConquerEncryption::ConquerEncryption()
{
this->InPackets = this->OutPackets = 0;
this->AlternateDec = false;
}
ConquerEncryption::~ConquerEncryption()
{
if(this->Key3 != 0 && this->Key4 != 0)
{
delete[] this->Key3;
delete[] this->Key4;
}
}
void ConquerEncryption::SetKeys(UINT Key11, UINT Key22)
{
UINT dwKey1 = ((Key11 + Key22) ^ 0x4321) ^ Key11;
UINT dwKey2 = dwKey1 * dwKey1;
this->Key3 = new byte[256];
this->Key4 = new byte[256];
byte * dKey1 = const_cast<byte*>(Key1), * dKey2 = const_cast<byte*>(Key2), * dKey3 = Key3, * dKey4 = Key4, KeyL = 256 / 4;
for(int i = 0; i < KeyL; i++)
{
*(dKey3 + i) = dwKey1 ^ *(dKey1 + i);
*(dKey4 + i) = dwKey2 ^ *(dKey2 + i);
}
this->OutPackets = 0;
this->AlternateDec = true;
}
void ConquerEncryption::Encrypt(byte *Packet, int PacketLength)
{
byte * packet = new byte[PacketLength];
memcpy(packet, Packet, PacketLength);
for(int It = 0; It < PacketLength; It++)
{
(*(packet + It)) = *(Packet + It) ^ 0xAB;
(*(packet + It)) = (*(Key2 + OutPackets) >> 8) ^ *(packet + It);
(*(packet + It)) = (*(Key1 + OutPackets) & 0xFF) ^ *(packet + It);
this->OutPackets++;
}
memcpy(Packet, packet, PacketLength);
delete[] packet;
}
void ConquerEncryption::Decrypt(byte *Packet, int PacketLength)
{
byte * packet = new byte[PacketLength];
memcpy(packet, Packet, PacketLength);
for(int It = 0; It < PacketLength; It++)
{
(*(packet + It)) = *(Packet + It) ^ 0xAB;
(*(packet + It)) = (*(packet + It) << 4 | *(packet + It) >> 4);
if(this->AlternateDec)
{
(*(packet + It)) = (*(Key4 + InPackets) >> 8) ^ *(packet + It);
(*(packet + It)) = (*(Key3 + InPackets) & 0xFF) ^ *(packet + It);
}
else
{
(*(packet + It)) = (*(Key2 + InPackets) >> 8) ^ *(packet + It);
(*(packet + It)) = (*(Key1 + InPackets) & 0xFF) ^ *(packet + It);
}
this->InPackets++;
}
memcpy(Packet, packet, PacketLength);
delete[] packet;
}
}
Emm here:
|
|
|
03/06/2010, 15:49
|
#55
|
elite*gold: 0
Join Date: Feb 2010
Posts: 492
Received Thanks: 222
|
I'm gonna sound like such a **** noob but on the Create Character screen u added the newest version xD but were do I add it
|
|
|
03/06/2010, 16:59
|
#56
|
elite*gold: 0
Join Date: Sep 2009
Posts: 321
Received Thanks: 60
|
Quote:
Originally Posted by Paralyzer[GM]
I'm gonna sound like such a **** noob but on the Create Character screen u added the newest version xD but were do I add it 
|
its not about just adding the packets u need to actully know how to use them and how they go together with refrances etc...
|
|
|
03/06/2010, 19:34
|
#57
|
elite*gold: 20
Join Date: Dec 2006
Posts: 945
Received Thanks: 175
|
Quote:
Originally Posted by Nullable
I only made a 5017 one, didn't want all those high versions, anyhow I'm not quite sure it works because I didn't have the chance to test it(abandoned project) so I will just paste it here:
Header File(coenc.h):
PHP Code:
#ifndef _COENC_H
#define _COENC_H
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
#include <iostream>
#include <stdio.h>
#include <stdlib.h>
#include <windows.h>
#define KEY_SIZE 256
typedef unsigned char byte;
namespace ConquerEncryptionClasses
{
static const byte Key1[] =
{
0x9D, 0x90, 0x83, 0x8A, 0xD1, 0x8C, 0xE7, 0xF6, 0x25, 0x28, 0xEB, 0x82, 0x99, 0x64, 0x8F, 0x2E,
0x2D, 0x40, 0xD3, 0xFA, 0xE1, 0xBC, 0xB7, 0xE6, 0xB5, 0xD8, 0x3B, 0xF2, 0xA9, 0x94, 0x5F, 0x1E,
0xBD, 0xF0, 0x23, 0x6A, 0xF1, 0xEC, 0x87, 0xD6, 0x45, 0x88, 0x8B, 0x62, 0xB9, 0xC4, 0x2F, 0x0E,
0x4D, 0xA0, 0x73, 0xDA, 0x01, 0x1C, 0x57, 0xC6, 0xD5, 0x38, 0xDB, 0xD2, 0xC9, 0xF4, 0xFF, 0xFE,
0xDD, 0x50, 0xC3, 0x4A, 0x11, 0x4C, 0x27, 0xB6, 0x65, 0xE8, 0x2B, 0x42, 0xD9, 0x24, 0xCF, 0xEE,
0x6D, 0x00, 0x13, 0xBA, 0x21, 0x7C, 0xF7, 0xA6, 0xF5, 0x98, 0x7B, 0xB2, 0xE9, 0x54, 0x9F, 0xDE,
0xFD, 0xB0, 0x63, 0x2A, 0x31, 0x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18, 0xC5, 0x8E, 0x1B, 0x34, 0x41, 0xCA, 0xF7, 0x10, 0xFD, 0xC6, 0x13, 0xAC, 0xF9,
0x82, 0x6F, 0x08, 0x35, 0xFE, 0x0B, 0x24, 0xB1, 0x3A, 0xE7, 0x00, 0x6D, 0x36, 0x03, 0x9C, 0x69,
0xF2, 0x5F, 0xF8, 0xA5, 0x6E, 0xFB, 0x14, 0x21, 0xAA, 0xD7, 0xF0, 0xDD, 0xA6, 0xF3, 0x8C, 0xD9
};
class ConquerEncryption
{
private:
byte * Key3, * Key4;
USHORT InPackets, OutPackets;
bool AlternateDec;
public:
ConquerEncryption();
~ConquerEncryption();
void Encrypt(byte * Packet, int PacketLength);
void Decrypt(byte * Packet, int PacketLength);
void SetKeys(UINT Key11, UINT Key22);
};
}
#endif
Source file (coenc.cpp):
PHP Code:
#include "coenc.h"
namespace ConquerEncryptionClasses
{
ConquerEncryption::ConquerEncryption()
{
this->InPackets = this->OutPackets = 0;
this->AlternateDec = false;
}
ConquerEncryption::~ConquerEncryption()
{
if(this->Key3 != 0 && this->Key4 != 0)
{
delete[] this->Key3;
delete[] this->Key4;
}
}
void ConquerEncryption::SetKeys(UINT Key11, UINT Key22)
{
UINT dwKey1 = ((Key11 + Key22) ^ 0x4321) ^ Key11;
UINT dwKey2 = dwKey1 * dwKey1;
this->Key3 = new byte[256];
this->Key4 = new byte[256];
byte * dKey1 = const_cast<byte*>(Key1), * dKey2 = const_cast<byte*>(Key2), * dKey3 = Key3, * dKey4 = Key4, KeyL = 256 / 4;
for(int i = 0; i < KeyL; i++)
{
*(dKey3 + i) = dwKey1 ^ *(dKey1 + i);
*(dKey4 + i) = dwKey2 ^ *(dKey2 + i);
}
this->OutPackets = 0;
this->AlternateDec = true;
}
void ConquerEncryption::Encrypt(byte *Packet, int PacketLength)
{
byte * packet = new byte[PacketLength];
memcpy(packet, Packet, PacketLength);
for(int It = 0; It < PacketLength; It++)
{
(*(packet + It)) = *(Packet + It) ^ 0xAB;
(*(packet + It)) = (*(Key2 + OutPackets) >> 8) ^ *(packet + It);
(*(packet + It)) = (*(Key1 + OutPackets) & 0xFF) ^ *(packet + It);
this->OutPackets++;
}
memcpy(Packet, packet, PacketLength);
delete[] packet;
}
void ConquerEncryption::Decrypt(byte *Packet, int PacketLength)
{
byte * packet = new byte[PacketLength];
memcpy(packet, Packet, PacketLength);
for(int It = 0; It < PacketLength; It++)
{
(*(packet + It)) = *(Packet + It) ^ 0xAB;
(*(packet + It)) = (*(packet + It) << 4 | *(packet + It) >> 4);
if(this->AlternateDec)
{
(*(packet + It)) = (*(Key4 + InPackets) >> 8) ^ *(packet + It);
(*(packet + It)) = (*(Key3 + InPackets) & 0xFF) ^ *(packet + It);
}
else
{
(*(packet + It)) = (*(Key2 + InPackets) >> 8) ^ *(packet + It);
(*(packet + It)) = (*(Key1 + InPackets) & 0xFF) ^ *(packet + It);
}
this->InPackets++;
}
memcpy(Packet, packet, PacketLength);
delete[] packet;
}
}
Emm here: 
|
Really wants to make me learn C++
|
|
|
03/06/2010, 19:40
|
#58
|
elite*gold: 0
Join Date: Nov 2009
Posts: 390
Received Thanks: 321
|
Quote:
Originally Posted by hunterman01
Really wants to make me learn C++
|
Nice  anyhow I'll leave Korvacs's thread alone  , you might discuss anything about the library in the release thread(or here, but you're on your own then XD)
|
|
|
03/06/2010, 21:22
|
#59
|
elite*gold: 0
Join Date: Jan 2008
Posts: 1,443
Received Thanks: 1,175
|
Quote:
Originally Posted by Nullable
I only made a 5017 one, didn't want all those high versions, anyhow I'm not quite sure it works because I didn't have the chance to test it(abandoned project)[...]
|
I think it's working... But why you don't use sizeof operator for the packet length?
|
|
|
03/07/2010, 13:58
|
#60
|
elite*gold: 0
Join Date: Nov 2009
Posts: 390
Received Thanks: 321
|
Quote:
Originally Posted by CptSky
I think it's working... But why you don't use sizeof operator for the packet length?
|
sizeof doesn't work that way.. you should read something about it or better try doing it yourself, and remember that the packet i'm reading is actually a pointer to the actual packet allocated on heap, in simple words sizeof doesn't work like this with pointers
|
|
|
Similar Threads
|
[Resource] My Wiki
05/07/2011 - CO2 Private Server - 4 Replies
Hey. Hope you get use out of this.
If you want me to add anything, just say so and
what you want me to add below.
Link: https://conquerresources.wikispaces.com/
Edit: Here are all of the source downloads btw in a list:
http://spirited-fang.blogspot.com/p/source-downlo ads.html
Sincerely,
|
Resource Wiki
11/12/2010 - CO2 Private Server - 3 Replies
Hey everyone,
I know how helpful it is to have a Packet Wiki, so I thought that I would add this to help you all. It's a resource wiki that will help you customize your source. Hope you all like it!
http://conquerproject.wikispaces.com/space/badge/ 468x60
Link if you can't figure out that the image is the link: Conquer Project Resources
Sincerely,
Fang
|
All times are GMT +1. The time now is 15:52.
|
|