Editing Kirk

Jump to navigation Jump to search
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.

Latest revision Your text
Line 982: Line 982:
== Command 0x12: verify certificate ==
== Command 0x12: verify certificate ==


This command verifies an AES-CBC-MAC (OMAC1) signature. It is used to verify [[IDStorage#IDStorage_certified_sections|ID Storage certificates]].  
This command verifies an AES-CBC-MAC (OMAC1) signature. It is used to verify IdStorage IDPS certificates.  


This command has no output.
This command has no output.


It takes as input an [[IDStorage#IDStorage_certified_sections|ID Storage certificate]] read from [[IDStorage]].
It takes as input a <code>ids_cert_psp</code> certificate read from [[IDStorage]].


<source lang="C">
<source lang="C">
typedef struct ECDSA160_signature { // size is 0x28
  unsigned char r[0x14];
  unsigned char s[0x14];
} ECDSA160_signature;
typedef struct ids_cert_main_psp { // size is 0xA8
char data[0x10];
char pub_key[0x28]; // ?generated using Kirk command 0xC? sent to Kirk command 0x11 for verification
ECDSA160_signature signature;
char constant_pub_key[0x28]; // hardcoded constant, same in all PSP consoles but depends on the certificate index in ID Storage
char enc_priv_key[0x20]; // decrypted and verified by Kirk command 0x10
} ids_cert_main_psp;
typedef struct ids_cert_psp { // size is 0xB8
ids_cert_main_psp cert_data; // data input for generating enc_aes_cmac_hash
char aes_cmac[0x10]; // verified by Kirk command 0x12
} ids_cert_psp;
typedef struct kirk_command_0x12_input{
typedef struct kirk_command_0x12_input{
ids_cert_psp certificate;
ids_cert_psp certificate;
Please note that all contributions to PSP Developer wiki are considered to be released under the GNU Free Documentation License 1.2 (see PSP Developer wiki:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!

To protect the wiki against automated edit spam, we kindly ask you to solve the following hCaptcha:

Cancel Editing help (opens in new window)