Jump to content
  • 0
Sign in to follow this  
Helena

How to decipher this string?

Question

Hi.

 

This may not be the right section but I'm not sure where else to ask. I'm using the erods database site and I notice that upon adding content through SQL, there is a huge string requires to be read. I am talking about this (bold part):

 

INSERT INTO `item_db_en_uk` VALUES ('5013', 'Horn_Of_Lord_Kaho', 'Lord Kaho's Horn', '5', '20', null, '100', null, '5', null, '0', '4294967295', '7', '2', '256', null, '0', '1', '99', ' bonus bMdef,10; bonus bStr,5; bonus bAgi,10; bonus bVit,10; bonus bInt,5; bonus bLuk,20; ', null, null, 0x789C8590416B83301886EF85FD871776F0B062EB400AC509D2DAD5B5DB61B3EB39EAA70682491357F0DF377643687730A72F79DE27096F04A328E74CA0265654C434724DACA5E217943C67427428A5C65EEA023B564BB8AE8B632DE94CDA7AE0C67D980499C62C9C7CA59F78823F45F291F6C300BE937EEFCDA7885E93EB34A0FD61670F9E2D7A5FC79B5BB612CC182C03A35803D376825E9C5C0AA997785C5C971362FBF7F760D6C7C2415E53498DA131DDBFF7E2D30F57CA76209B31F76073FFDE3D12AFEA764CF5E6F75EA494B0856782F026B3313FB6F5777D70B8E602B59D866E, null, null, 'N;');

 

That big string, somehow and surprisingly, translates into this:

 

A special headgear created specifically for Lord Kaho ... Whoever he is. 
STR + 5, INT + 5 
VIT + 10, AGI + 10 
LUK + 20, MDEF + 10 
Class : Headgear 
Defense : 5 
Equipped on : Upper 
Weight : 10 
Applicable Job : Every Job

 

Does anyone know what this is? Hex? MD5, SHA1? -- I've been browsing the net now for hours but any translation site leaves me without result. If anyone can point me in the right direction, please. >.<

Share this post


Link to post
Share on other sites

4 answers to this question

Recommended Posts

  • 0

Thanks! 

 

I managed to find a site that's able to decompress these strings to exactly that. This is the site: http://i-tools.org/gzip

Unfortunately, it seems impossible to turn text back into a similar (numeric) string, when I attempt to use that site to compress it gives me this format which SQL can not read:

 

0+UdAjhuzN۩

&&uo

9

$L|E g9FL#JJ_ B&5RرqsIn~ύ5^wlEC.aݘNF7jO~V

fQ)+Aa"sg~wǼ^QF.+e7!.ls훯oyN'-WJǂq׀~CUsn

 

If there is another tool out there to achieve a correct numeric translation (like in the query), I'd love to see it. Sadly i had no luck thus far.

 

You won't find such a tool because it makes no sense to show a string like that. Also, gzip is not the same as zlib (they do share many similarities though!). Anyway, if you have .net 3.5 or more recent installed, you could use that (attached file), should be pretty straightforward to use :

 

xdaBSe6.png

Zlib Compression.zip

Share this post


Link to post
Share on other sites
  • 0

IDK where you've got this database entry, but it's plain ridiculous. It's some sort of text, encoded as an hexadecimal string (hence the 0x starting value and numbers ranging from 0-9 and A-F) with some sort of ciphering method. But who the heck would ever decide on his sanity to encode long texts into an absurdly big int number and represent them as hexadecimal strings?

 

Could be possible for someone else than me (not sure), to know how to decipher these strings provided we know the source that translates that to human readable strings.

Share this post


Link to post
Share on other sites
  • 0

It's not encrypted, it's compressed. The 0x78 0x9c is a typical zlib header for compressed streams. Before I keep going though, I'd like to mention that... if this is indeed passed as a string rather than a byte array, then... it's actually a horribly bad idea. You lose the gain of the compression and creates a useless overhead, so basically this whole string is a pure waste of time for everyone lol, but yeah let's move on!

 

I used my own libraries to 'decrypt' it, but I'm sure you can find a zlib library yourself quite easily (isn't there already one provided in the 3rdparty folder of Hercules?).

