Important information: this site is currently scheduled to go offline indefinitely by end of the year.

Kingdom Hearts 1.5 remix .mself

The Original Forum. Game archives, full of resources. How to open them? Get help here.
peronmls
advanced
Posts: 55
Joined: Tue Oct 04, 2011 11:21 pm
Has thanked: 6 times

Re: Kingdom Hearts 1.5 remix .mself

Post by peronmls »

BUMP (:
GovanifY
advanced
Posts: 59
Joined: Wed Apr 16, 2014 9:25 pm
Location: In the depths of a game...
Has thanked: 1 time
Been thanked: 33 times
Contact:

Re: Kingdom Hearts 1.5 remix .mself

Post by GovanifY »

Well, I have 2/3 things to say.
First, the mself format isn't complicated at all. For completing the bms script, keytotruth(or truthkey) added on github an extractor, ya can check it here: https://github.com/Truthkey/KH_1.5_MSELF_EXTRACTOR
Btw, stupid anecdote but I learned to truthkey how to use github :p proof: http://puu.sh/8brBp.png. I sended this pic' to him: http://image.noelshack.com/fichiers/201 ... ed-git.png (ya, url b\c it will take all the screen).

Anyways, all files are encrypted using the SDATA v4 encryption, created by $0ny. All files are encrypted on AES-CBC-256. The decryption key is that: 0D655EF8E674A98AB8505CFA7D012933

So why can't we just decrypt those files? Well there's another thing: a compression. I studied a little bit him a while ago and got a compression/decompression algo reversed from the ps3 sdk. For everyone who wants them they are available here: http://pastebin.com/rYdQPmBx and http://pastebin.com/nw3R4RsJ
I never studied too much 1.5, I'm more on KH2FM. I'm just posting that for everyone who wants to know exactly how is 1.5

Bye!, GovanifY

EDIT: Since I found the compression used by the SDATA algorithm was a variant of the LZRC one, I just wanted to make a quick soft that can decrypt and decompress those file. I can thx IDA Pro and my old pastebin, they were usefull^^

Here's the link: http://www.govanify.x10host.com/_files/SDATA_DEC.exe
Good romhacking ;)
The only limit I've encountered so far is my brain.

-----------------------------------------------
Ya can check my work here:
http://www.govanify.blogspot.fr
http://www.govanify.com
https://twitter.com/GovanifY
fadedsoulz
n00b
Posts: 14
Joined: Thu Jul 01, 2010 8:46 pm
Has thanked: 1 time

Re: Kingdom Hearts 1.5 remix .mself

Post by fadedsoulz »

I just took a look at the mself files from KH 2.5 Remix. It seems like the sdat file names are scrambled. Do you think we could get file names for the files?
"b4c65e127b71abaf.sdat" is one of the file names from kingdom2.mself

-
Edit: there seems to be an index.dat for each folder that contains an .mself. Maybe that can help with the file names?
Devilot
ultra-veteran
ultra-veteran
Posts: 443
Joined: Tue Sep 07, 2010 10:12 am
Has thanked: 159 times
Been thanked: 49 times

Re: Kingdom Hearts 1.5 remix .mself

Post by Devilot »

from the japanese version?
fadedsoulz
n00b
Posts: 14
Joined: Thu Jul 01, 2010 8:46 pm
Has thanked: 1 time

Re: Kingdom Hearts 1.5 remix .mself

Post by fadedsoulz »

Devilot wrote:from the japanese version?
Yeah.. I've been looking through the files since it was released. Falo's mself script seems to be working for the new files, but I'm concerned with some of the sdat files. When I decrypted an sdat that was a TIM2 file, the header seemed to be off. I had to trim the first 16 bytes for Noesis to recognize it. I'm also having trouble with the "mlds" script for the larger files from "kingdom2.mself". The format for the files containing gtf textures seems to be similar, but I'm unable to extract anything from the archive. Either the offset is wrong or the SDAT decryption is off. I've been using Govanify's sdat tool instead of using the PS3 to decrypt, so that could have made a difference. Anyway, I'm hoping that there will be more progress on this release compared to 1.5.
mysis
n00b
Posts: 17
Joined: Thu Aug 14, 2014 11:45 am
Been thanked: 12 times

Re: Kingdom Hearts 1.5 remix .mself

Post by mysis »

you might want to use the npdtool by belmondo and user ©2014 to decrypt the sdat-files. its perfectly working.

http://www.psdevwiki.com/ps3/Dev_Tools#NPDTool_v4d
PS3 DevWiki : http://www.psdevwiki.com/ps3/Main_Page
Irc Channel : [url]irc://efnet/ps3dev[/url]

Visit my Blog: http://syscallm.blogspot.de/
Devilot
ultra-veteran
ultra-veteran
Posts: 443
Joined: Tue Sep 07, 2010 10:12 am
Has thanked: 159 times
Been thanked: 49 times

Re: Kingdom Hearts 1.5 remix .mself

Post by Devilot »

if you succeed, can you post them?
Namichan
ultra-n00b
Posts: 2
Joined: Sat May 07, 2011 7:41 pm

Re: Kingdom Hearts 1.5 remix .mself

Post by Namichan »

-
Last edited by Namichan on Sat Mar 04, 2023 4:07 pm, edited 2 times in total.
mysis
n00b
Posts: 17
Joined: Thu Aug 14, 2014 11:45 am
Been thanked: 12 times

Re: Kingdom Hearts 1.5 remix .mself

Post by mysis »

