Go Back   RunUO - Ultima Online Emulation > RunUO > Custom Script Releases

Custom Script Releases This forum is where you can release your custom scripts for other users to use.

Please note: By releasing your scripts here you are submitting them to the public and as such agree to make them public domain. The RunUO Team has made its software GPL for you to use and enjoy you should do the same for anything based off of RunUO.

Reply
 
Thread Tools Display Modes
Old 07-11-2006, 09:38 AM   #1 (permalink)
Forum Expert
 
Join Date: May 2005
Age: 29
Posts: 949
Default [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".
Attached Files
File Type: zip BoxServer.zip (42.1 KB, 1870 views)
File Type: zip Pandora.zip (412.0 KB, 2595 views)
File Type: zip ServerOptions.zip (1.1 KB, 1328 views)

Last edited by Irian; 01-21-2007 at 07:16 AM. Reason: Added Bugfix for RunUO 2 < SVN 67
Irian is offline   Reply With Quote
Old 07-11-2006, 12:54 PM   #2 (permalink)
Forum Expert
 
Join Date: May 2005
Age: 29
Posts: 949
Default

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.
Irian is offline   Reply With Quote
Old 07-11-2006, 02:39 PM   #3 (permalink)
Account Terminated
 
Icon's Avatar
 
Join Date: Aug 2003
Location: North Carolina
Age: 36
Posts: 390
Send a message via MSN to Icon
Default

Is there a link or a recompiled version of PB2 to work on the .net 2.0?

Thanks

Hk
Icon is offline   Reply With Quote
Old 07-11-2006, 03:13 PM   #4 (permalink)
Forum Expert
 
Join Date: May 2005
Age: 29
Posts: 949
Default

I think, Pandora compiles fine with .Net 2.0 (some warnings, ok, but ne errors, iirc).
Irian is offline   Reply With Quote
Old 07-11-2006, 07:37 PM   #5 (permalink)
Account Terminated
 
Icon's Avatar
 
Join Date: Aug 2003
Location: North Carolina
Age: 36
Posts: 390
Send a message via MSN to Icon
Default

Quote:
Originally Posted by Irian
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
Icon is offline   Reply With Quote
Old 07-11-2006, 08:42 PM   #6 (permalink)
Forum Novice
 
Midnightdragon's Avatar
 
Join Date: Jun 2006
Age: 29
Posts: 615
Default

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.
Midnightdragon is offline   Reply With Quote
Old 07-11-2006, 08:57 PM   #7 (permalink)
Newbie
 
ratzerna's Avatar
 
Join Date: Nov 2003
Location: Where ducks live in VA
Age: 42
Posts: 55
Default

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.
ratzerna is offline   Reply With Quote
Old 07-11-2006, 10:00 PM   #8 (permalink)
Forum Master
 
Lord_Greywolf's Avatar
 
Join Date: Dec 2005
Posts: 6,764
Send a message via Yahoo to Lord_Greywolf
Default

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
__________________
http://www.AoAUO.com

:) ..... Come for the Customs, Play for the Fun. Return to see your new Friends ..... :)
Lord_Greywolf is offline   Reply With Quote
Old 07-11-2006, 11:52 PM   #9 (permalink)
Forum Expert
 
Join Date: Dec 2003
Location: Sitting in a chair fulfilling my life's goal
Age: 22
Posts: 2,650
Send a message via AIM to Killamus Send a message via MSN to Killamus
Default

Okay, I did a search and came up with nothing. What does this do?
__________________
Procrastinators unite!
Tomorrow.
Saying that Java is nice because it works on all OS's is like saying that anal sex is nice because it works on all genders.
Killamus is offline   Reply With Quote
Old 07-12-2006, 12:35 AM   #10 (permalink)
Forum Master
 
Lord_Greywolf's Avatar
 
Join Date: Dec 2005
Posts: 6,764
Send a message via Yahoo to Lord_Greywolf
Default

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)
__________________
http://www.AoAUO.com

:) ..... Come for the Customs, Play for the Fun. Return to see your new Friends ..... :)
Lord_Greywolf is offline   Reply With Quote
Old 07-12-2006, 12:40 AM   #11 (permalink)
Forum Expert
 
Erica's Avatar
 
Join Date: Jan 2005
Location: Laramie Wyoming
Age: 43
Posts: 1,279
Send a message via ICQ to Erica Send a message via AIM to Erica Send a message via MSN to Erica Send a message via Yahoo to Erica Send a message via Skype™ to Erica
Default

Quote:
Originally Posted by Lord_Greywolf
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 ?
__________________
Erica is offline   Reply With Quote
Old 07-12-2006, 12:42 AM   #12 (permalink)
Forum Expert
 
Raider's Avatar
 
Join Date: Jan 2005
Age: 31
Posts: 288
Send a message via Yahoo to Raider
Default

Ok im going to try this hopefully it will work with 2.0 svn 64 .
__________________
Raider is offline   Reply With Quote
Old 07-12-2006, 02:33 AM   #13 (permalink)
Forum Expert
 
