Hacking 3DS Firmware has been decrypted

Status
Not open for further replies.

Devin

"Local Hardware Wizard"
Member
Joined
Aug 17, 2009
Messages
5,955
Trophies
2
Age
29
Location
The Nexus
XP
4,538
Country
United States
Definitely interested to see where this leads if anywhere. Mainly interested to see what kinds of homebrew could/would be released aside from the Emulators and such.
 

Ericthegreat

Not New Member
Member
Joined
Nov 8, 2008
Messages
3,455
Trophies
2
Location
Vana'diel
XP
4,281
Country
United States
Definitely interested to see where this leads if anywhere. Mainly interested to see what kinds of homebrew could/would be released aside from the Emulators and such.
From what I can tell we still have nothing.... Unless somthing is found in the firmware. Right?
 

3DSGuy

No longer in scene
Member
Joined
May 22, 2012
Messages
345
Trophies
0
XP
467
Country
United States

It's a brief explanation of how the NCCH (A type of container used by the 3DS) keys are randomized and individual per-console. This was probably asked to clarify the significance of the key recently released that is associated with the 3DS Camera, which is NOT used for decrypting the app, but is simply used for (Someone please correct me if I'm wrong) downloading the encrypted form from Nintendo servers. If the key HAD been a universal NCCH key, which is what 3dsguy was asking, it may have opened up a lot more options (again, I could be wrong, if anyone who knows better cares to correct me), such as being able to analyze the app header.

Edit: Before someone can take my words out of context, the key released will NOT enable anything hypothetically mentioned above.
Okay, I need to clear somethings. The decrypted title key for Nintendo 3DS Camera, is not the NCCH key for Nintendo 3DS Camera. The data past the NCCH header in NCCH files(with the exception for the plain region) for retail units are encrypted with 128bit AES-CTR. Part of the key is individual for NCCH file. So each NCCH key is different for each retail NCCH. NCCH keys are not console unique, if it was, a game cartridge would only work on one 3DS. But the 3DS uses a special hardware key-scrambler for all keys except title keys, but essentially the key is the same between consoles.

Let me explain the purpose of title keys.

Nintendo needs to host 3DS titles on an internet server, for system updates and eShop downloads. For many reasons including potential piracy, Nintendo encrypts the NCCH files with AES-CBC 128bit, before putting them on there servers for download. So this is where title key come in. The title key allows the 3DS to decrypt the CDN files to readable NCCH files. But the title key is encrypted in the 'ticket', which can only be decrypted with the Common Key. So this way Nintendo can restrict what can access all system NCCH files with a 0x10 long key.

So to sum up:

NCCH key - unique for every NCCH file, uses AES-CTR. But it can be determined. Encrypts the Exheader/ExeFS/RomFS inside the NCCH.
Common Key - constant, is used to decrypt the 'title key' from the 'ticket' for system title that exists on Nintendo's servers. Uses AES-CBC.
Title key - unique for every title, but common for every encrypted NCCH for a given title. Is used to decrypt NCCH files found on Nintendo servers to a readable NCCH file. Uses AES-CBC.(The Exheader/ExeFS/RomFS still requires a NCCH key for further decryption)
 

Rydian

Resident Furvert™
Member
Joined
Feb 4, 2010
Messages
27,880
Trophies
0
Age
36
Location
Cave Entrance, Watching Cyan Write Letters
Website
rydian.net
XP
9,111
Country
United States
Also inb4 "a 0x10 long key, we can brute-force that right?" The 0x denotes hex, so that's actually 18 quintillion possibilities (as usual, if my math is right).

Also, if the check is done at Nintendo's servers they can just use attempt limiting to basically kill all brute force attempts outside of a Fucking Huge™ botnet.

Also inb4 "well why don't put the ROM on the SD card and see if the 3DS will load it?".
 
  • Like
Reactions: 3 people

3DSGuy

