Adubbz / Ghidra-Switch-Loader

Nintendo Switch loader for Ghidra
ISC License
278 stars 41 forks source link

How to recognize NXO file? #30

Closed ghost closed 2 years ago

ghost commented 2 years ago

Yes

I see you have NXO support, but how do I use it?

I tried renaming 0x00 to KIP1,NSO0 etc. for fun. Obviously didn't work :)

Thanks :)

masagrator commented 2 years ago

NXO is just a general name used in homebrew scene for shared sections in NSO and NRO (starting with MOD0 at 8th byte) There is no NXO file. When loading NRO or NSO, plugin uses also NXO folder to parse data.

And obviously plugin does more checks than just checking magic

ghost commented 2 years ago

Idk, so I have to make it recognize it as a NRO or NSO for it to use the NXO folder to parse data? What I'm asking is how? Can't select the Nintendo Switch Binary, when loading it.

I opened it as AARCH64 v8-A already, it has xrefs and everything, but no segments:) so I can already work on it 👍

masagrator commented 2 years ago

And what this file even is?

ghost commented 2 years ago

Doesn't matter :) Don't actually need a loader anyway.. but would still like to know if there's a way to make it work as is :) It's a dumped switch game :)

masagrator commented 2 years ago

Doesn't matter

Ok. So I don't care.

Adubbz commented 2 years ago

MOD0 is not a file format in itself, it is part of a larger file format that contains it. This is an incomplete dump.