Line 5:
Line 5:
== Gamecard savegame Encryption ==
== Gamecard savegame Encryption ==
+
+
Gamecard encryption is AES-CTR applied on top of DISA container, but below the wear leveling layer (if exists). The same key Y used for encryption is also used for DISA CMAC signing. Several versions of encryption scheme have been introduced over the time.
+
+
{| class="wikitable" border="1"
+
|-
+
! FW Introduced
+
! Old3DS
+
! [[AES#Keyslot|AES Keyslots]] (Encryotion / CMAC)
+
! Key Y generation method
+
! Repeating CTR
+
|-
+
| The initial version
+
| style="background: #ccffbb" | Yes
+
| 0x37 / 0x33
+
| v1
+
| style="background: #ccffbb" | Yes
+
|-
+
| [[2.0.0-2]]
+
| style="background: #ccffbb" | Yes
+
| 0x37 / 0x33
+
| v2
+
| style="background: #ccffbb" | Yes
+
|-
+
| [[2.2.0-4]]
+
| style="background: #ccffbb" | Yes
+
| 0x37 / 0x33
+
| v2
+
| style="background: #ffccbb" | No
+
|-
+
| [[6.0.0-11]]
+
| style="background: #ccffbb" | Yes
+
| 0x37 / 0x33
+
| v3
+
| style="background: #ffccbb" | No
+
|-
+
| [[9.6.0-24|9.6.0-X]]
+
| style="background: #ffccbb" | No
+
| 0x1A / 0x19
+
| v2?
+
| style="background: #ffccbb" | No
+
|}
=== Repeating CTR Fail ===
=== Repeating CTR Fail ===