Out of interest how does this hash get calculated?
Code:
20EFF0183DA095635F99E8978A90C27C7D3F42E6504DF328F42ACC280EB05D1B
I take it's a hash from a file in Atmosphere, but what file and what kind of hash.
It's the SHA-256 hash of Loader.kip, which is stored inside fusee-secondary. You can extract fusee-secondary with
FSS0-Extractor and then calculate the SHA-256 hash of Loader.kip using your tool of choice.
If you want to compare Loader.kip to the previous version to see how much changed, you will need to decompress it with
hactool, like
Code:
hactool --intype=kip1 --uncompressed=Loader-uncompressed.kip Loader.kip
Then you can compare the uncompressed versions.
Also I take it the file is getting patches applied at the following offsets of that file:
Yes, at least for the fusee-secondary patches. There's a comment at the top of patches.ini that explains the format. I think the patches are applied after decompression, but the hash in the patches.ini section is the hash of the compressed version.
The .ips files for fusee-primary use the same patches, but at 0x1C54 and 0x696C. I believe fusee-primary must be applying patches to the whole kip file while Hekate applies it to the code section within the kip file. The kip has a 0x100-byte header, and the code section is the first section in the file after the header, so that explains the position difference.