Join Date: May 2005
Age: 29
Posts: 949
Default

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 is offline   Reply With Quote
Old 07-12-2006, 02:45 AM   #14 (permalink)
Newbie
 
endwolf's Avatar
 
Join Date: Jul 2004
Location: Louisiana
Age: 39
Posts: 74
Talking Grrrr

I did all the above it compiled, but it won't log in...any Ideas?
endwolf is offline   Reply With Quote
Old 07-12-2006, 02:53 AM   #15 (permalink)
Forum Expert
 
Join Date: May 2005
Age: 29
Posts: 949
Default

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 :-).

Last edited by Irian; 07-12-2006 at 02:55 AM.
Irian is offline   Reply With Quote
Old 07-12-2006, 03:20 AM   #16 (permalink)
Newbie
 
endwolf's Avatar
 
Join Date: Jul 2004
Location: Louisiana
Age: 39
Posts: 74
Default 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.
endwolf is offline   Reply With Quote
Old 07-12-2006, 03:24 AM   #17 (permalink)
Forum Expert
 
Join Date: May 2005
Age: 29
Posts: 949
Default

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?
Irian is offline   Reply With Quote
Old 07-12-2006, 03:36 AM   #18 (permalink)
Newbie
 
endwolf's Avatar
 
Join Date: Jul 2004
Location: Louisiana
Age: 39
Posts: 74
Default 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
endwolf is offline   Reply With Quote
Old 07-12-2006, 03:58 AM   #19 (permalink)
Forum Expert
 
Join Date: May 2005
Age: 29
Posts: 949
Default

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

Last edited by Irian; 07-12-2006 at 04:02 AM.
Irian is offline   Reply With Quote
Old 07-12-2006, 11:07 AM   #20 (permalink)
Forum Master
 
Lord_Greywolf's Avatar
 
Join Date: Dec 2005
Posts: 6,764
Send a message via Yahoo to Lord_Greywolf
Default

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
__________________
http://www.AoAUO.com

:) ..... Come for the Customs, Play for the Fun. Return to see your new Friends ..... :)
Lord_Greywolf is offline   Reply With Quote
Old 07-15-2006, 12:46 AM   #21 (permalink)
Newbie
 
endwolf's Avatar
 
Join Date: Jul 2004
Location: Louisiana
Age: 39
Posts: 74
Default Sorry lost con

Here is the warning the server gives me

Warnings:
+ Core/BoxServer.cs:
CS0618: Line 41: 'System.Runtime.Remoting.Channels.ChannelServices. RegisterC
hannel(System.Runtime.Remoting.Channels.IChannel)' is obsolete: 'Use System.Runt
ime.Remoting.ChannelServices.RegisterChannel(IChan nel chnl, bool ensureSecurity)
instead.'
endwolf is offline   Reply With Quote
Old 07-15-2006, 01:39 AM   #22 (permalink)
Forum Master
 
Lord_Greywolf's Avatar
 
Join Date: Dec 2005
Posts: 6,764
Send a message via Yahoo to Lord_Greywolf
Default

i get the same warning

but it is working fine for me - i can log in and use the box server with no problem, and so has many of my gm's - only one had a problem and he was using windows xp firewall, so he is going to try it again tomorrow with out it running, otherwise - it just would not connect for him - no error or anything - just did not connect
__________________
http://www.AoAUO.com

:) ..... Come for the Customs, Play for the Fun. Return to see your new Friends ..... :)
Lord_Greywolf is offline   Reply With Quote
Old 07-15-2006, 05:59 AM   #23 (permalink)
Forum Expert
 
Join Date: May 2005
Age: 29
Posts: 949
Default

This is just a warning, it should not stop the Boxserver from working (it just means: You're using rather old methods, pal). I will correct it, when I find the time, the only problem with putting everything toegether is, that I'm not sure if I get the installers to work.
Irian is offline   Reply With Quote
Old 07-17-2006, 01:35 AM   #24 (permalink)
Forum Novice
 
penndragon's Avatar
 
Join Date: Apr 2004
Location: Tennessee
Age: 41
Posts: 119
Send a message via Yahoo to penndragon
Default Login from outside........

Quick question... I am running on a local machine and can login fine to the box server with 127.0.0.1 but the GM's canot login at all. The box comes up and says connecting (on their screen) and the purple bar just continues to run and it never connects. Do they also have to make the changes to their system (install .NET 2.0 and use the modified Pandora.exe) or could it be another problem. We have doublechecked the IP and port settings along with Name and Pass. We have also tried both SHA1 and normal.
__________________
The only stupid question is the one not asked........ Just don't ask me..... I don't know either........ :D
penndragon is offline   Reply With Quote
Old 07-17-2006, 04:50 AM   #25 (permalink)
Forum Expert
 
Join Date: May 2005
Age: 29
Posts: 949
Default

Yes, they must. Perhaos you are using a router/firewall? Is the BoxServer Port open?
Irian is offline   Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools