I am attempting to decrypt/decode CodeBreaker/GameShark SP/Xploder codes for GBA.
Thanks to endrift, who made mGBA, I have a decryption tool for Action Replay MAX, GameShark Advance and Action Replay codes written in C# already.
My primary issues are these:
How can I determine the Encryption Key(s) for CodeBreaker?
Does the CodeBreaker for GBA use Tiny Encryption Algorithm?
If the CodeBreaker does not use Tiny Encryption Algorithm, then what method does it use? Can someone post a code snippet of the decryption method?
Here's the code for GameShark Advance/Action Replay (v1/v2) decryption
Thanks to endrift, who made mGBA, I have a decryption tool for Action Replay MAX, GameShark Advance and Action Replay codes written in C# already.
My primary issues are these:
How can I determine the Encryption Key(s) for CodeBreaker?
Does the CodeBreaker for GBA use Tiny Encryption Algorithm?
If the CodeBreaker does not use Tiny Encryption Algorithm, then what method does it use? Can someone post a code snippet of the decryption method?
Here's the code for GameShark Advance/Action Replay (v1/v2) decryption
Code:
UInt32[] GBAGameSharkSeeds = { UInt32.Parse("09F4FBBD", NumberStyles.HexNumber), UInt32.Parse("9681884A", NumberStyles.HexNumber), UInt32.Parse("352027E9", NumberStyles.HexNumber), UInt32.Parse("F3DEE5A7", NumberStyles.HexNumber) };
//Tiny Encryption Algorithm
int i;
for (i = 0; i < 32; ++i)
{
op2 -= ((op1 << 4) + GBAGameSharkSeeds[2]) ^ (op1 + sum) ^ ((op1 >> 5) + GBAGameSharkSeeds[3]);
op1 -= ((op2 << 4) + GBAGameSharkSeeds[0]) ^ (op2 + sum) ^ ((op2 >> 5) + GBAGameSharkSeeds[1]);
sum -= 0x9E3779B9;
}
//op1 has the Address
//op2 has the Value
//Sum, is pointless?

Comment