ZenHAX

Free Game Research Forum | Official QuickBMS support | twitter @zenhax
It is currently Sat Aug 13, 2022 3:20 am

All times are UTC




Post new topic  Reply to topic  [ 6 posts ] 
Author Message
 Post subject: JustCause 1 CRC/Hashing
PostPosted: Mon Jun 07, 2021 8:42 pm 

Joined: Mon Jun 07, 2021 8:20 pm
Posts: 33
Wanted a help in research JustCause 1 CRC or Hash algo.

JustCause 2 using jenkins_hashlittle, but seems like JustCause 1 are not. CRC_scan can't help figure out the algo. Hashes only filename in lower case.

In attach I provide a test script for compare values in the pc.tab file with quickbms generated. Pc.list file it's a sorted by hash pclist.txt from JustCause Demo.


Attachments:
JustCauseDemo_HashTest.zip [150.65 KiB]
Downloaded 154 times
Top
   
PostPosted: Fri Oct 29, 2021 5:40 pm 

Joined: Sat Aug 09, 2014 2:34 pm
Posts: 1346
It's SHA1, first 4 bytes it's hash

Example:

Code:
0A 90 34 90 DB 9A 1F 36 9D 46 34 15 BC 23 1A 7E 45 90 C4 C4 - keymap_pc_default.bin

0x9034900A -> keymap_pc_default.bin


if you interested here my repo https://github.com/Ekey/JC.ARC.Tool/ with code :)


Top
   
PostPosted: Sun Nov 14, 2021 7:54 pm 

Joined: Mon Jun 07, 2021 8:20 pm
Posts: 33
I didn't even think what can be used only first bytes of SHA1 or other long hashes )

Thanks.
Remains parse all files of retail version of game to get filename strings.


Top
   
PostPosted: Mon Nov 15, 2021 6:03 pm 

Joined: Sat Aug 09, 2014 2:34 pm
Posts: 1346
You can check my small list with names > https://github.com/Ekey/JC.ARC.Tool/tre ... r/Projects


Top
   
PostPosted: Mon Nov 15, 2021 6:23 pm 

Joined: Mon Jun 07, 2021 8:20 pm
Posts: 33
JustCause Demo contain pclist.txt with all 3650 filename strings stored in demo *.arc file. In retail version part of files should be same. Some names of other part can be digged from Small Archives, which have "SARC" in header. These archives sometimes contain a debug path string of source file.

Here uses non-standard SHA1? All checksum generators gives another result:
Code:
fd c9 27 2e 21 88 01 09 3c 91 88 2d a1 3f ee ba 62 86 04 bc - keymap_pc_default.bin


Top
   
PostPosted: Tue Nov 16, 2021 9:14 pm 

Joined: Sat Aug 09, 2014 2:34 pm
Posts: 1346
grandshot wrote:
Here uses non-standard SHA1? All checksum generators gives another result:
Code:
fd c9 27 2e 21 88 01 09 3c 91 88 2d a1 3f ee ba 62 86 04 bc - keymap_pc_default.bin

They using SHA1 (Steve Reid version) with big-endian byte order and you need allocate 128 bytes for each string. Anyway you can check this part of hashing code :)


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 6 posts ] 

All times are UTC


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Limited