RunUO Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

[RunUO 2.0 RC1] Pandora's Box / BoxServer

Irian

Page
[RunUO 2.0 RC1] Pandora's Box / BoxServer

Updated (1.2): Should work completly now. No changes in the RunUO encryption needed.

Pandora's Box works fine with RunUO 2.0 - but unfortunatly, the BoxServer doesn't. I changed the Scripts, recompiled the BoxServer.dll and the Pandora.exe to make it work. You only need to do a small bugfix in the RunUO code itself.

0. If you use RunUO 2.0 RC1, you'll have to fix a little bug in the file /Scripts/Accounting/Account.cs. It was fixed in the SVN with version 67, so if you use any version higher than that, you will not have to do it...

Simply look at line 131 and replace this code...

Code:
		public string NewCryptPassword
		{
			get { return m_CryptPassword; }
			set { m_CryptPassword = value; }
		}

with this...

Code:
		public string NewCryptPassword
		{
			get { return m_NewCryptPassword; }
			set { m_NewCryptPassword = value; }
		}

1. Install Pandora's Box and replace with Pandora.exe with the one in the Pandora.zip file.

2. Either install the BoxServer with the BoxServerSetup.exe and then replace the files/folders with the one from the BoxServer.zip (be carefull,the BoxServer.dll must be in the RunUO main folder) or copy the contents of the BoxServer.zip into your /Scripts/ folder, move the BoxServer.dll to your RunUO main folder and edit the file Data/Assemblies.cfg by adding this two lines:

Code:
BoxServer.dll
System.Runtime.Remoting.dll

Don't forget to enable "SHA1 encryption" in the Server-Options of Pandora's Box.

I've included the ServerOptions.zip with the ServerOptions.cs file for all the people who want to recompile Pandora's Box on their on. For recompiling the BoxServer.dll simply change the includes of "zlib" to "zlib32".
 

Attachments

  • BoxServer.zip
    42.1 KB · Views: 2,447
  • Pandora.zip
    412 KB · Views: 3,336
  • ServerOptions.zip
    1.1 KB · Views: 1,716

Irian

Page
So, for anyone who want's to know, what the problem with encryption was...

Pandora's Box already had an option to use SHA1 encryption (which is also used in RunUO 2.0), BUT the details were a little bit different:

1. Pandora's Box used the following code to get the string that would be hashed:

Code:
string toHash = Username + Username.Length + Password;

RunUO only uses...

Code:
string toHash = Username + Password;

2. Pandora's Box hashed the thing twice, first the toHash string and then it hashed the Hash again. RunUO doesn't.

After changing that in the Pandora code - and fixing a little RunUO bug (see above) it was possible to bring the BoxServer to work.
 

Icon

Wanderer
Irian said:
I think, Pandora compiles fine with .Net 2.0 (some warnings, ok, but ne errors, iirc).



Nope says u need to have the .net 1.1 installed for it to work same goes if u try to run runuo 2.0 on an .net 1.1 install ( if there isnt a recompiled PB2 version out i guess i can install both 1.1 and 2.0 versions of the .net to run both :p)

Hk
 
I believe .NET 2.0 will overwrite .NET 1.1 and I would not suggest tring to get around this by installing them into two seperate directories. This will lead to alot of problems.

I have plans to update PB to .NET 2.0 and also add all of the new content from expansions to bring it fully up to date.
 

ratzerna

Sorceror
Just check your :

C:\WINDOWS\Microsoft.NET\Framework directory

You'll see several versions installed. I currently have 1.0, 1.1, and 2.0 all installed. Of course if you didn't install 1.0 or 1.1, they may not be in your directory.

Of course there is the slight possibility I'm not refering to what your talking bout at all. sorry for the confusion if that's the case.
 
question, when you were redoing pandora's box, did you set it to use the expanded map regions now also available in the game?

because right now - even statics and map features show black if you go into those areas.

(as of patch 5.1 i believe and have to update maps also - but i belive 2.0 is all ready - tram and fel maps are 1.5 times wider)

But i am going to try this in a little bit - i was having problems getting past one point - but i forgot about the dll file - that was probaly my problem
 
