The Forum is up for sale: XeNTaX Forum looking for new owner

Ikaruga (.arc ) [PC]

The Original Forum. Game archives, full of resources. How to open them? Get help here.
Post Reply
mappy2012
advanced
Posts: 61
Joined: Sun Jul 03, 2011 4:40 am
Has thanked: 51 times
Been thanked: 1 time

Ikaruga (.arc ) [PC]

Post by mappy2012 »

Who can help with the extract the arc file?
Header: NARC
Samples:
http://www3.zippyshare.com/v/67612335/file.html
Ekey
M-M-M-Monster veteran
M-M-M-Monster veteran
Posts: 1822
Joined: Wed Mar 31, 2010 6:54 am
Has thanked: 92 times
Been thanked: 1056 times

Re: Ikaruga (.arc ) [PC]

Post by Ekey »

Encrypted with Blowfish
Ekey
M-M-M-Monster veteran
M-M-M-Monster veteran
Posts: 1822
Joined: Wed Mar 31, 2010 6:54 am
Has thanked: 92 times
Been thanked: 1056 times

Re: Ikaruga (.arc ) [PC]

Post by Ekey »

Code: Select all

struct ARCHeader
{
 	DWORD dwID;	// NARC
 	DWORD dwTotalFiles;
 	DWORD dwNamesSize;
 	DWORD dwTableSize;	// -0x10
};

struct ARCEntry
{
 	DWORD dwUnknown;	// 0x00000007
 	DWORD dwNameOffset;	// + dwTotalFiles * 0x14
 	DWORD dwOffset;	// dwTableSize + 0x10
 	DWORD dwSize;
 	DWORD dwMagicConstant;	// Constant for generate key
};

Table offset begin from 0x10 offset. Keys generating from magic constants

Code: Select all

0x3A4D6669 - "sdr.arc"
0x327648CF - "obj.arc"
0x30763DD9 - "snd.arc"
0x327648CF - "tex.arc"
0x067640D6 - "bin.arc"
Already generated keys for decrypt : only tables:

Code: Select all

static unsigned char pKey_bin[56] = {
       0xF5, 0x06, 0xEF, 0x0B, 0xA0, 0x71, 0x33, 0x35, 0x25, 0x89, 0xE3, 0x0D, 0xFC, 0x45, 0x2D,
       0x10, 0x51, 0x7A, 0x80, 0x02, 0xC6, 0x39, 0x03, 0x37, 0x71, 0x96, 0x91, 0x05, 0x74, 0x95,
       0xB8, 0x24, 0x8F, 0x73, 0x93, 0x27, 0xAC, 0x03, 0xD8, 0x20, 0x36, 0x84, 0xD7, 0x06, 0xAF,
       0x31, 0xB4, 0x3A, 0xF8, 0xC6, 0xE7, 0x27, 0x77, 0xB9, 0xBB, 0x05};
	   
static unsigned char pKey_obj[56] = {
       0xE6, 0xAE, 0x55, 0x2D, 0x1F, 0x54, 0x10, 0x30, 0x34, 0x14, 0x8B, 0x20, 0x8B, 0x15, 0x15,
       0x37, 0x8E, 0x73, 0x0C, 0x3D, 0x59, 0x9D, 0x34, 0x02, 0xF6, 0xF2, 0xA1, 0x1C, 0xAB, 0x1B,
       0x37, 0x22, 0x96, 0xBC, 0x42, 0x06, 0x95, 0xDD, 0x8F, 0x0C, 0xFA, 0x44, 0x97, 0x34, 0xDD,
       0x82, 0x91, 0x2B, 0x7E, 0x98, 0x89, 0x03, 0x68, 0x49, 0x4F, 0x3D};
	   
