d0k3 / GodMode9

GodMode9 Explorer - A full access file browser for the Nintendo 3DS console :godmode:
GNU General Public License v3.0
2.17k stars 194 forks source link

[FEATURE REQUEST] Support for decrypting dev CIA files #688

Closed ccdffddfddfdsfedeee closed 3 years ago

ccdffddfddfdsfedeee commented 3 years ago

Got a great idea on how to improve GodMode9? That's always appreciated. Please make sure you add all the required info here.

Describe the feature you'd like Is it possible to decrypt dev CIA files? It says failed every time, and it still does not work with aeskeydb.bin.

Describe alternatives you've considered A computer works, but it takes a long time.

d0k3 commented 3 years ago

That should already work, even without an aeskeydb.bin file. Can you add some info? What exactly did you try to decrypt and what was the output?

ccdffddfddfdsfedeee commented 3 years ago

Screenshots of the errors: snap_210327151334 snap_210327151026

d0k3 commented 3 years ago

Alright thanks. First of all, this doesn't look like a dev CIA, but rather like a system CIA. Is that what you meant?

d0k3 commented 3 years ago

The second screenshot - that didn't happen right after the failed decryption, right? I'd assume it could happen after mounting an incorrectly decrypted CIA.

ccdffddfddfdsfedeee commented 3 years ago

The CIA is a dev encrypted system CIA, and the second screenshot is the same CIA as the first one

d0k3 commented 3 years ago

Alright, can you contact me via some other means? Maybe via the official GM9 Discord or via Telegram (@d0k3_homebrew_legend). I may need some additional data from you.

ccdffddfddfdsfedeee commented 3 years ago

I do not have accounts for those

d0k3 commented 3 years ago

Okay, I guess I know what's going wrong there. Decrypting this will work on a dev 3DS, but I'm strongly assuming you got none. One issue here is, there's no way to tell apart retail NCCHs from dev NCCHs, apart from trying to decrypt (and failing). The other issue is that a retail 3DS simply does not have dev keys.

There is a workaround, though. You could create an aeskeydb.bin file that replaces your retail NCCH keys with dev ones. As far as I know, someone already did this in the past. If you need help with this, you can ask on the IRC channel GodMode9 on Freenode.

d0k3 commented 3 years ago

Alright, closing this now, because adding this feature wouldn't benefit most users, while it would be a lot of work to implement (and still wouldn't be convenient for the users).

Apart from the workaround I mentioned, GodMode9 will only handle the data belonging to the systems type (retail/dev). It's better to decrypt dev data on a PC.