Namichan wrote:Can anyone tell me if it is possible to extract the prerendered cutscenes/CGIs from the bbsmovie.mself and kh2movie.mself files with any of these tools/scripts?
I already tried to use the Nova Extractor, but that resulted in unplayabled swf files for me :[
the mself format is same as on kingdom hearts 1.5 hd remix.
the prerendered movies/cgi are in mp4 format. so after you extracted them from mself the next step would be to remove sdat encryption - doable with the npdtool i linked above.
PS3 DevWiki : http://www.psdevwiki.com/ps3/Main_Page
Irc Channel : [url]irc://efnet/ps3dev[/url]

Visit my Blog: http://syscallm.blogspot.de/
Namichan
ultra-n00b
Posts: 2
Joined: Sat May 07, 2011 7:41 pm

Re: Kingdom Hearts 1.5 remix .mself

Post by Namichan »

-
Last edited by Namichan on Sat Mar 04, 2023 4:12 pm, edited 1 time in total.
fadedsoulz
n00b
Posts: 14
Joined: Thu Jul 01, 2010 8:46 pm
Has thanked: 1 time

Re: Kingdom Hearts 1.5 remix .mself

Post by fadedsoulz »

mysis wrote:you might want to use the npdtool by belmondo and user ©2014 to decrypt the sdat-files. its perfectly working.

http://www.psdevwiki.com/ps3/Dev_Tools#NPDTool_v4d
Thanks for sharing! I originally tried an older version that didn't work with SDAT V4. It works fine on the .mp4 files but I'm not sure about the ones with the sdat compression. I'll test that later. Do you have any idea about the "index.dat" files in each folder that has an "mself"? In addition, could someone help out with the "model" format? I'm not sure what to call it since the file names are obfuscated, but I do know that SFX and textures are contained in the dat archives after decryption. If you need to post anything, let me know!
crazycatz
ultra-n00b
Posts: 5
Joined: Thu Apr 12, 2012 9:27 pm
Been thanked: 4 times

Re: Kingdom Hearts 1.5 remix .mself

Post by crazycatz »

Just going to dump what I know...
fadedsoulz wrote:Do you have any idea about the "index.dat" files in each folder that has an "mself"?
The index.dat contains a list of file hashes, their size, and an incrementing number:

Code: Select all

// Values are in big-endian
for each file:
    uint64 Hash
    uint32 Size
    uint32 File # in mself? (Starts at 0, increments by 1 for each file)
I know the game loads (or at least has code to load) this file when it loads the corresponding mself. I'm guessing it's used to load files without converting the hash to a string (as is stored in mself filenames).

---

All files seem to be wrapped in a common header, which is:

Code: Select all

// big-endian
uint   DataSize
uint   AdditionalFileCount
byte*8 Padding?
foreach additionalFile:
    byte*32 FileName
    uint    Absolute Offset
    uint    ?
    uint    Size
    uint    Padding?
byte*dataSize Data
foreach additionalFile:
    byte*Size Data
I've only tested this on models (?; the ones with the GTFs), but it should work for any file:

Code: Select all

# Square Enix - Kingdom Hearts HD 2.5 ReMix Models(?)
# by Crazycatz
# script for QuickBMS http://quickbms.aluigi.org

endian big

get Size LONG
get H_Files LONG
goto 8 0 SEEK_CUR

# xmath fails for me ~.~
math Offset = H_Files
math Offset *= 48
math Offset += 16
get Name BASENAME
string Name += ".bin"
log Name Offset Size

for i = 0x0 < H_Files
    GetDString Name 0x20
    get Offset LONG
    get Unknown LONG
    get Size LONG
    goto 4 0 SEEK_CUR
    log Name Offset Size
next i
Though most filetypes don't have any additionalFiles, so often times the first 16 bytes can just be removed.

---

Random notes:
  • Audio files have the signature "SEDBSSCF", and are mostly (all?) 192 kbps CBR MP3. (I can't play a few of them.)
    • bd21b6eb3dc3dc52 is a version of Dearly Beloved with interlaced channels or something.
  • The KH2 mself has BAR and IMD files, which are the format used in the PS2 version. I don't know if they're used, but they are in big-endian (PS2 was little-endian).
Azurfan
advanced
Posts: 61
Joined: Wed Jun 23, 2010 10:12 pm
Has thanked: 23 times
Been thanked: 3 times

Re: Kingdom Hearts 1.5 remix .mself

Post by Azurfan »

Thanks for the script crazycatz.
Last edited by Azurfan on Thu Oct 16, 2014 6:14 pm, edited 1 time in total.
crazycatz
ultra-n00b
Posts: 5
Joined: Thu Apr 12, 2012 9:27 pm
Been thanked: 4 times

Re: Kingdom Hearts 1.5 remix .mself

Post by crazycatz »

Quick update, I got the hashing algorithm and a program that can extract the MSELF with names.
http://crazycatz00.x10host.com/KH/files ... 25Tools.7z
(For the cautious, it's written in .NET, so Reflector or something can open.)

The hash method is actually MD5, but cut in half.
So "00battle.bin" has the MD5 "764d15394e82c389afdc883ed4ba8f5a" and 2.5 uses "764d15394e82c389". (Note that, because I was lazy and forgot, my program prints hashes in little endian, so it would say "89C3824E39154D76". It does work right otherwise though.)
Haevens
ultra-n00b
Posts: 3
Joined: Sun Jun 15, 2014 4:40 pm

Re: Kingdom Hearts 1.5 remix .mself

Post by Haevens »

@crazycatz
Is it possible to have the same for KH BBS?
because that the files no name comes out.
Post Reply