From 521dfe12c6b6d47b3ff4e14b792708b160e7f80d Mon Sep 17 00:00:00 2001 From: Hash Borgir Date: Sat, 4 Jun 2022 05:55:41 -0600 Subject: [PATCH] testing checksum after modify --- checksum.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/checksum.php b/checksum.php index 8f02a9b..afd1d09 100644 --- a/checksum.php +++ b/checksum.php @@ -266,7 +266,7 @@ $fp = fopen($filename, "rb+"); $filesize = filesize($filename); $pucData = file_get_contents($filename); -// ddump($pucData); +ddump(unpack('C*', $pucData)); // pucData - pointer to the byte stream of the .d2s file // iSize - number of bytes in the stream ( filesize ) @@ -278,7 +278,8 @@ function checksum($fp, $pucData, $iSize, $xorTableHex) { $uVar = 0xFFFFFFFF; for($i=0;$i<$iSize;$i++) { - // $hex = strtoupper(bin2hex($pucData[$i])); // getting correct bytes here, matches file in hex editor + // $hex = strtoupper(bin2hex($pucData[$i])); + // getting correct bytes here, matches file in hex editor // dump((strtoupper(dechex($xorTableHex[$hex])))); // uVar1 = uVar1 >> 8 ^ DWORD_ARRAY_6fd2a248[(uint)*param_1 ^ uVar1 & 0xff];