Difference between revisions of "SD:/private/wii/loc.dat"
< SD:
Jump to navigation
Jump to search
m (moved Main Page/loc.dat to Loc.dat: Preparing integration into content.bin info.) |
Hallowizer (talk | contribs) m (Navbox) |
||
(7 intermediate revisions by 5 users not shown) | |||
Line 1: | Line 1: | ||
=== Layout === | === Layout === | ||
+ | Loc.dat is encrypted using the SDKey and SD-IV values. | ||
The general layout of this file is as follows. | The general layout of this file is as follows. | ||
Line 11: | Line 12: | ||
| 0x0 | | 0x0 | ||
| 0x4 | | 0x4 | ||
− | | | + | | Magic - "sdal" |
|- | |- | ||
| 0x4 | | 0x4 | ||
Line 19: | Line 20: | ||
| 0x14 | | 0x14 | ||
| 0x3C0 | | 0x3C0 | ||
− | | | + | | List of channels on the SDMenu. (Each slot is 4 bytes. Empty slot indicated by 0x00000000.) |
|- | |- | ||
| 0x3D4 | | 0x3D4 | ||
Line 26: | Line 27: | ||
|} | |} | ||
− | + | Here's some C structures: | |
+ | <pre> | ||
+ | typedef struct | ||
+ | { | ||
+ | char tid[4]; // The lower 4 bytes of the channels Title ID. | ||
+ | } SDList; | ||
+ | |||
+ | typedef struct | ||
+ | { | ||
+ | char magic[4]; // The Magic. Always `sdal' | ||
+ | u8 md5[0x10]; // MD5 sum. Pad with MD5-Blanker. | ||
+ | SDList list[240]; // The entries. Same order as on the menu. | ||
+ | u8 padding[12]; // Padding with 0's. | ||
+ | } Locdat; | ||
+ | </pre> | ||
+ | |||
+ | Credit to CaitSith2, and Galaxy| for this finding. | ||
+ | |||
+ | {{Navbox filebrowser}} |
Latest revision as of 19:43, 20 August 2021
Layout
Loc.dat is encrypted using the SDKey and SD-IV values. The general layout of this file is as follows.
Offset | Length | Description |
---|---|---|
0x0 | 0x4 | Magic - "sdal" |
0x4 | 0x10 | File MD5 Sum (padded with MD5-blanker before hash calculation) |
0x14 | 0x3C0 | List of channels on the SDMenu. (Each slot is 4 bytes. Empty slot indicated by 0x00000000.) |
0x3D4 | 0xC | Padded with 0s. |
Here's some C structures:
typedef struct { char tid[4]; // The lower 4 bytes of the channels Title ID. } SDList; typedef struct { char magic[4]; // The Magic. Always `sdal' u8 md5[0x10]; // MD5 sum. Pad with MD5-Blanker. SDList list[240]; // The entries. Same order as on the menu. u8 padding[12]; // Padding with 0's. } Locdat;
Credit to CaitSith2, and Galaxy| for this finding.
Wii Filesystem | |||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Template:Navbox filebrowser/DirectoriesSD: | Template:Navbox filebrowser/DirectoriesSD:/private |
|