Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Conquer Online 2 > CO2 Private Server
You last visited: Today at 09:46

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[Problem] Authentication to GameServer

Discussion on [Problem] Authentication to GameServer within the CO2 Private Server forum part of the Conquer Online 2 category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Jul 2010
Posts: 223
Received Thanks: 23
[Problem] Authentication to GameServer

Hey Everyone,

I don't write often about problems that I'm having... but I've been at this for days researching this problem. First, you must know that the structure of my server is much like CoEmu. It is split up into two servers: a login server and a world server. Secondly, you must know that my socket system problem isn't just one problem, but many huge problems that I can't find the root of.

This is what I have found out through backtracking:

1. The problem isn't with the login server. The login server sends the correct key and information to the world server successfully every time.

2. The world server picks up the key and information correctly and sets the ASocket in the connection request handler.

3. The Connection Request system then picks it up successfully and records the key for research use.

4. It then adds the key to Authenticated Logins after checking to see if it's already in the system. The user is entering the game server now and the client starts to initialize... This is where it goes wrong.

5. The Login Handler now starts... if the information did not make it, then it stops the client at "initializing" and never enters the game server. The case that handles the login handler in the packet processor is case 1052. This is meant to end the authorization process and load the character into the game server.

If it doesn't pick it up... the client process bar will not move and the server will report that the connection is being dismissed (Timed Out in CoEmu talk). This is just one of the major problems with the login process of Conquer Online New Dawn.

Help is appreciated.
-Fang

PS: What happens if you run 32,577 threads on the server? What is the comparison to running 18? I know this is extreme... but that's what my server can hold. Thanks.
-Fáng- is offline  
Old 08/29/2010, 12:45   #2


 
Korvacs's Avatar
 
elite*gold: 20
Join Date: Mar 2006
Posts: 6,125
Received Thanks: 2,518
So whats the problem? I read all of it twice and couldnt find an issue, if the server didnt get the info then it kicks the client, thats a good thing...

Threads wise, since every thread tries to occupy CPU Time, there will be a point where more threads makes the server less efficient. See there is no limit to the number of software threads you can make, but your processor can only handle (in alot of cases) 2 threads per core, per time interval, this doesnt sound like alot however the cpu will adjust the time interval to compensate for the number of software threads which are active. So like i say, at some point you'll find your threads arnt getting enough CPU Time, at which point you'll have reached the tipping point and it will all be down hill from there.

32,577 Sounds like its going to cause issues, most apps dont use more than 100, and the less threads you use the more CPU Time each of them can have so a server running 18 will keep the **** outta a server running 32,577. Also how can your server "hold" 32,577 did you limit it to that number? Or what.
Korvacs is offline  
Old 08/29/2010, 13:09   #3
 
_DreadNought_'s Avatar
 
elite*gold: 28
Join Date: Jun 2010
Posts: 2,223
Received Thanks: 867
His problem(I think) is that when you login you never log stright in, you have to login 2x to get in game?
_DreadNought_ is offline  
Old 08/29/2010, 13:10   #4
 
elite*gold: 0
Join Date: Jul 2010
Posts: 223
Received Thanks: 23
Quote:
Originally Posted by Korvacs View Post
So whats the problem? I read all of it twice and couldnt find an issue, if the server didnt get the info then it kicks the client, thats a good thing...

Threads wise, since every thread tries to occupy CPU Time, there will be a point where more threads makes the server less efficient. See there is no limit to the number of software threads you can make, but your processor can only handle (in alot of cases) 2 threads per core, per time interval, this doesnt sound like alot however the cpu will adjust the time interval to compensate for the number of software threads which are active. So like i say, at some point you'll find your threads arnt getting enough CPU Time, at which point you'll have reached the tipping point and it will all be down hill from there.

