Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #define CEMU_CONSOLE ((char*)0xFB0000)
- void exit_err(int error){
- sprintf(CEMU_CONSOLE, "Exit Code: %u\n", error);
- exit(0);
- }
- int main(void)
- {
- const char *fname = "TIAuthKF";
- tinyauth_error_t err;
- char *username;
- uint8_t *signature;
- size_t username_len, signature_len;
- err = tinyauth_load_key(fname, "<your password here>");
- if(err) exit_err(err);
- err = tinyauth_get_credentials(&username, &username_len, &signature, &signature_len);
- if(err) exit_err(err);
- sprintf(CEMU_CONSOLE, "__TInyAuth Keyfile Extracted Credentials__\n");
- uint8_t tbuf[username_len + 1];
- memset(tbuf, 0, sizeof(tbuf));
- memcpy(tbuf, username, username_len);
- sprintf(CEMU_CONSOLE, "%s\n", tbuf);
- for(int i = 0; i < signature_len; i++)
- sprintf(CEMU_CONSOLE, "%02X", ((uint8_t*)signature)[i]);
- sprintf(CEMU_CONSOLE, "\n");
- tinyauth_cleanup();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement