ihaveamac / ninfs

FUSE filesystem Python scripts for Nintendo console files
MIT License
438 stars 18 forks source link

Suggestion: Provide virtual encrypted/decrypted file for the whole file #23

Closed mariomadproductions closed 6 years ago

mariomadproductions commented 6 years ago

Not just individual (stripped down?) NCCHs.

ihaveamac commented 6 years ago

You mean for CCI/CIA/{something else}? It's probably not worth the trouble for it. But maybe if I can easily do the same thing I did for NCCH for other types.

mariomadproductions commented 6 years ago

CCI/CIA. Is there a reliable encryptor/decryptor for PC for those already?

ihaveamac commented 6 years ago

I might consider what is needed for CIA. What's the point for CCI / what would benefit from it?

mariomadproductions commented 6 years ago

I wanted it for the "decrypted checksum" fields in the No-Intro 3DS ROM database.

Not sure there is much use in those fields anymore though. Though I have a feeling decrypted ROMs are more compressible.

ihaveamac commented 6 years ago

decrypted checksum will probably be invalid due to small garbage in the ExeFS (end of .code section) on titles using extra crypto. I never thought it was worth fixing because it didn't impact functionality, and it would be really annoying to do so.

ihaveamac commented 6 years ago

Doing this for CIA would be very difficult unless only the titlekey layer is removed. This is because the SHA256 of the entire file would have to be regenerated if the content is modified.