static unsigned char pKey_sdr[56] = {
       0xFA, 0x33, 0x10, 0x04, 0x57, 0xE0, 0x93, 0x18, 0xC8, 0xBA, 0xDF, 0x20, 0xEF, 0x12, 0xEA,
       0x14, 0xA2, 0xC1, 0xDC, 0x2B, 0xFF, 0x61, 0xFF, 0x22, 0x12, 0x3E, 0x47, 0x16, 0xFC, 0x83,
       0xCA, 0x10, 0x03, 0x30, 0x24, 0x11, 0xE0, 0xFA, 0xA0, 0x14, 0x6D, 0x2C, 0x52, 0x38, 0xB0,
       0x21, 0xB1, 0x17, 0x8F, 0x49, 0x62, 0x19, 0x2A, 0x6E, 0xDB, 0x18};
	   
static unsigned char pKey_snd[56] = {
       0x16, 0xD3, 0x11, 0x27, 0x00, 0x5B, 0x89, 0x31, 0x97, 0xB1, 0x7D, 0x09, 0x12, 0xBF, 0xCA,
       0x2A, 0xB7, 0x6F, 0xEF, 0x0F, 0xE2, 0xED, 0x92, 0x04, 0x45, 0xE0, 0xD5, 0x21, 0x8E, 0xB0,
       0x47, 0x26, 0x33, 0x3E, 0x36, 0x1B, 0x22, 0x99, 0xD9, 0x37, 0x99, 0x46, 0xE8, 0x0F, 0xCA,
       0xEC, 0x4B, 0x18, 0x67, 0x55, 0x91, 0x1A, 0xDA, 0x4A, 0xA8, 0x34};

static unsigned char pKey_tex[56] = {
       0xE6, 0xAE, 0x55, 0x2D, 0x1F, 0x54, 0x10, 0x30, 0x34, 0x14, 0x8B, 0x20, 0x8B, 0x15, 0x15,
       0x37, 0x8E, 0x73, 0x0C, 0x3D, 0x59, 0x9D, 0x34, 0x02, 0xF6, 0xF2, 0xA1, 0x1C, 0xAB, 0x1B,
       0x37, 0x22, 0x96, 0xBC, 0x42, 0x06, 0x95, 0xDD, 0x8F, 0x0C, 0xFA, 0x44, 0x97, 0x34, 0xDD,
       0x82, 0x91, 0x2B, 0x7E, 0x98, 0x89, 0x03, 0x68, 0x49, 0x4F, 0x3D};
File data also encrypted. For decrypt need key that may be generated from the magic constant (you can get it from ARCEntry)

Function for generate keys: ASM and C++ (PseudoCode)
User avatar
aluigi
VVIP member
VVIP member
Posts: 1916
Joined: Thu Dec 08, 2005 12:26 pm
Location: www.ZENHAX.com
Has thanked: 4 times
Been thanked: 661 times
Contact:

Re: Ikaruga (.arc ) [PC]

Post by aluigi »

except for the encryption, it's the same format of Sin Punishment 2.

The following is the quickbms script to extract the files:
http://aluigi.org/papers/bms/others/ikaruga.bms
Ekey
M-M-M-Monster veteran
M-M-M-Monster veteran
Posts: 1822
Joined: Wed Mar 31, 2010 6:54 am
Has thanked: 92 times
Been thanked: 1056 times

Re: Ikaruga (.arc ) [PC]

Post by Ekey »

Nice job :)
hcs
mega-veteran
mega-veteran
Posts: 263
Joined: Sun Oct 18, 2009 9:41 pm
Location: Portland, OR
Has thanked: 3 times
Been thanked: 79 times
Contact:

Re: Ikaruga (.arc ) [PC]

Post by hcs »

Hi aluigi, I am told that this script doesn't work for snd.arc.
Actual error QuickBMS quits on is: [myfseek] the offset 0x1e18c6e8 in the file -1 can't be reached
Using Win7 x64 with latest version of QuickBMS
Debug log: http://pastebin.com/uTHxfnLe
User avatar
aluigi
VVIP member
VVIP member
Posts: 1916
Joined: Thu Dec 08, 2005 12:26 pm
Location: www.ZENHAX.com
Has thanked: 4 times
Been thanked: 661 times
Contact:

Re: Ikaruga (.arc ) [PC]

Post by aluigi »