32,577 Sounds like its going to cause issues, most apps dont use more than 100, and the less threads you use the more CPU Time each of them can have so a server running 18 will keep the crap outta a server running 32,577. Also how can your server "hold" 32,577 did you limit it to that number? Or what.
That doesn't seem right at all Korvacs. If the server didn't get the info then that's a bad thing because it's supposed to send it so the client can reach the game server. You obviously did not read this twice. And as far as threads go... you must be mistaken. My server is running 5 threads at all times to handle the server and they are being used at the same time. I have a dual core. Also, as I said, the "32,577" is the number that my server says it can handle. I don't know how it could and I know it will crash my computer before it could... but the server itself can handle 32,577 threads. Anyways, I was just curious. The login problem is my concern. All I know is that it's something to do with linking the auth ok to the game server.
-Fáng- is offline  
Old 08/29/2010, 13:45   #5


 
Korvacs's Avatar
 
elite*gold: 20
Join Date: Mar 2006
Posts: 6,125
Received Thanks: 2,518
Quote:
Originally Posted by -Fáng- View Post
That doesn't seem right at all Korvacs. If the server didn't get the info then that's a bad thing because it's supposed to send it so the client can reach the game server. You obviously did not read this twice. And as far as threads go... you must be mistaken. My server is running 5 threads at all times to handle the server and they are being used at the same time. I have a dual core. Also, as I said, the "32,577" is the number that my server says it can handle. I don't know how it could and I know it will crash my computer before it could... but the server itself can handle 32,577 threads. Anyways, I was just curious. The login problem is my concern. All I know is that it's something to do with linking the auth ok to the game server.
The reason its a good thing is because the client sends the data, so if the client doesnt send the data then the server kicks the client, thats good. If the reason your not receiving the data is because of your socket server, then you need to output all of the decrypted data your receiving from the socket and check that your actually receiving your 1052 if you are then track the data by debugging and see where you loose it. You have a load of tools available for you, the console is Key for debugging, just output the packet as you go through your methods and see where your going wrong.

As for your threads no im not mistaken, all threads share CPU Time, they dont all run at the same time, a thread takes a fraction of the CPU Time, and then the next thread gets some CPU Time, then the next one, and so on and so on. A typical server (not limited to Conquer servers) should use in the region of 15/20 threads, there simply is no need for more, a massive server on a Hardware Multi-CPU motherboard (4 physical cpus, 16 cores?) No more than 200 really. Dunno why you think your server can handle 32.5k, dunno why you mentioned it really..
Korvacs is offline  
Old 08/29/2010, 13:59   #6
 
ImmuneOne's Avatar
 
elite*gold: 0
Join Date: Nov 2009
Posts: 754
Received Thanks: 544
Your Auth->Game Sequence;
Quote:
CoClient -> AuthSocket (LoginRequest)
AuthSocket -> CoClient (LoginReply) // Key 3 = Banned, 2 = Correct, 1 = Wrong password
AuthSocket -> GameSocket (Connection_Request)
CoClient -> GameSocket (OnGameConnect)
Supposed to be;
Quote:
CoClient -> AuthSocket (LoginRequest)
AuthSocket -> CoClient (LoginReply) // Key 3 = Banned, 2 = Correct, 1 = Wrong password
CoClient -> GameSocket;
(OnGameConnect)
Quote:
[StructLayout(LayoutKind.Sequential, CharSet=Ansi)]
struct OnGameConnect
{
public PacketHeader Header; //Contains PSize, PType
public UInt32 Connection_ID; //Connection ID sent by AuthSocket to CoClient
public UInt32 Connection_Key; //Connection key sent by AuthSocket to CoClient
[MarshalAs(UnmanagedType.ByValTStr, SizeConst=16)]
public String Connection_Message;//Informs you about client's language
}
if Connection_ID == 0
SendMsg("Un-authorized connection!");
if Connection_Key == 3
SendMsg("You are banned!");

LoadHero(GamePacket.Connection_ID, Client);
There is no need at all to create an extra socket.
ImmuneOne is offline  
Old 08/29/2010, 15:50   #7
 
elite*gold: 0
Join Date: Oct 2008
Posts: 342
Received Thanks: 66
Weird CoEmu coding. But yeah Andy always coded messy sockets

Fang.. you might implement Hybrids Socket System. (there is a version for blowfish out already)
µ~Xero~µ is offline  
Old 08/29/2010, 15:54   #8

 
Kiyono's Avatar
 
