Kprx auth sm

From Vita Development Wiki
Jump to navigation Jump to search

Kernel PRX Authentication Security Module. kprx_auth_sm authenticates and decrypts SELF files.

Teardown

After authentication, SELF Attributes and Capabilities are checked through a SWI 6 call to secure_kernel.

Functions

get_metainfo_ac_info

Version offset
3.60 0x80eb8a

Check program-authority-id to get corresponding SELF Attribute and Capability.

Supported program-authority-id
Privileged program-authority-id
Game 0x2F00000000000001
Non-Game 0x2F00000000000002

Attempting to start a fSELF with an unsupported program-authority-id eventually causes the system to throw error code 0x800f0616.

Returns error code 0x800f0624 for unsupported program-authority-id.

bigmac_exec

Version offset
3.60 0x80EF46
typedef struct bigmac_exec_option {
	int channel;
	int flags; // masked by 0xFFFFFCC0
} bigmac_exec_option;

/*
 * key      - If option->flags not seted 0x80, pass to bigmac keyring
 * key_size - 0:1:2:3, 64:128:192:256
 */
int bigmac_exec(void *dst, const void *src, int size, const void *key, void *iv, int first_algo, int second_algo, int key_size, const bigmac_exec_option *pOpt);