I guess the cause is some zero before the 56th character of the key that decrease its length.
I have updated the script to force the length of 56 bytes, let me know if it works.
hcs
mega-veteran
mega-veteran
Posts: 263
Joined: Sun Oct 18, 2009 9:41 pm
Location: Portland, OR
Has thanked: 3 times
Been thanked: 79 times
Contact:

Re: Ikaruga (.arc ) [PC]

Post by hcs »

Thanks for looking into it again luigi, but it sounds like it isn't working:
I've tried the updated script aluigi posted, still doesn't work, just give a different offset (0x00b72660) in the error message:

debug log: http://pastebin.com/SGQMLcjL
And a clarification:
the script doesn't work with any of the game archives, not just for snd.arc
Here is a small sample: http://snesmusic.org/hoot/sdr.zip
User avatar
aluigi
VVIP member
VVIP member
Posts: 1916
Joined: Thu Dec 08, 2005 12:26 pm
Location: www.ZENHAX.com
Has thanked: 4 times
Been thanked: 661 times
Contact:

Re: Ikaruga (.arc ) [PC]

Post by aluigi »

I can't help more, the script uses the exact magicdwords reported by Ekey, in fact the bin.arc posted above works.

If you know the correct magicdword for that specific archive, the script will work.
tot
ultra-n00b
Posts: 4
Joined: Tue Mar 02, 2010 7:55 pm

Re: Ikaruga (.arc ) [PC]

Post by tot »

aluigi wrote:I can't help more, the script uses the exact magicdwords reported by Ekey, in fact the bin.arc posted above works.
First of all thank you Ekey and aluigi for providing this script :D

I believe the unpack problem is related to the version of the .arc files. Shortly after release an update was issued, these files have a different checksum or encryption key.

I tested the script with the following files (md5sum) and it works flawlessly:

7b57ff8614effd1aceb87097a57d44ba *bin.arc
f9ddb5b7bbe6e0eb2fa98ad16c0634e6 *obj.arc
a15b389666c5133908399003a7c9c9e6 *sdr.arc
d79351e9da323b0a7c760ca4ffcce0f5 *snd.arc
1c0702415618f2ab45e3332b3194036f *tex.arc

If Ekey could share the method he used to determine the magic constants we could amend the script.
damekk
ultra-n00b
Posts: 1
Joined: Tue Dec 15, 2015 3:00 am

Re: Ikaruga (.arc ) [PC]

Post by damekk »

Ekey wrote:

Code: Select all

struct ARCHeader
{
 	DWORD dwID;	// NARC
 	DWORD dwTotalFiles;
 	DWORD dwNamesSize;
 	DWORD dwTableSize;	// -0x10
};

struct ARCEntry
{
 	DWORD dwUnknown;	// 0x00000007
 	DWORD dwNameOffset;	// + dwTotalFiles * 0x14
 	DWORD dwOffset;	// dwTableSize + 0x10
 	DWORD dwSize;
 	DWORD dwMagicConstant;	// Constant for generate key
};

Table offset begin from 0x10 offset. Keys generating from magic constants

Code: Select all

0x3A4D6669 - "sdr.arc"
0x327648CF - "obj.arc"
0x30763DD9 - "snd.arc"
0x327648CF - "tex.arc"
0x067640D6 - "bin.arc"
Already generated keys for decrypt : only tables:

Code: Select all

static unsigned char pKey_bin[56] = {
       0xF5, 0x06, 0xEF, 0x0B, 0xA0, 0x71, 0x33, 0x35, 0x25, 0x89, 0xE3, 0x0D, 0xFC, 0x45, 0x2D,
       0x10, 0x51, 0x7A, 0x80, 0x02, 0xC6, 0x39, 0x03, 0x37, 0x71, 0x96, 0x91, 0x05, 0x74, 0x95,
       0xB8, 0x24, 0x8F, 0x73, 0x93, 0x27, 0xAC, 0x03, 0xD8, 0x20, 0x36, 0x84, 0xD7, 0x06, 0xAF,
       0x31, 0xB4, 0x3A, 0xF8, 0xC6, 0xE7, 0x27, 0x77, 0xB9, 0xBB, 0x05};
	   