No longer in scene
Member
Joined
May 22, 2012
Messages
345
Trophies
0
XP
467
Country
United States
Also, if the check is done at Nintendo's servers they can just use attempt limiting to basically kill all brute force attempts outside of a Fucking Huge™ botnet.
No Nintendo's servers won't do any checks. They've set it up so they can just put files on their servers( app data, TMD and ticket) and they can sleep soundly in the knowledge that 99.9999% of people won't be able to get the decrypted title key for any given title. You can download the ticket for system titles, so you don't need to be connected (after downloading the ticket) to Nintendo's servers to brute force the common key (of course no one would try to brute force the common key.)
 
  • Like
Reactions: 1 person

Sylantemp

Active Member
Newcomer
Joined
Jul 20, 2012
Messages
43
Trophies
0
XP
71
Country
United States

It's a brief explanation of how the NCCH (A type of container used by the 3DS) keys are randomized and individual per-console. This was probably asked to clarify the significance of the key recently released that is associated with the 3DS Camera, which is NOT used for decrypting the app, but is simply used for (Someone please correct me if I'm wrong) downloading the encrypted form from Nintendo servers. If the key HAD been a universal NCCH key, which is what 3dsguy was asking, it may have opened up a lot more options (again, I could be wrong, if anyone who knows better cares to correct me), such as being able to analyze the app header.

Edit: Before someone can take my words out of context, the key released will NOT enable anything hypothetically mentioned above.
Okay, I need to clear somethings. The decrypted title key for Nintendo 3DS Camera, is not the NCCH key for Nintendo 3DS Camera. The data past the NCCH header in NCCH files(with the exception for the plain region) for retail units are encrypted with 128bit AES-CTR. Part of the key is individual for NCCH file. So each NCCH key is different for each retail NCCH. NCCH keys are not console unique, if it was, a game cartridge would only work on one 3DS. But the 3DS uses a special hardware key-scrambler for all keys except title keys, but essentially the key is the same between consoles.

Let me explain the purpose of title keys.

Nintendo needs to host 3DS titles on an internet server, for system updates and eShop downloads. For many reasons including potential piracy, Nintendo encrypts the NCCH files with AES-CBC 128bit, before putting them on there servers for download. So this is where title key come in. The title key allows the 3DS to decrypt the CDN files to readable NCCH files. But the title key is encrypted in the 'ticket', which can only be decrypted with the Common Key. So this way Nintendo can restrict what can access all system NCCH files with a 0x10 long key.

So to sum up:

NCCH key - unique for every NCCH file, uses AES-CTR. But it can be determined. Encrypts the Exheader/ExeFS/RomFS inside the NCCH.
Common Key - constant, is used to decrypt the 'title key' from the 'ticket' for system title that exists on Nintendo's servers. Uses AES-CBC.
Title key - unique for every title, but common for every encrypted NCCH for a given title. Is used to decrypt NCCH files found on Nintendo servers to a readable NCCH file. Uses AES-CBC.(The Exheader/ExeFS/RomFS still requires a NCCH key for further decryption)

Ah, thanks for clearing all that up. I got the basics of it reading over the documentation, but the information tends to be so far spread and seemingly unconnected that it can get overwhelming to try and understand.
On that note, though, the servers are handled in the same means as the Wii/DSi, correct? Could it be assumed that with individual title keys known (and the common key, which is still unknown), a partially-encrypted NCCH file could be downloaded from a device other than the 3DS? An NCCH key would still be missing, but the actual file would be decrypted from CDN to NCCH format. This is just going off of prior knowledge, but it sounds a lot like how NUS Downloader interacted with the servers (albeit with full decryption?).

I suppose "Universal NCCH key" was a bad term to use in response, even as a hypothetical. Your question on 3DBrew had actually confused me a bit, as it sounded like mixing the concepts of common and private keys, in different context.
 

3DSGuy

