Repository navigation
RSA Decryption Fails Using 'Record' App with latest client version #47
Description
Activity
Testing
Recordapp onparty-huntbranch throws this error when selecting a character from the character list:ERROR Org.BouncyCastle.Crypto.DataLengthException: input too large for RSA cipher. at Org.BouncyCastle.Crypto.Engines.RsaCoreEngine.ConvertInput(Byte[] inBuf, Int32 inOff, Int32 inLen) in /_/crypto/src/crypto/engines/RSACoreEngine.cs:line 101 at Org.BouncyCastle.Crypto.Engines.RsaEngine.ProcessBlock(Byte[] inBuf, Int32 inOff, Int32 inLen) in /_/crypto/src/crypto/engines/RsaEngine.cs:line 81 at OXGaming.TibiaAPI.Network.Rsa.ProcessBlock(NetworkMessage message, Int32 index, RsaEngine engine) in /home/dev/Documents/TibiaAPI/TibiaAPI/Network/Rsa.cs:line 104 at OXGaming.TibiaAPI.Network.Rsa.OpenTibiaDecrypt(NetworkMessage message, Int32 index) in /home/dev/Documents/TibiaAPI/TibiaAPI/Network/Rsa.cs:line 62 at OXGaming.TibiaAPI.Network.Connection.BeginReceiveClientCallback(IAsyncResult ar) in /home/dev/Documents/TibiaAPI/TibiaAPI/Network/Connection.cs:line 797 ERROR Data: 9D 00 00 00 00 00 0A 07 00 E7 04 E7 04 00 00 0B 00 31 32 2E 35 35 2E 31 30 34 35 34 DA 67 01 BA 02 41 67 2F C2 58 BD 14 95 58 59 CA B8 31 F4 6A AB CD 50 83 56 34 14 10 D4 C0 52 A1 54 50 3D 5E 4D AA 58 C9 3D 07 2E D4 C2 09 C6 CB 2A 16 8B 0A F7 41 8C 45 B6 8E D8 BC FE 6C 35 3D 3E 66 83 9A 3C 27 9A 34 C4 BD 22 53 83 D8 8D D9 8D 27 39 5D 39 5B EC 09 F2 A1 98 F3 C7 3A D4 49 9A 41 B2 A0 0D 6F F4 58 7A CC 68 25 BB 70 6B 40 BC 15 98 42 8A 69 38 55 52 45 59 EE F0 60 EB 71 66 30 69They dont support 12.55, stoppeds work on 12.51. new packets.
I see. That's a shame. But I can imagine the amount of work this project required was probably formidable. Thank you for the heads-up!
@GPRicci thanks for the report. Unless someone else submits a PR before me, it may be some time before I update it for the latest update as I am quite busy IRL.
Thank you for your answer, Joe! It's ok. RL comes first. I wish I had the knowledge to colaborate with an update.
@GPRicci I managed to make it work with client version 12.66.10792 (latest)
It seems like you did not change the RSA key to use the Open Tibia RSA..
Even though you are connecting to the official Tibia™, you still need to change the RSA Key because it's an asymmetric cryptography. So the tool can encrypt using the Tibia™ RSA, but it can't decrypt. If it's not able to decrypt, it's not able to store it in the.oxrfile.
I've just started checking out this API, so I'm not too sure on how to proceed with this error.
I ran the 'Record' app, then started the client (loginWebService modified to http://127.0.0.1:7171/).
I get my character list without issues, however when I try to connect to the game world with a character the following error pops up in the console:
I'm logging in to official Tibia servers using the official and latest client. Perhaps something changed in the latest version regarding the encryption of packets? RSA key changed?
Thank you beforehand.