mi5hmash / LimebrellaSharp

Unpack, Pack & Resign files encrypted with the 1st version of "Lime" encryption.
The Unlicense
27 stars 2 forks source link

Can this tool work on Dragon's Dogma 2? #8

Open barlowhaydnb opened 8 months ago

barlowhaydnb commented 8 months ago

I've tried several times but it doensn't seem working. The game created new saves after I copied the resigned saves to steam folder.

mi5hmash commented 8 months ago

Hi @barlowhaydnb. I haven't seen the save files for this game, so I can't assess their compatibility. To be honest, I am not interested in playing this game, so I will not buy it or invest my time in supporting it in any way.

barlowhaydnb commented 8 months ago

@mi5hmash I see, that's such a shame, it is a great game. Thank you anyway

LennardF1989 commented 8 months ago

Thank you for your research on this @mi5hmash - From the looks of it, DD2 does also use Lime, just with different private keys.

Running it through IDA now to have a deeper look. Any tips on how you eventually found these offsets, saves me from reinventing the wheel!

insomnious commented 8 months ago

+1 for the research. I'm also attempting to check this out as it's very close for DD2 but not quite. I'd never heard of Lime until I stumbled across this repo.

mi5hmash commented 8 months ago

Hi @LennardF1989, I did it with the Cheat Engine. First, I found the SaveEncryptionType offset - during the game start-up, its value changes from 0x01 to 0x10. Then I found what accesses this address - a switch statement was what I was looking for. One of the subroutines was the one where the Lime magic was happening. There, I found that the program performs the NOT operation on SteamID bytes. It was worth examining the calls after that operation as the SteamID is used to calculate a final encryption key. Keys that I named "private keys" were among subroutines parameters.

insomnious commented 8 months ago

@LennardF1989 I'm out of office until next week but happy to collaborate if you'd like to share efforts. Thanks again @mi5hmash

mi5hmash commented 8 months ago

@insomnious, @LennardF1989, If you have Discord you can PM me there.