No longer in scene
Member
Joined
May 22, 2012
Messages
345
Trophies
0
XP
467
Country
United States
Ah, thanks for clearing all that up. I got the basics of it reading over the documentation, but the information tends to be so far spread and seemingly unconnected that it can get overwhelming to try and understand.
On that note, though, the servers are handled in the same means as the Wii/DSi, correct? Could it be assumed that with individual title keys known (and the common key, which is still unknown), a partially-encrypted NCCH file could be downloaded from a device other than the 3DS? An NCCH key would still be missing, but the actual file would be decrypted from CDN to NCCH format. This is just going off of prior knowledge, but it sounds a lot like how NUS Downloader interacted with the servers (albeit with full decryption?).

I suppose "Universal NCCH key" was a bad term to use in response, even as a hypothetical. Your question on 3DBrew had actually confused me a bit, as it sounded like mixing the concepts of common and private keys, in different context.
Yeah it's more or less the same as Wii/DSi. The formats of the TMD and ticket appear to be slightly different for 3DS. But the concept is still the same.

"I suppose "Universal NCCH key" was a bad term to use in response, even as a hypothetical. Your question on 3DBrew had actually confused me a bit, as it sounded like mixing the concepts of common and private keys, in different context." 3DS Dev units use 'static/universal' NCCH keys (there are 3 AFAIK), so one could decrypt an entire set of developer NCCH files with one dev NCCH key. I was just asking if NCCH keys for retail units we're also 'static', and as yellows8 pointed out, they aren't.
 
  • Like
Reactions: 1 person

Slowking

Well-Known Member
Member
Joined
Dec 31, 2006
Messages
1,403
Trophies
0
XP
260
Country
Germany
DECRYPTED game = you can run the game on an emulator (but you need to make one first)
You can also see the files inside and examine them. That DOESN'T necessarily mean you can RE-ENCRYPT a changed version and put it BACK on the card to play it or run homebrew. It's often a one-way thing, especially when it also needs to be SIGNED (something else that's different from decryption and we can't necessarily do yet.)

Actually that's wrong. Signing and encrypting are the same thing, at least when it comes to any videogame console I know about.

The 3DS uses RSA for game encryption. It's an asymetric encryption, which (in simple terms) means, that even if you have the decryption key, you still don't have the encryption key. The encryption key, can't be found in the 3DS itself. It's kept somewhere at Nintendo to sign the final games. Not even devs have it.
It works by using a math problem, where the equasion in one direction is really simple but in the other would take all the computers in the world the age of the universe to calculate.
 

3DSGuy

No longer in scene
Member
Joined
May 22, 2012
Messages
345
Trophies
0
XP
467
Country
United States
DECRYPTED game = you can run the game on an emulator (but you need to make one first)
You can also see the files inside and examine them. That DOESN'T necessarily mean you can RE-ENCRYPT a changed version and put it BACK on the card to play it or run homebrew. It's often a one-way thing, especially when it also needs to be SIGNED (something else that's different from decryption and we can't necessarily do yet.)

Actually that's wrong. Signing and encrypting are the same thing, at least when it comes to any videogame console I know about.

The 3DS uses RSA for game encryption. It's an asymetric encryption, which (in simple terms) means, that even if you have the decryption key, you still don't have the encryption key. The encryption key, can't be found in the 3DS itself. It's kept somewhere at Nintendo to sign the final games. Not even devs have it.
It works by using a math problem, where the equasion in one direction is really simple but in the other would take all the computers in the world the age of the universe to calculate.
Well you are partly right. Though clearly you haven't read the rest of the thread. The signatures in files used with the 3DS, do use RSA encryption. But everything else uses AES encryption. And in the case of NCCH files, the encryption of the game data uses AES-CTR, where the encryption key is the same as the encryption key.
 

Mirrorman95

New Member
Newbie
Joined
Sep 1, 2012
Messages
3
Trophies
0
XP
6
Country
United States
DECRYPTED game = you can run the game on an emulator (but you need to make one first)
You can also see the files inside and examine them. That DOESN'T necessarily mean you can RE-ENCRYPT a changed version and put it BACK on the card to play it or run homebrew. It's often a one-way thing, especially when it also needs to be SIGNED (something else that's different from decryption and we can't necessarily do yet.)

