-

Extraction and unpacking of game archives and compression, encryption, obfuscation, decoding of unknown files
lemurboy12
Posts: 265
Joined: Fri Oct 17, 2014 2:57 am

Re: LittleBigPlanet 3 .FARC

Post by lemurboy12 »

We just tried extracting from the LittleBigPlanet 1 beta, but it didn't work.

http://puu.sh/gKm8z.zip
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: LittleBigPlanet 3 .FARC

Post by aluigi »

I guess you have an old version of the script/quickbms because here it works perfectly.
lemurboy12
Posts: 265
Joined: Fri Oct 17, 2014 2:57 am

Re: LittleBigPlanet 3 .FARC

Post by lemurboy12 »

oh, nevermind then
Miles2345
Posts: 76
Joined: Thu Oct 16, 2014 3:05 am

Re: LittleBigPlanet 3 .FARC

Post by Miles2345 »

Maybe, do you think it would somehow be possible / is it already possible to somehow regenerate a hash for certain files, so they could be reimported fine and then tweaked in the .map so the hash will match up?
Miles2345
Posts: 76
Joined: Thu Oct 16, 2014 3:05 am

Re: LittleBigPlanet 3 .FARC

Post by Miles2345 »

I just found this, but I do have a question, what are the eight bytes before and six bytes after the SHA1 hash? (LBP3)
http://puu.sh/h3PO6.png
Miles2345
Posts: 76
Joined: Thu Oct 16, 2014 3:05 am

Re: LittleBigPlanet 3 .FARC

Post by Miles2345 »

Nevermind, got it sorted out.
Miles2345
Posts: 76
Joined: Thu Oct 16, 2014 3:05 am

Re: LittleBigPlanet 3 .FARC

Post by Miles2345 »

Sorry to bother you with this game again but I had a question.

I need a way to turn whatever file I decompressed with offzip back into the format the game uses. Is this possible and how difficult would it be to do?

From there I can generate a SHA1 hash/fix blurayguids.map myself as well as manually inject it back into the farc file, that's not an issue. I only need to recompress it.

http://puu.sh/hhLVU.bin Here's a file in its original state and
http://puu.sh/hhLWs.dat here's the same file decompressed with offzip.
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: LittleBigPlanet 3 .FARC

Post by aluigi »

It's a chunk-based format so, even if I write a script (easy), you will not be able to reimport it.
Miles2345
Posts: 76
Joined: Thu Oct 16, 2014 3:05 am

Re: LittleBigPlanet 3 .FARC

Post by Miles2345 »

Why's that exactly? I think I understand how reinserting it in a farc would work, I would just replace another file, I wouldn't need a script for that. I just need to compress it again and that's all.
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: LittleBigPlanet 3 .FARC

Post by aluigi »

You can use packzip to recompress but the problem is that it's splitted in chunks of 32768 bytes.
If you dump the chunks as single files you can reimport them without problems (quickbms with script or packzip) but it's not the correct way:

Code: Select all

endian big
idstring "LVLb"
get DUMMY long
get DUMMY long
get DUMMY long
get CHUNKS byte

savepos TMP
xmath OFFSET "TMP + (CHUNKS * (2 + 2))"

for i = 0 < CHUNKS
    get ZSIZE short
    get SIZE short
    clog "" OFFSET ZSIZE SIZE
    math OFFSET + ZSIZE
next i