elite*gold: 20
Join Date: Jun 2006
Posts: 3,296
Received Thanks: 924
Quote:
Originally Posted by µ~Xero~µ View Post
Weird CoEmu coding. But yeah Andy always coded messy sockets

Fang.. you might implement Hybrids Socket System. (there is a version for blowfish out already)
Really? I've been watching this forum for quite some time and never saw it being posted.
Kiyono is offline  
Old 08/29/2010, 16:38   #9
 
elite*gold: 0
Join Date: Oct 2008
Posts: 342
Received Thanks: 66
by InFlamedCo
µ~Xero~µ is offline  
Old 08/29/2010, 17:40   #10
 
Arcо's Avatar
 
elite*gold: 0
Join Date: Oct 2009
Posts: 8,765
Received Thanks: 5,291
Quote:
Originally Posted by Kiyono View Post
Really? I've been watching this forum for quite some time and never saw it being posted.
Yup InflamedCOD released one, its the one I used to upgrade hybrids source past 5017.
Arcо is offline  
Thanks
1 User
Old 08/29/2010, 17:53   #11

 
Kiyono's Avatar
 
elite*gold: 20
Join Date: Jun 2006
Posts: 3,296
Received Thanks: 924
Quote:
Originally Posted by .Arco View Post
Yup InflamedCOD released one, its the one I used to upgrade hybrids source past 5017.
I did some searching and found it, I even posted in the thread but I just forgot about it lol
Kiyono is offline  
Thanks
2 Users
Old 08/29/2010, 19:29   #12
 
elite*gold: 0
Join Date: Jul 2010
Posts: 223
Received Thanks: 23
Hm... well my socket system is fast... really fast. If the other socket system is better though... how on earth would I implement that for CoEmu. It's a one project system is it not?

ImmuneOne, what socket system are you using in your unfinished project?
-Fáng- is offline  
Old 08/29/2010, 19:40   #13
 
elite*gold: 0
Join Date: Oct 2008
Posts: 342
Received Thanks: 66
YOu can always port the sockets. and Immune had his own.
µ~Xero~µ is offline  
Old 08/29/2010, 19:45   #14


 
Korvacs's Avatar
 
elite*gold: 20
Join Date: Mar 2006
Posts: 6,125
Received Thanks: 2,518
Quote:
Originally Posted by -Fáng- View Post
Hm... well my socket system is fast... really fast. If the other socket system is better though... how on earth would I implement that for CoEmu. It's a one project system is it not?

ImmuneOne, what socket system are you using in your unfinished project?
The socket class in any server tends to be a fairly seperate entity, you should be able to convert it fairly easily really.
Korvacs is offline  
Old 08/29/2010, 19:47   #15
 
elite*gold: 0
Join Date: Jul 2010
Posts: 223
Received Thanks: 23
Ok, well I'll look into it then. What are the advantages of using that socket system though?
-Fáng- is offline  
Reply


Similar Threads Similar Threads
New problem on gameserver ! look :)
04/25/2010 - SRO Private Server - 36 Replies
http://img232.imageshack.us/img232/3167/77464059.p ng Uploaded with ImageShack.us what to do :D? Its close 1 sec after that error :P
[Q] Authentication
06/23/2009 - Kal Online - 3 Replies
I heard is it possible to to jump behind the authentication of your account so blocked accounts work again, is it true? and how is it possible?
[HELP] my GameServer have problem [HELP]
12/13/2008 - EO PServer Hosting - 10 Replies
Hi all its my first post i need help hope u guys help i've done from makeing the accountserver and its fully work the gameserver have problem i dont know why http://img156.imageshack.us/img156/724/dbsg0.png http://img156.imageshack.us/img156/dbsg0.png/1/w6 41.png
I've got a Gameserver - How to use the Serverfiles with Gameserver?
09/21/2008 - Flyff Private Server - 3 Replies
Hi, I've got a old Gameserver from a friend. I think its fast enough for 4 people^^ But, I don't know how to "copy" the Server files. Or, what must I do? Please help ToonMaster
Authentication Key
03/15/2008 - WoW PServer Exploits, Hacks & Tools - 8 Replies
can some1 post valid Authentication Key for wow so i can create acc on blizz server...



All times are GMT +2. The time now is 09:46.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.