Actually that's wrong. Signing and encrypting are the same thing, at least when it comes to any videogame console I know about.

The 3DS uses RSA for game encryption. It's an asymetric encryption, which (in simple terms) means, that even if you have the decryption key, you still don't have the encryption key. The encryption key, can't be found in the 3DS itself. It's kept somewhere at Nintendo to sign the final games. Not even devs have it.
It works by using a math problem, where the equasion in one direction is really simple but in the other would take all the computers in the world the age of the universe to calculate.
Well you are partly right. Though clearly you haven't read the rest of the thread. The signatures in files used with the 3DS, do use RSA encryption. But everything else uses AES encryption. And in the case of NCCH files, the encryption of the game data uses AES-CTR, where the encryption key is the same as the encryption key.
Is there at least a fair chance of a ROM decrypter becoming available in the near-future?
 

3DSGuy

No longer in scene
Member
Joined
May 22, 2012
Messages
345
Trophies
0
XP
467
Country
United States
DECRYPTED game = you can run the game on an emulator (but you need to make one first)
You can also see the files inside and examine them. That DOESN'T necessarily mean you can RE-ENCRYPT a changed version and put it BACK on the card to play it or run homebrew. It's often a one-way thing, especially when it also needs to be SIGNED (something else that's different from decryption and we can't necessarily do yet.)

Actually that's wrong. Signing and encrypting are the same thing, at least when it comes to any videogame console I know about.

The 3DS uses RSA for game encryption. It's an asymetric encryption, which (in simple terms) means, that even if you have the decryption key, you still don't have the encryption key. The encryption key, can't be found in the 3DS itself. It's kept somewhere at Nintendo to sign the final games. Not even devs have it.
It works by using a math problem, where the equasion in one direction is really simple but in the other would take all the computers in the world the age of the universe to calculate.
Well you are partly right. Though clearly you haven't read the rest of the thread. The signatures in files used with the 3DS, do use RSA encryption. But everything else uses AES encryption. And in the case of NCCH files, the encryption of the game data uses AES-CTR, where the encryption key is the same as the encryption key.
Is there at least a fair chance of a ROM decrypter becoming available in the near-future?
Well... there is one ;). ctrtool is capable of decrypting ROMs, provided you have the right NCCH key(AES-CTR 128bit) for the ROM.

And before you ask, no retail NCCH keys will probably be found in the near future.
 

Mirby

BDFF Hype~ :3
Member
Joined
Feb 9, 2011
Messages
469
Trophies
1
Age
34
Location
That One Place
Website
mirbystudios.tumblr.com
XP
1,249
Country
United States
DECRYPTED game = you can run the game on an emulator (but you need to make one first)
You can also see the files inside and examine them. That DOESN'T necessarily mean you can RE-ENCRYPT a changed version and put it BACK on the card to play it or run homebrew. It's often a one-way thing, especially when it also needs to be SIGNED (something else that's different from decryption and we can't necessarily do yet.)

Actually that's wrong. Signing and encrypting are the same thing, at least when it comes to any videogame console I know about.

The 3DS uses RSA for game encryption. It's an asymetric encryption, which (in simple terms) means, that even if you have the decryption key, you still don't have the encryption key. The encryption key, can't be found in the 3DS itself. It's kept somewhere at Nintendo to sign the final games. Not even devs have it.
It works by using a math problem, where the equasion in one direction is really simple but in the other would take all the computers in the world the age of the universe to calculate.
Well you are partly right. Though clearly you haven't read the rest of the thread. The signatures in files used with the 3DS, do use RSA encryption. But everything else uses AES encryption. And in the case of NCCH files, the encryption of the game data uses AES-CTR, where the encryption key is the same as the encryption key.
Is there at least a fair chance of a ROM decrypter becoming available in the near-future?
Well... there is one ;). ctrtool is capable of decrypting ROMs, provided you have the right NCCH key(AES-CTR 128bit) for the ROM.

