Skip to content
Permalink
Browse files

update submod

  • Loading branch information...
Reisyukaku committed Nov 3, 2019
1 parent cee0a21 commit 52f300673d641be80c6ea387e0435e507ecd30d6
Showing with 6 additions and 7 deletions.
  1. +0 −3 Makefile
  2. +1 −1 NX_Sysmodules
  3. +1 −1 src/package.c
  4. +2 −2 src/patches.c
  5. +2 −0 src/patches.h
@@ -56,16 +56,13 @@ $(dir_out)/sysmodules: $(dir_sysmod)
@cp $(dir_sysmod)/sm/sm.kip $(dir_out)/ReiNX/sysmodules/
@cp $(dir_sysmod)/pm/pm.kip $(dir_out)/ReiNX/sysmodules/
@cp $(dir_sysmod)/rnx_mitm/rnx_mitm.kip $(dir_out)/ReiNX/sysmodules/
@cp $(dir_sysmod)/spl/spl.kip $(dir_out)/ReiNX/sysmodules/
@cp $(dir_sysmod)/boot/boot.kip $(dir_out)/ReiNX/sysmodules/
@mkdir -p "$(dir_out)/ReiNX/titles/0100000000000034"
@mkdir -p "$(dir_out)/ReiNX/titles/0100000000000036"
@mkdir -p "$(dir_out)/ReiNX/titles/0100000000000037"
@mkdir -p "$(dir_out)/ReiNX/titles/010000000000000D/flags"
@cp $(dir_sysmod)/fatal/fatal.nsp $(dir_out)/ReiNX/titles/0100000000000034/exefs.nsp
@cp $(dir_sysmod)/dmnt/dmnt.nsp $(dir_out)/ReiNX/titles/010000000000000D/exefs.nsp
@cp $(dir_sysmod)/creport/creport.nsp $(dir_out)/ReiNX/titles/0100000000000036/exefs.nsp
@cp $(dir_sysmod)/ro/ro.nsp $(dir_out)/ReiNX/titles/0100000000000037/exefs.nsp


$(dir_out)/$(name).bin: $(dir_build)/$(name).elf
@@ -265,7 +265,7 @@ size_t calcKipSize(pkg2_kip1_t *kip1) {
void pkg2_parse_kips(link_t *info, pkg2_hdr_t *pkg2) {
print("%kParsing KIPS%k\n", WHITE, DEFAULT_TEXT_COL);
u8 *ptr = pkg2->data + pkg2->sec_size[PKG2_SEC_KERNEL];
if (pkg2->sec_size[PKG2_SEC_INI1] == 0) {
if (!pkg2->sec_size[PKG2_SEC_INI1]) {
pkg2_get_newkern_info(pkg2->data);

ptr = pkg2->data + pkg2_newkern_ini1_start;
@@ -69,8 +69,8 @@ void patchKernel(pkg2_hdr_t *pkg2){
if(!hasCustomKern()) {
print("%kPatching Kernel...%k\n", WHITE, DEFAULT_TEXT_COL);
u8 hash[0x20];
if(pkg2->sec_size[PKG2_SEC_INI1] == 0) {
se_calc_sha256(hash, (void*)(pkg2->data + 0x800), GetNewKernIniStart() - 0x800); //TODO unhardcode
if(!pkg2->sec_size[PKG2_SEC_INI1]) {
se_calc_sha256(hash, (void*)(pkg2->data + PKG2_NEWKERN_START), GetNewKernIniStart() - PKG2_NEWKERN_START); //TODO unhardcode
//*((vu64 *)((uPtr)pkg2->data + 0x168)) = (u64)pkg2->sec_size[PKG2_SEC_KERNEL];
printHex((void*)hash, 0x20);
}else{
@@ -22,6 +22,8 @@
#include "error.h"
#include "kippatches/fs.inc"

#define PKG2_NEWKERN_START 0x800

//FS_MITM
static u32 PRC_ID_SND_100[] =
{

0 comments on commit 52f3006

Please sign in to comment.
You can’t perform that action at this time.