Skip to content

Commit

Permalink
Alien Isolation PS4 csum fix
Browse files Browse the repository at this point in the history
Update build-win.yml

Update README.md
  • Loading branch information
bucanero committed Sep 7, 2023
1 parent 6c1b597 commit 46ce9e3
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-win.yml
Expand Up @@ -43,7 +43,7 @@ jobs:
make
# add .exe extension to binaries
mv alien-checksum-fixer/alien-checksum-fixer alien-checksum-fixer.exe
mv castlevania-checksum-fixer/cod-checksum-fixer castlevania-checksum-fixer.exe
mv castlevania-checksum-fixer/castlevania-checksum-fixer castlevania-checksum-fixer.exe
mv cod-blackops-decrypter/cod-blackops-decrypter cod-blackops-decrypter.exe
mv cod-checksum-fixer/cod-checksum-fixer cod-checksum-fixer.exe
mv dbz-checksum-fixer/dbz-checksum-fixer dbz-checksum-fixer.exe
Expand Down
5 changes: 4 additions & 1 deletion README.md
Expand Up @@ -61,7 +61,10 @@ Tools to decrypt specific PS4 save-games:

Tools to fix checksums for specific PS3 save-games:
- [alien-checksum-fixer](./alien-checksum-fixer)
- Alien: Isolation
- Alien: Isolation (PS3/PS4)
- [castlevania-checksum-fixer](./castlevania-checksum-fixer)
- Castlevania: Lords of Shadow
- Castlevania: Lords of Shadow 2
- [cod-checksum-fixer](./cod-checksum-fixer)
- Call of Duty: Ghosts
- [deadspace-checksum-fixer](./deadspace-checksum-fixer)
Expand Down
18 changes: 14 additions & 4 deletions alien-checksum-fixer/main.c
@@ -1,6 +1,6 @@
/*
*
* Alien: Isolation (PS3) Checksum Fixer - (c) 2021 by Bucanero - www.bucanero.com.ar
* Alien: Isolation (PS3/PS4) Checksum Fixer - (c) 2021 by Bucanero - www.bucanero.com.ar
*
* This tool is based on the "Security Archive" notes by Philymaster (https://community.wemod.com/t/philymasters-security-archive/3923)
*
Expand Down Expand Up @@ -32,7 +32,7 @@ int main(int argc, char **argv)
u64 csum;
char *opt, *bak;

printf("\nAlien: Isolation (PS3) checksum fixer 0.1.0 - (c) 2021 by Bucanero\n\n");
printf("\nAlien: Isolation (PS3/PS4) checksum fixer 0.2.0 - (c) 2021 by Bucanero\n\n");

if (--argc < 1)
{
Expand All @@ -48,8 +48,18 @@ int main(int argc, char **argv)
// Save a file backup
asprintf(&bak, "%s.bak", argv[1]);
write_buffer(bak, data, len);

csum = ES32(*(u32*)(data + 0x18)) + ES32(*(u32*)(data + 0x1C)) - 0x20;

// detect PS4 save
if (memcmp(data, "IAAC", 4) == 0)
csum = (*(u32*)(data + 0x18)) + (*(u32*)(data + 0x1C)) - 0x20;
// detect PS3 save
else if (memcmp(data, "CAAI", 4) == 0)
csum = ES32(*(u32*)(data + 0x18)) + ES32(*(u32*)(data + 0x1C)) - 0x20;
else
{
printf("[X] This is not an Alien Isolation save file! (%s)\n", argv[1]);
return -1;
}

printf("[*] Checksum Size : %llu bytes\n", csum);
printf("[*] Stored Checksum : %016llX\n", ES64(*(u64*)(data+8)));
Expand Down
Binary file added alien-checksum-fixer/samples/THEFILE
Binary file not shown.

0 comments on commit 46ce9e3

Please sign in to comment.