d0k3 / GodMode9

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

[FEATURE REQUEST] Write updated crypto flags of the first NCCH partition when decrypting NCSD (.3ds) files #665

Closed ZeroSkill1 closed 3 years ago

ZeroSkill1 commented 3 years ago

When decrypting a .3ds file, the header at 0x1100 still has the flags of the previously encrypted NCCH partition in it. I don't know whether this is done on purpose or not.

d0k3 commented 3 years ago

If I remember correctly, we had the exact same discussion for leaving that header as is a while ago. I'm still open for discussing this.

Keep in mind, decrypted cart dumps are non-standard and don't exist in big N's universe. The signature inside the NCCH headers only matches the NCCH headers in their original form. While we don't need to change anything in the NCSD header, we need to change flags inside the NCCH headers. In same cases, more. Leaving the header 0x1000 untouched gives us a way of keeping a copy of the original, unaltered header, with the signature intact.

ZeroSkill1 commented 3 years ago

Oh, I understand now.

Though, that signature doesn't have any impact on usability though, does it?

d0k3 commented 3 years ago

No, it doesn't and the flags inside the NCCH header @0x1000 do not either. It's a pure digital preservation thing (afaik).

ZeroSkill1 commented 3 years ago

Alright, thank you.