static unsigned char pKey_obj[56] = {
       0xE6, 0xAE, 0x55, 0x2D, 0x1F, 0x54, 0x10, 0x30, 0x34, 0x14, 0x8B, 0x20, 0x8B, 0x15, 0x15,
       0x37, 0x8E, 0x73, 0x0C, 0x3D, 0x59, 0x9D, 0x34, 0x02, 0xF6, 0xF2, 0xA1, 0x1C, 0xAB, 0x1B,
       0x37, 0x22, 0x96, 0xBC, 0x42, 0x06, 0x95, 0xDD, 0x8F, 0x0C, 0xFA, 0x44, 0x97, 0x34, 0xDD,
       0x82, 0x91, 0x2B, 0x7E, 0x98, 0x89, 0x03, 0x68, 0x49, 0x4F, 0x3D};
	   
static unsigned char pKey_sdr[56] = {
       0xFA, 0x33, 0x10, 0x04, 0x57, 0xE0, 0x93, 0x18, 0xC8, 0xBA, 0xDF, 0x20, 0xEF, 0x12, 0xEA,
       0x14, 0xA2, 0xC1, 0xDC, 0x2B, 0xFF, 0x61, 0xFF, 0x22, 0x12, 0x3E, 0x47, 0x16, 0xFC, 0x83,
       0xCA, 0x10, 0x03, 0x30, 0x24, 0x11, 0xE0, 0xFA, 0xA0, 0x14, 0x6D, 0x2C, 0x52, 0x38, 0xB0,
       0x21, 0xB1, 0x17, 0x8F, 0x49, 0x62, 0x19, 0x2A, 0x6E, 0xDB, 0x18};
	   
static unsigned char pKey_snd[56] = {
       0x16, 0xD3, 0x11, 0x27, 0x00, 0x5B, 0x89, 0x31, 0x97, 0xB1, 0x7D, 0x09, 0x12, 0xBF, 0xCA,
       0x2A, 0xB7, 0x6F, 0xEF, 0x0F, 0xE2, 0xED, 0x92, 0x04, 0x45, 0xE0, 0xD5, 0x21, 0x8E, 0xB0,
       0x47, 0x26, 0x33, 0x3E, 0x36, 0x1B, 0x22, 0x99, 0xD9, 0x37, 0x99, 0x46, 0xE8, 0x0F, 0xCA,
       0xEC, 0x4B, 0x18, 0x67, 0x55, 0x91, 0x1A, 0xDA, 0x4A, 0xA8, 0x34};

static unsigned char pKey_tex[56] = {
       0xE6, 0xAE, 0x55, 0x2D, 0x1F, 0x54, 0x10, 0x30, 0x34, 0x14, 0x8B, 0x20, 0x8B, 0x15, 0x15,
       0x37, 0x8E, 0x73, 0x0C, 0x3D, 0x59, 0x9D, 0x34, 0x02, 0xF6, 0xF2, 0xA1, 0x1C, 0xAB, 0x1B,
       0x37, 0x22, 0x96, 0xBC, 0x42, 0x06, 0x95, 0xDD, 0x8F, 0x0C, 0xFA, 0x44, 0x97, 0x34, 0xDD,
       0x82, 0x91, 0x2B, 0x7E, 0x98, 0x89, 0x03, 0x68, 0x49, 0x4F, 0x3D};
File data also encrypted. For decrypt need key that may be generated from the magic constant (you can get it from ARCEntry)

Function for generate keys: ASM and C++ (PseudoCode)

I'm sorry but how to determine the magic constants and keys?The files of the game has updated, the keys don't work for new version :(
Habanero
n00b
Posts: 19
Joined: Wed May 01, 2019 7:36 pm
Been thanked: 2 times

Re: Ikaruga (.arc ) [PC]

Post by Habanero »

I recently tried extracting the files myself, and I encountered the same problem. The BMS script seems to be out of date still since it gives an error message.

Filecutter:
http://www.mediafire.com/folder/vdc7glf ... es_PC_.ARC
Ikaruga directory contents:
http://puu.sh/DK6wK/623382bc9a.png
Post Reply