And before you ask, no retail NCCH keys will probably be found in the near future.
Damn. I just wanna peek inside some games! D:
 
  • Like
Reactions: 1 person

Mirrorman95

New Member
Newbie
Joined
Sep 1, 2012
Messages
3
Trophies
0
XP
6
Country
United States
DECRYPTED game = you can run the game on an emulator (but you need to make one first) You can also see the files inside and examine them. That DOESN'T necessarily mean you can RE-ENCRYPT a changed version and put it BACK on the card to play it or run homebrew. It's often a one-way thing, especially when it also needs to be SIGNED (something else that's different from decryption and we can't necessarily do yet.)
Actually that's wrong. Signing and encrypting are the same thing, at least when it comes to any videogame console I know about. The 3DS uses RSA for game encryption. It's an asymetric encryption, which (in simple terms) means, that even if you have the decryption key, you still don't have the encryption key. The encryption key, can't be found in the 3DS itself. It's kept somewhere at Nintendo to sign the final games. Not even devs have it. It works by using a math problem, where the equasion in one direction is really simple but in the other would take all the computers in the world the age of the universe to calculate.
Well you are partly right. Though clearly you haven't read the rest of the thread. The signatures in files used with the 3DS, do use RSA encryption. But everything else uses AES encryption. And in the case of NCCH files, the encryption of the game data uses AES-CTR, where the encryption key is the same as the encryption key.
Is there at least a fair chance of a ROM decrypter becoming available in the near-future?
Well... there is one ;). ctrtool is capable of decrypting ROMs, provided you have the right NCCH key(AES-CTR 128bit) for the ROM. And before you ask, no retail NCCH keys will probably be found in the near future.
Damn. I just wanna peek inside some games! D:
You and me both, particularly Kingdom Hearts 3D. So I assume the NCCH key of any given game is encrypted somewhere in its 3DS ROM?
 

nukeboy95

Old skool member
Member
Joined
Aug 24, 2010
Messages
2,275
Trophies
0
Location
The left side
XP
916
Country
United States
DECRYPTED game = you can run the game on an emulator (but you need to make one first) You can also see the files inside and examine them. That DOESN'T necessarily mean you can RE-ENCRYPT a changed version and put it BACK on the card to play it or run homebrew. It's often a one-way thing, especially when it also needs to be SIGNED (something else that's different from decryption and we can't necessarily do yet.)
Actually that's wrong. Signing and encrypting are the same thing, at least when it comes to any videogame console I know about. The 3DS uses RSA for game encryption. It's an asymetric encryption, which (in simple terms) means, that even if you have the decryption key, you still don't have the encryption key. The encryption key, can't be found in the 3DS itself. It's kept somewhere at Nintendo to sign the final games. Not even devs have it. It works by using a math problem, where the equasion in one direction is really simple but in the other would take all the computers in the world the age of the universe to calculate.
Well you are partly right. Though clearly you haven't read the rest of the thread. The signatures in files used with the 3DS, do use RSA encryption. But everything else uses AES encryption. And in the case of NCCH files, the encryption of the game data uses AES-CTR, where the encryption key is the same as the encryption key.
Is there at least a fair chance of a ROM decrypter becoming available in the near-future?
Well... there is one ;). ctrtool is capable of decrypting ROMs, provided you have the right NCCH key(AES-CTR 128bit) for the ROM. And before you ask, no retail NCCH keys will probably be found in the near future.
Damn. I just wanna peek inside some games! D:
You and me both, particularly Kingdom Hearts 3D. So I assume the NCCH key of any given game is encrypted somewhere in its 3DS ROM?
id rather peek around in the saves
 

3DSGuy

