1
0
Fork 0
mirror of https://github.com/DarkMatterCore/nxdumptool.git synced 2024-11-26 12:12:02 +00:00

Update to v1.1.11.

This commit is contained in:
Pablo Curiel 2020-09-22 18:51:33 -04:00
parent 0259d2141e
commit 4932283d81
5 changed files with 59 additions and 40 deletions

View file

@ -33,7 +33,7 @@ include $(DEVKITPRO)/libnx/switch_rules
VERSION_MAJOR := 1 VERSION_MAJOR := 1
VERSION_MINOR := 1 VERSION_MINOR := 1
VERSION_MICRO := 10 VERSION_MICRO := 11
APP_TITLE := nxdumptool APP_TITLE := nxdumptool
APP_AUTHOR := DarkMatterCore APP_AUTHOR := DarkMatterCore

View file

@ -71,6 +71,14 @@ Thanks to
Changelog Changelog
-------------- --------------
**v1.1.11:**
* Built using libnx `f01fb21`.
* The application will now only attempt to decrypt the eTicket device RSA keypair if the target title uses a ticket with personalized titlekey crypto, instead of always decrypting it regardless of the ticket crypto type.
* Fixed a NSP dumping issue where the decrypted titlekey wasn't being set for the current NCA if both the ticket and the decrypted titlekey were retrieved while parsing a previous NCA. Big thanks to [sadboys2001](https://github.com/sadboys2001) for reporting it.
This is only a bugfix release. I don't expect to release any new versions until the rewrite is finished - the only exception being fixing some kind of feature-breaking bug. Please understand.
**v1.1.10:** **v1.1.10:**
* Built using libnx v3.1.0. * Built using libnx v3.1.0.

View file

@ -930,6 +930,7 @@ int retrieveNcaTikTitleKey(nca_header_t *dec_nca_header, u8 *out_tik, u8 *out_en
if (!foundRightsId || (rightsIdType != 1 && rightsIdType != 2)) if (!foundRightsId || (rightsIdType != 1 && rightsIdType != 2))
{ {
uiDrawString(STRING_X_POS, STRING_Y_POS(breaks), FONT_COLOR_ERROR_RGB, "%s: NCA rights ID unavailable in this console!", __func__); uiDrawString(STRING_X_POS, STRING_Y_POS(breaks), FONT_COLOR_ERROR_RGB, "%s: NCA rights ID unavailable in this console!", __func__);
breaks++;
ret = -2; ret = -2;
return ret; return ret;
} }
@ -937,6 +938,8 @@ int retrieveNcaTikTitleKey(nca_header_t *dec_nca_header, u8 *out_tik, u8 *out_en
// Load external keys // Load external keys
if (!loadExternalKeys()) return ret; if (!loadExternalKeys()) return ret;
if (rightsIdType == 2)
{
if (!setcal_eticket_retrieved) if (!setcal_eticket_retrieved)
{ {
// Get extended eTicket RSA key from PRODINFO // Get extended eTicket RSA key from PRODINFO
@ -982,6 +985,7 @@ int retrieveNcaTikTitleKey(nca_header_t *dec_nca_header, u8 *out_tik, u8 *out_en
if (!testKeyPair(E, D, N)) return ret; if (!testKeyPair(E, D, N)) return ret;
setcal_eticket_retrieved = true; setcal_eticket_retrieved = true;
} }
}
eTicketSave = calloc(1, sizeof(FIL)); eTicketSave = calloc(1, sizeof(FIL));
if (!eTicketSave) if (!eTicketSave)
@ -1122,6 +1126,7 @@ int retrieveNcaTikTitleKey(nca_header_t *dec_nca_header, u8 *out_tik, u8 *out_en
if (!foundEticket) if (!foundEticket)
{ {
uiDrawString(STRING_X_POS, STRING_Y_POS(breaks), FONT_COLOR_ERROR_RGB, "%s: unable to find a matching eTicket entry for NCA rights ID!", __func__); uiDrawString(STRING_X_POS, STRING_Y_POS(breaks), FONT_COLOR_ERROR_RGB, "%s: unable to find a matching eTicket entry for NCA rights ID!", __func__);
breaks++;
ret = -2; ret = -2;
return ret; return ret;
} }

View file

@ -837,7 +837,13 @@ bool retrieveTitleKeyFromGameCardTicket(title_rights_ctx *rights_info, u8 *decry
} }
// Check if the ticket has already been retrieved from the HFS0 partition in the gamecard // Check if the ticket has already been retrieved from the HFS0 partition in the gamecard
if (rights_info->retrieved_tik) return true; if (rights_info->retrieved_tik)
{
// Save the decrypted NCA key area keys
memset(decrypted_nca_keys, 0, NCA_KEY_AREA_SIZE);
memcpy(decrypted_nca_keys + (NCA_KEY_AREA_KEY_SIZE * 2), rights_info->dec_titlekey, 0x10);
return true;
}
// Load external keys // Load external keys
if (!loadExternalKeys()) return false; if (!loadExternalKeys()) return false;

View file

@ -908,7 +908,7 @@ static bool initServices()
initPmdmnt = true; initPmdmnt = true;
/* Initialize pl service */ /* Initialize pl service */
result = plInitialize(); result = plInitialize(PlServiceType_User);
if (R_FAILED(result)) if (R_FAILED(result))
{ {
consoleErrorScreen("%s: failed to initialize pl service! (0x%08X)", __func__, result); consoleErrorScreen("%s: failed to initialize pl service! (0x%08X)", __func__, result);