In memory of Ben “bushing” Byer, who passed away on Monday, February 8th, 2016.

/sys/uid.sys

From WiiBrew
Jump to navigation Jump to search
/sys/uid.sys
TypeGeneric file
OwnerIOS
Group ID0

/sys/uid.sys is a list of TitleID-UID pairs. UIDs are used for ownership on the Wii filesystem.

The first entry in the file is always the System Menu, with UID 0x1000. UIDs iterate from that number. It may not be necessary for the first entry to be 1-2/0x1000, but it's probably a good idea to keep it that way.

On the filesystem, ownership is normally used to gives titles access to their "data" directories.

uid.sys is often used by homebrewers to have a record of what titles have been installed on a console (and the order they were loaded), as IOS does not remove title IDs from this table when it deletes titles.

Creation

This file would probably be created by any IOS when attempting to install a title if it does not already exist, however, in practice, it is created by boot2v0 when it loads the 1-2 title for the first time, to assign this title a UID of 0x1000.

File structure

typedef struct
{
	u64 title_id;
	u32 uid;
} uid_entry;

typedef uid_entry uidsys[]; // any number of entries