From 1a9acbd3b7ef34a701ad521e332948b050453d05 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20L=C3=B3pez=20Guimaraes?= Date: Sat, 6 Jul 2024 13:48:49 +0100 Subject: [PATCH] ios_mcp: Add DLP permission group to all titles This allows usage of nn_dlp from homebrew. --- source/ios_mcp/source/mcp_loadfile.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/source/ios_mcp/source/mcp_loadfile.c b/source/ios_mcp/source/mcp_loadfile.c index 392e315..8440f58 100644 --- a/source/ios_mcp/source/mcp_loadfile.c +++ b/source/ios_mcp/source/mcp_loadfile.c @@ -515,8 +515,16 @@ int _MCP_ReadCOSXml_patch(uint32_t u1, uint32_t u2, MCPPPrepareTitleInfo *xmlDat xmlData->avail_size = 0; xmlData->overlay_arena = 0; + bool dlpPatched = false; + // Give us full permissions everywhere for (uint32_t i = 0; i < 19; i++) { + // Add DLP permission group to all titles + if (!dlpPatched && xmlData->permissions[i].group == 0) { + xmlData->permissions[i].group = 25; // DLP + dlpPatched = true; + } + xmlData->permissions[i].mask = 0xFFFFFFFFFFFFFFFF; }