rev7254 | Not able to connect using Poseidon, bRO | 2.0.7

This place is for Closed bug reports only. NOT for asking help!

Moderators: Moderators, Developers

Message
Author
Mushroom
Perl Monk
Perl Monk
Posts: 427
Joined: 04 Apr 2008, 14:04
Noob?: No
Location: Brazil

rev7254 | Not able to connect using Poseidon, bRO | 2.0.7

#1 Post by Mushroom »

Just wanted to run openkore on bRO-Thor to check somethings and just noticed that Openkore is bugging when connecting with Poseidon.
After running openkore (with poseidon and ragnarok client opened already), posedon keeps spamming these messages:
Querying Ragnarok Online client.
Error: no Ragnarok Online client connected.
However, I found a fix on Brazilian Openkore forum and it seems to be working fine.
Maybe it could be commited? so bRO users don't need to apply the patch (unless the fix bugs other official servers)

- Patch is attached to the topic.
Attachments

[The extension patch has been deactivated and can no longer be displayed.]

Quit.

User avatar
kLabMouse
Administrator
Administrator
Posts: 1301
Joined: 24 Apr 2008, 12:02

Re: rev7254 | Not able to connect using Poseidon, bRO | 2.0.7

#2 Post by kLabMouse »

Mushroom wrote:However, I found a fix on Brazilian Openkore forum and it seems to be working fine.
Maybe it could be commited? so bRO users don't need to apply the patch (unless the fix bugs other official servers)

- Patch is attached to the topic.
This patch is mostly back-port to IPC Msg Exchange.
the main patches are:
Request/Response patch, to allow query in non Map mode

Code: Select all

-			if ($clients->[$i]{connectedToMap}) {
-                		$clients->[$i]->send($packet);
-                		$self->{state} = 'requesting';
-                		return;
-			}
+			$clients->[$i]->send($packet);
+			$self->{state} = 'requesting';
+			return;

Code: Select all

-	$client->{connectedToMap} = 1;
Server List/Char list patch (donno if it is even needed)

Code: Select all

-#		my $data = pack("C*", 0xAD, 0x02, 0x00, 0x00, 0x1E, 0x0A, 0x00, 0x00);
-#		$client->send($data);
 		my $sex = 1;
 		my $serverName = pack("a20", "Poseidon server"); # server name should be less than or equal to 20 characters
 		my $serverUsers = pack("V", @{$self->clients()} - 1);
 		# '0069' => ['account_server_info', 'x2 a4 a4 a4 x30 C1 a*',
 		# 			[qw(sessionID accountID sessionID2 accountSex serverInfo)]],
-		my $data;
-		if ($switch eq '01FA') {
-			$data = pack("C*", 0x69, 0x00, 0x53, 0x00) . 
-				$sessionID . $accountID . $sessionID2 . 
-				pack("x30") . pack("C1", $sex) . pack("x4") .
-				pack("C*", $ipElements[0], $ipElements[1], $ipElements[2], $ipElements[3]) .
-				$port .	$serverName . $serverUsers . pack("x2");
-		} else {
-			$data = pack("C*", 0x69, 0x00, 0x4F, 0x00) . 
-				$sessionID . $accountID . $sessionID2 . 
-				pack("x30") . pack("C1", $sex) .
-				pack("C*", $ipElements[0], $ipElements[1], $ipElements[2], $ipElements[3]) .
-				$port .	$serverName . $serverUsers . pack("x2");
-		}
+		my $data = pack("C*", 0x69, 0x00, 0x4f, 0x00) . 
+			$sessionID . $accountID . $sessionID2 . 
+			pack("x30") . pack("C1", $sex) .
+			pack("C*", $ipElements[0], $ipElements[1], $ipElements[2], $ipElements[3]) .
+			$port .	$serverName . $serverUsers . pack("x2");
kRO Mode disable(donno why)

Code: Select all

-		if($switch eq '02B0') {	# kRO uses 02B2 as masterLogin packet when we have <langtype>0</langtype> in the clientinfo.xml
-								# if other servers do use this packet too that will be a problem.
-			$clientdata{$index}{kRO} = 1;
-		}
Map Login patch

Code: Select all

-	} elsif ($switch eq '0436' &&
-		(length($msg) == 19) &&
-		(substr($msg, 2, 4) eq $accountID) &&
-		(substr($msg, 6, 4) eq $charID) &&
-		(substr($msg, 10, 4) eq $sessionID)
-		) { # client sends the maplogin packet
-
-		$client->send(pack("v a4", 0x0283, $accountID));
-		# mapLogin packet
-		$client->send(pack("H536", "eb0206ad09222b56c0050500000f012c010100000000000900000001004e565f42415349430000000000000000080000000f0000000030000000000000000000010054465f444f55424c4500000000000000090000000f0000000131000000000000000000010054465f4d495353000000000000000000070000000f0000000132000100000000000a00010054465f535445414c0000000000000000080000000f0000000133000400000000000a00010054465f484944494e4700000000000000090000000f0000000034000100000000000c00020054465f504f49534f4e00000000000000090000000f0000000135001000000000000a00090054465f4445544f5849465900000000000b0000000f000000008e00040000000100030001004e565f464952535441494400000000000b0000000f00000000d701df145a000200000000d701df145a0003000000003a010100d701df145a0002f13200003a010100b0001900d06b0000b0001800b2110000b102080000000000b202080000000000b0002a003f000000b0002b0000000000b0002e002d000000b000300000000000d9070039020000000000000000000000000000000000000000000000000000233000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000"));
-		$client->{connectedToMap} = 1;
-
Packet Glue Filter

Code: Select all

@@ -521,7 +476,7 @@
 		### Check if packet 0228 got tangled up with the sync packet
 		if (uc(unpack("H2", substr($msg, 7, 1))) . uc(unpack("H2", substr($msg, 6, 1))) eq '0228') {
 			# queue the response (thanks abt123)
-			$self->{response} = substr($msg, 6, length($msg));
+			$self->{response} = substr($msg, 6, 18);
 			$self->{state} = 'requested';
 		}
 
@@ -540,17 +495,6 @@
 
 	} elsif ($switch eq '0228') { # client sends game guard sync
 		# Queue the response
-		# Don't allow other packet's (like Sync) to get to RO server.
-		my $length = unpack("v",substr($msg,2,2));
-		if ($length > 0) {
-			$self->{response} = substr($msg,0,$length+2);
-		} else {
-			$self->{response} = $msg;
-		};
-		$self->{state} = 'requested';
-	
-	} elsif ($switch eq '02A7') { # client sends hShield response
-		# Queue the response
 		$self->{response} = $msg;
 		$self->{state} = 'requested';

As for Me, the patch is very lame, and should be made more smart to not break compatibility with other clients.

random
Noob
Noob
Posts: 1
Joined: 11 Dec 2010, 16:31
Noob?: Yes

Poseidon, bRO | 2.0.7

#3 Post by random »

I'm quite new here, actually I already used bot but that was a long time ago and I don't remember nothing. At all.

@Ok, skipping that lil' unecessary introduction, here's my problem:
I play bRO, so, I need Poseidon, and so I made all the necessary to use it; when I'm entering the Poseidon server a bug appears, and I can't enter the server,

The error: Yep it won't help much.
Image

Here are the poseidon .exe and .xml files (in ragnarok folder);

Code: Select all

ragexe.exe 1rag1 /account:poseidon.xml

Code: Select all

 <?xml version="1.0" encoding="euc-kr" ?>
<clientinfo>
	<servicetype>brazil</servicetype>
	<servertype>primary</servertype>
	<extendedslot></extendedslot>

	<connection>
		<display>Poseidon</display>
		<desc>None</desc>
		<address>127.0.0.1</address>
		<port>6900</port>
		<version>1</version>
		<registrationweb>http://www.openkore.com/</registrationweb>
	</connection>
</clientinfo>
@Brazil has 2 servers, should I Put 2 servers in the poseidon.xml?
@Sometimes, If I go quickly, I can get to the character selection tab, but can't enter.
@Sometimes when I try to enter the server with a random password/username, it says "Can't connect to server."

Mushroom
Perl Monk
Perl Monk
Posts: 427
Joined: 04 Apr 2008, 14:04
Noob?: No
Location: Brazil

Re: rev7254 | Not able to connect using Poseidon, bRO | 2.0.7

#4 Post by Mushroom »

Since I'm back at botting I decided to analyze if this patch is still necessary to run poseidon on bRO. Well, it is.
But you don't need to replace all this files, the only lines that are required to change are this:

Code: Select all

Index: RagnarokServer.pm
===================================================================
--- RagnarokServer.pm	(revision 7678)
+++ RagnarokServer.pm	(working copy)
@@ -64,11 +64,9 @@
 
 	for (my $i = 0; $i < @{$clients}; $i++) {
 		if ($clients->[$i]) {
-			if ($clients->[$i]{connectedToMap}) {
-                		$clients->[$i]->send($packet);
-                		$self->{state} = 'requesting';
-                		return;
-			}
+            $clients->[$i]->send($packet);
+            $self->{state} = 'requesting';
+            return;
 		}
 	}
 	print "Error: no Ragnarok Online client connected.\n";
Quit.

iMikeLance
Moderators
Moderators
Posts: 208
Joined: 01 Feb 2010, 17:37
Noob?: No
Location: Brazil - MG
Contact:

Re: rev7254 | Not able to connect using Poseidon, bRO | 2.0.7

#5 Post by iMikeLance »

Fixed a long time ago.

Post Reply