this is for installing and getting pandora's box to work with RunUo 2.0
(pandora's box is like axis was for sphere, but a lot more features)

you will need pandora's box for it also

get it here:
http://arya.altervista.org/

and then folow his procedures in the 1st post


-----

I also checked - this version does not include support for the expanded maps

If you could - it would be nice to have them in (2.0 does support them by default -- the new size is : 7168, 4096)
 

Erica

Knight
Lord_Greywolf said:
this is for installing and getting pandora's box to work with RunUo 2.0
(pandora's box is like axis was for sphere, but a lot more features)

you will need pandora's box for it also

get it here:
http://arya.altervista.org/

and then folow his procedures in the 1st post


-----

I also checked - this version does not include support for the expanded maps

If you could - it would be nice to have them in (2.0 does support them by default -- the new size is : 7168, 4096)
That would be awesome if got the pandora box map to work on 2.0 like Lord_Greywolf said got a question as well so if i do exactly whats on the first post it should work with 2.0 svn 64 right ?
 

Irian

Page
I recompiled the MapViewer.dll a long time ago for the new MapSizes, here's the link... Has nothing to do with the Pandora.exe, iirc.
 

Irian

Page
1. Are you sure, that you opened Pandora's Options, went to "Server", activated "Server uses SHA1 hashing", re-typed your password and pressed "Update"?

If yes:

Check in the AccountHandler.cs, what "ProtectPasswords" is. If it's "NewCrypt", it's SHA1. If it's "Crypt", it's MDA5, if it's "None", it won't work wit PB. :)

Try to edit the file Authentication.cs in your BoxServer's Core folder. Search for this code...

Code:
public static AuthenticationResult Authenticate( BoxMessage msg )
		{
			Account account = GetAccount( msg.Username );

			if ( account == null )
			{
				// Account doesn't exist
				return AuthenticationResult.WrongCredentials;
			}

			AuthenticationResult auth = AuthenticationResult.WrongCredentials;

and add...

Code:
            System.Console.WriteLine(msg.Password);
            System.Console.WriteLine(account.NewCryptPassword);

Then the server will show the password Pandora sends and the password, the server expectes. If they differ, you forgot something (or I forgot to mention something :).
 

endwolf

Sorceror
Lost without the box...

Code:
RunUO - [www.runuo.com] Version 2.0, Build 2357.32527
Core: Running on .NET Framework Version 2.0.50727
Core: Optimizing for 2 processors
Scripts: Compiling C# scripts...done (0 errors, 0 warnings)
Scripts: Compiling VB.NET scripts...no files found.
Scripts: Verifying...done (2337 items, 563 mobiles)
Regions: Loading...done
World: Loading...done (99892 items, 2422 mobiles) (3.62 seconds)
Pandora is listening on port 8035 - BoxServer version 0.3


And the .CS looks like this....

Code:
public static AuthenticationResult Authenticate( BoxMessage msg )
		{
			Account account = GetAccount( msg.Username );

			if ( account == null )
			{
				// Account doesn't exist
				return AuthenticationResult.WrongCredentials;
			}

			AuthenticationResult auth = AuthenticationResult.WrongCredentials;
                    System.Console.WriteLine(msg.Password);
                    System.Console.WriteLine(account.NewCryptPassword);

Does not show anything when trying to log the box in.
 

Irian

Page
Then - I think - you don't connect at all. Are you sure, the server address in your Pandora's Box Options is correct? Use 127.0.0.1 to connect to a server on the same computer. What did you use? Is the Accountname correct?
 

endwolf

Sorceror
Yes

I use all the correct IP (127.0.0.1) and username and passwords....even updated the password in the box with SHA1 checked....used all the fixes placed above. I'll try reinstalling the box and re doing the above files :D
 

Irian

Page
The most likly reason is - imho - that you didn't copy the modified BoxServer.dll (from the .zip file) into the RunUO main folder. The "original" one tries to use the zlib.dll - but in RunUO 2.0 there's only Zlib32.dll and Zlib64.dll. The recompiled BoxServer.dll uses the Zlib32.dll
 
also - this is stupid, but i found that it needs to be done this way

look in the server setting in pandora - make sure it has the right port number in there

what i have found is if you just type the number in - it does not retain it

what you need to do is to type in the number 1 lower (8034) and then use the arrow key to increment it up by one - then it retains it
or what ever your port number is for it

-----------

Thanks for the map fix - i am going to install it now ;)
 
Top