No longer in scene
Member
Joined
May 22, 2012
Messages
345
Trophies
0
XP
467
Country
United States
DECRYPTED game = you can run the game on an emulator (but you need to make one first) You can also see the files inside and examine them. That DOESN'T necessarily mean you can RE-ENCRYPT a changed version and put it BACK on the card to play it or run homebrew. It's often a one-way thing, especially when it also needs to be SIGNED (something else that's different from decryption and we can't necessarily do yet.)
Actually that's wrong. Signing and encrypting are the same thing, at least when it comes to any videogame console I know about. The 3DS uses RSA for game encryption. It's an asymetric encryption, which (in simple terms) means, that even if you have the decryption key, you still don't have the encryption key. The encryption key, can't be found in the 3DS itself. It's kept somewhere at Nintendo to sign the final games. Not even devs have it. It works by using a math problem, where the equasion in one direction is really simple but in the other would take all the computers in the world the age of the universe to calculate.
Well you are partly right. Though clearly you haven't read the rest of the thread. The signatures in files used with the 3DS, do use RSA encryption. But everything else uses AES encryption. And in the case of NCCH files, the encryption of the game data uses AES-CTR, where the encryption key is the same as the encryption key.
Is there at least a fair chance of a ROM decrypter becoming available in the near-future?
Well... there is one ;). ctrtool is capable of decrypting ROMs, provided you have the right NCCH key(AES-CTR 128bit) for the ROM. And before you ask, no retail NCCH keys will probably be found in the near future.
Damn. I just wanna peek inside some games! D:
You and me both, particularly Kingdom Hearts 3D. So I assume the NCCH key of any given game is encrypted somewhere in its 3DS ROM?
No no no. You need the NCCH key to decrypt the ROM, you won't find the key anywhere in the ROM.
 

hundredhead

Well-Known Member
Newcomer
Joined
Feb 18, 2009
Messages
61
Trophies
0
XP
177
Country
United States
DECRYPTED game = you can run the game on an emulator (but you need to make one first) You can also see the files inside and examine them. That DOESN'T necessarily mean you can RE-ENCRYPT a changed version and put it BACK on the card to play it or run homebrew. It's often a one-way thing, especially when it also needs to be SIGNED (something else that's different from decryption and we can't necessarily do yet.)
Actually that's wrong. Signing and encrypting are the same thing, at least when it comes to any videogame console I know about. The 3DS uses RSA for game encryption. It's an asymetric encryption, which (in simple terms) means, that even if you have the decryption key, you still don't have the encryption key. The encryption key, can't be found in the 3DS itself. It's kept somewhere at Nintendo to sign the final games. Not even devs have it. It works by using a math problem, where the equasion in one direction is really simple but in the other would take all the computers in the world the age of the universe to calculate.
Well you are partly right. Though clearly you haven't read the rest of the thread. The signatures in files used with the 3DS, do use RSA encryption. But everything else uses AES encryption. And in the case of NCCH files, the encryption of the game data uses AES-CTR, where the encryption key is the same as the encryption key.
Is there at least a fair chance of a ROM decrypter becoming available in the near-future?
Well... there is one ;). ctrtool is capable of decrypting ROMs, provided you have the right NCCH key(AES-CTR 128bit) for the ROM. And before you ask, no retail NCCH keys will probably be found in the near future.
Damn. I just wanna peek inside some games! D:
You and me both, particularly Kingdom Hearts 3D. So I assume the NCCH key of any given game is encrypted somewhere in its 3DS ROM?
No no no. You need the NCCH key to decrypt the ROM, you won't find the key anywhere in the ROM.

What does this mean for the stupid people?
 

Deleted member 194275

Edson Arantes do Nascimento
Member
Joined
Aug 19, 2009
Messages
2,685
Trophies
2
XP
4,351
What does this mean for the stupid people?

It means that this topic will lead us to no new knowledge. Everything that is been said here for the last 20 pages is information available at 3DBrew since January or even early.

There are nobody of so called "hacking scene" reading or writing anything here.

PS.: You are not "stupid people". Nobody here is really into "3DS Hacking process" anyways.
 
  • Like
Reactions: 1 person
Status
Not open for further replies.

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    Psionic Roshambo @ Psionic Roshambo: https://www.youtube.com/watch?v=BjK2lPBzGzo