This script will allow you to support unmodified clients.
A README file is included in the zip and also an utility to automatically extract the encryption keys from a client.
The script and the program are released under the GPL.
No core modifications are required yet. But because of an upcoming change in the official core (PacketEncoder will be changed from a static to an instance member), i am planning to modify the script accordingly and make the 2-line change to the core public. (Since it will improve the performance significantly).
Currently there is only one issue known to me:
Encryption contexts will not be cleaned up correctly if a NetState is disconnected. There is no reliable callback for a disconnecting socket, so it's only possible with some sort of manual garbage collection. It is highly likely though, that certain Contexts will be reused since i use the OS Socket handle as the key to identify the context.
This issue will resolve itself with the next version of the core or the 2 line core mod mentioned above.
NOTE ON VERSION 2.0:I added the encryption keys for clients 3.0.5 trough 5.0.1 to the configuration. If you find any errors please report them here.
Version 2 requires you to modify your core if you are using RunUO 1.0. Information on how this can be done and also a precompiled version of RunUO 1.0 with the change can be found here:
http://www.runuo.com/forum/showthread.php?p=463268The change allows the encryption to store its context information directly with the NetState instead of a Hashtable. That increases performance and also removes the problem of cleaning up the hashtable when a NetState disconnects. The change has been accepted into the next official RunUO version. Version 2.0 of this script should work with an unmodded RunUO 2.0 once it's out.
cu,
darkstorm