SciresM, (one of the public devs in the community with very deep access into the Switch,) has said previously in the VGPC Discord server that:
(Source, in VGPC Discord server)SciresM: wrote: tl;dr for switch is that what people call xci doesn't match actual format
there's an 0x200 sector that goes before the header
which contains cartridge communication keydata
(it's title-specific, not cart-specific)
...
whether can be done properly without custom dumper sysmodule is an open question imo
it can be done that way easily since in that model you take over all lotus comms directly
you could probably patch FS to output the sector to you.
It has since been figured out that you can just dump it directly from FS:
(Source, in VGPC Discord server)SciresM wrote: tl;dr is that the the asic handler object in nn::gc:: keeps a copy of the cartridge header, a copy of the cartridge cert, and a copy of the cartridge key area in its members
So you can debug FS and read the key area out of memory.
(First message source, in VGPC Discord server)SciresM wrote: official XCI files produced by Nintendo tools start with the key area
The key area is at offset 0 and the signature/header is at offset 4096
And the key area is shared for all cartridges for a game
"Redumped" is a yes.
...
Your dumps are bad, and you should fix it.
Aren't you supposed to be about preservation?
...
The key area contains the communication titlekey, which is fixed per game.
...
In official files produced by Nintendo tools
the key area is the first part of the file
and what your dumps call "XCI" is at offset 0x1000.
If you care about preserving games, dumps should be re-done.
What I'm personally thinking is that we should mark all the previous Switch dumps without this data as "Bad", put this data into the main XCI dumps via a currently-WIP rewrite of the Switch cart dumping tool NXDumpTool (which we already use for Switch cart dumps before this new information), and then get people to redump these as from what I'm aware - This is how we would normally do it.
My main hang up here at the moment is that as this tool does not have any public, fully compiled, "Stable" releases of this updated version app out there yet from the official developer. What *is* out there however, is unofficial (and basically "Alpha") builds that have been compiled and put into the VGPC Discord Server.
I have talked to Hiccup about this in private, and he feels that we should put this data in its own file (that could be optional for submission and optionally excluded from the DATs) alongside the XCI files, keeping the old dumps in the database as "Good."
He has told me that he will put his argument as its own post, so please refer there for his view on this.
One of my issues with this is that dumpers and datters will likely get confused in the long run (how we are to add the data if it's its own file, users submitting only the Key Area file and not the XCI, or the XCI and not that extra data, etc) more than this would help.
Thanks for your time.
Edit: There seems to be a good thread going of hashes for the XCI and this data over at viewtopic.php?f=7&t=4036