Applies to: GT3, GT4, TT · Extension: .GT4 / .TT · Endian: Little
Main builds of Gran Turismo and Tourist Trophy will have splitted executables - the main executable named by the game code and another file usually starting with CORE.
The main executable is in charge of processing the second file.
privatestaticreadonlybyte[]k=newbyte[16]{// "PolyphonyDigital"0x05,0x3A,0x39,0x2C,0x25,0x3D,0x3A,0x3B,0x2C,0x11,0x3C,0x32,0x3C,0x21,0x34,0x39,};// The key is encrypted, decrypt itprivatestaticbyte[]GetKey(){byte[]key=newbyte[16];for(inti=0;i<16;i++)key[i]=(byte)(k[i]^0x55);returnkey;}// For decryption of the body:byte[]iv=sr.ReadBytes(8);byte[]key=GetKey();vars=newSalsa20(key,key.Length);s.SetIV(iv);s.Decrypt(file.AsSpan(8),file.Length-12);