string stringData = "789C8590416B83301886EF85FD871776F0B062EB400AC509D2DAD5B5DB61B3EB39EAA70682491357F0DF377643687730A72F79DE27096F04A328E74CA0265654C434724DACA5E217943C67427428A5C65EEA023B564BB8AE8B632DE94CDA7AE0C67D980499C62C9C7CA59F78823F45F291F6C300BE937EEFCDA7885E93EB34A0FD61670F9E2D7A5FC79B5BB612CC182C03A35803D376825E9C5C0AA997785C5C971362FBF7F760D6C7C2415E53498DA131DDBFF7E2D30F57CA76209B31F76073FFDE3D12AFEA764CF5E6F75EA494B0856782F026B3313FB6F5777D70B8E602B59D866E";byte[] byteData = Methods.StringToByteArray(stringData);byte[] uncompressedData = GRF.Core.Compression.DecompressZlib(byteData);string output = Utilities.Services.EncodingService.Ansi.GetString(uncompressedData);

 

Which gives you : 

A special headgear created specifically for Lord Kaho ... Whoever he is.<br />STR + 5, INT + 5<br />VIT + 10, AGI + 10<br />LUK + 20, MDEF + 10<br />Class :<span style='color: #777777'> Headgear</span><br />Defense :<span style='color: #777777'> 5</span><br />Equipped on :<span style='color: #777777'> Upper</span><br />Weight :<span style='color: #777777'> 10</span><br />Applicable Job :<span style='color: #777777'> Every Job</span>

Good luck!

Edited by Tokeiburu

Share this post


Link to post
Share on other sites
  • 0

It's not encrypted, it's compressed. The 0x78 0x9c is a typical zlib header for compressed streams. Before I keep going though, I'd like to mention that... if this is indeed passed as a string rather than a byte array, then... it's actually a horribly bad idea. You lose the gain of the compression and creates a useless overhead, so basically this whole string is a pure waste of time for everyone lol, but yeah let's move on!

 

I used my own libraries to 'decrypt' it, but I'm sure you can find a zlib library yourself quite easily (isn't there already one provided in the 3rdparty folder of Hercules?).

string stringData = "789C8590416B83301886EF85FD871776F0B062EB400AC509D2DAD5B5DB61B3EB39EAA70682491357F0DF377643687730A72F79DE27096F04A328E74CA0265654C434724DACA5E217943C67427428A5C65EEA023B564BB8AE8B632DE94CDA7AE0C67D980499C62C9C7CA59F78823F45F291F6C300BE937EEFCDA7885E93EB34A0FD61670F9E2D7A5FC79B5BB612CC182C03A35803D376825E9C5C0AA997785C5C971362FBF7F760D6C7C2415E53498DA131DDBFF7E2D30F57CA76209B31F76073FFDE3D12AFEA764CF5E6F75EA494B0856782F026B3313FB6F5777D70B8E602B59D866E";byte[] byteData = Methods.StringToByteArray(stringData);byte[] uncompressedData = GRF.Core.Compression.DecompressZlib(byteData);string output = Utilities.Services.EncodingService.Ansi.GetString(uncompressedData);

 

Which gives you : 

A special headgear created specifically for Lord Kaho ... Whoever he is.<br />STR + 5, INT + 5<br />VIT + 10, AGI + 10<br />LUK + 20, MDEF + 10<br />Class :<span style='color: #777777'> Headgear</span><br />Defense :<span style='color: #777777'> 5</span><br />Equipped on :<span style='color: #777777'> Upper</span><br />Weight :<span style='color: #777777'> 10</span><br />Applicable Job :<span style='color: #777777'> Every Job</span>

Good luck!

 

Thanks! 

 

I managed to find a site that's able to decompress these strings to exactly that. This is the site: http://i-tools.org/gzip

Unfortunately, it seems impossible to turn text back into a similar (numeric) string, when I attempt to use that site to compress it gives me this format which SQL can not read:

 

0+UdAjhuzN۩
&&uo
9
$L|E g9FL#JJ_ B&5RرqsIn~ύ5^wlEC.aݘNF7jO~V
fQ)+Aa"sg~wǼ^QF.+e7!.ls훯oyN'-WJǂq׀~CUsn
 
If there is another tool out there to achieve a correct numeric translation (like in the query), I'd love to see it. Sadly i had no luck thus far.
Edited by Helena

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.