Skip to content

Commit 612b64b

Browse files
committed
Added 8.20 Support
1 parent 98685bb commit 612b64b

2 files changed

Lines changed: 158 additions & 2 deletions

File tree

prosper0gdb/offsets.c

Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2221,6 +2221,100 @@ DEF(lapic_map, 0x28cf838)
22212221
#include "offset_list.txt"
22222222
END_FW()
22232223

2224+
START_FW(820)
2225+
DEF(allproc, 0x2875d50)
2226+
DEF(idt, 0x2eb3df0)
2227+
DEF(gdt_array, 0x2eb50d0)
2228+
DEF(tss_array, 0x2eb6ad0)
2229+
DEF(pcpu_array, 0x2ec8a00)
2230+
DEF(doreti_iret, -0xA28C73)
2231+
DEF(add_rsp_iret, doreti_iret - 7)
2232+
DEF(swapgs_add_rsp_iret, doreti_iret - 10)
2233+
DEF(rep_movsb_pop_rbp_ret, -0x9EC5C6)
2234+
DEF(rdmsr_start, -0xA2A3AA)
2235+
DEF(wrmsr_ret, -0xA2B77C)
2236+
DEF(dr2gpr_start, -0xA2FD93)
2237+
DEF(gpr2dr_1_start, -0xA2FC7A)
2238+
DEF(gpr2dr_2_start, -0xA2FB87)
2239+
DEF(mov_cr3_rax_mov_ds, -0xA2F7E9)
2240+
DEF(mov_rax_cr3, -0x3B721F)
2241+
DEF(nop_ret, wrmsr_ret + 2)
2242+
DEF(cpu_switch, -0xA2FF80)
2243+
DEF(mprotect_fix_start, -0x965114)
2244+
DEF(mprotect_fix_end, mprotect_fix_start+6)
2245+
2246+
DEF(mmap_self_fix_1_start, -0x0)
2247+
DEF(mmap_self_fix_1_end, mmap_self_fix_1_start+2)
2248+
DEF(mmap_self_fix_2_start, -0x0)
2249+
DEF(mmap_self_fix_2_end, mmap_self_fix_2_start+2)
2250+
2251+
DEF(aslr_fix_start, -0x8B12A1)
2252+
DEF(aslr_fix_end, aslr_fix_start+2)
2253+
2254+
DEF(sigaction_fix_start, -0x708140)
2255+
DEF(sigaction_fix_end, -0x708124)
2256+
DEF(sysents, 0x1a7db0)
2257+
DEF(sysents_ps4, 0x19f800)
2258+
DEF(sysentvec, 0xE21CA8)
2259+
DEF(sysentvec_ps4, 0xE21E20)
2260+
DEF(sceSblServiceMailbox, -0x6C4430)
2261+
DEF(sceSblAuthMgrSmIsLoadable2, -0x900F10)
2262+
DEF(mdbg_call_fix, -0x66EFC9)
2263+
DEF(syscall_before, -0x856F71)
2264+
DEF(syscall_after, -0x856F4D)
2265+
DEF(malloc, -0xB9E90)
2266+
DEF(M_something, 0x1457980)
2267+
DEF(loadSelfSegment_epilogue, -0x9007EB)
2268+
DEF(loadSelfSegment_watchpoint, -0x2EB8F8)
2269+
DEF(loadSelfSegment_watchpoint_lr, -0x900A57)
2270+
DEF(decryptSelfBlock_watchpoint_lr, -0x9006BF)
2271+
DEF(decryptSelfBlock_epilogue, -0x9005FE)
2272+
//DEF(decryptMultipleSelfBlocks_watchpoint_lr, -0x8FFF81) //403
2273+
DEF(decryptMultipleSelfBlocks_watchpoint_lr, -0x8FFF88)
2274+
DEF(decryptMultipleSelfBlocks_epilogue, -0x8FFD57)
2275+
DEF(sceSblServiceMailbox_lr_verifyHeader, -0x900BF7)
2276+
DEF(sceSblServiceMailbox_lr_loadSelfSegment, -0x90085F)
2277+
DEF(sceSblServiceMailbox_lr_decryptSelfBlock, -0x90029D)
2278+
DEF(sceSblServiceMailbox_lr_decryptMultipleSelfBlocks, -0x8FFAB3)
2279+
DEF(sceSblServiceMailbox_lr_sceSblAuthMgrSmFinalize, -0x900F88)
2280+
DEF(sceSblServiceMailbox_lr_verifySuperBlock, -0x9A5693)
2281+
DEF(sceSblServiceMailbox_lr_sceSblPfsClearKey_1, -0x9A5C11)
2282+
DEF(sceSblServiceMailbox_lr_sceSblPfsClearKey_2, -0x9A5BA5)
2283+
DEF(sceSblServiceMailbox_lr_npdrm_cmd_5, -0x33C403)
2284+
DEF(sceSblServiceMailbox_lr_npdrm_cmd_6, -0x33C1D5)
2285+
//DEF(sceSblPfsSetKeys, -0x9A5930) //403
2286+
DEF(sceSblPfsSetKeys, -0x9A6780)
2287+
DEF(sceSblServiceCryptAsync, -0x946F60)
2288+
DEF(sceSblServiceCryptAsync_deref_singleton, -0x946F23)
2289+
DEF(copyin, -0x9ECE90)
2290+
DEF(copyout, -0x9ECF40)
2291+
DEF(crypt_message_resolve, -0x49C990)
2292+
DEF(justreturn, -0xA28EA0)
2293+
DEF(justreturn_pop, justreturn+8)
2294+
DEF(mini_syscore_header, 0xED4FA8)
2295+
DEF(pop_all_iret, -0xA28CD2)
2296+
DEF(pop_all_except_rdi_iret, pop_all_iret+4)
2297+
DEF(push_pop_all_iret, -0x9ca2b8)
2298+
DEF(kernel_pmap_store, 0x2e48848)
2299+
DEF(crypt_singleton_array, 0x2d8d830)
2300+
DEF(security_flags, 0xAC3064)
2301+
DEF(targetid, 0xAC306D)
2302+
DEF(qa_flags, 0xAC3088)
2303+
DEF(utoken, 0xAC30F0)
2304+
DEF(mov_rax_cr0, -0xA2FEE1)
2305+
DEF(mov_cr0_rax, -0xA2FEDC)
2306+
DEF(mov_rdi_cr2, -0xA2C10A)
2307+
DEF(lgdt_rdi, -0x9EC7A0)
2308+
DEF(lidt_lldt, -0xA2F731)
2309+
DEF(ltr_ax, -0xA2F70F)
2310+
DEF(kproc_shutdown, -0x9c6908)
2311+
DEF(s_shutdown_final, 0x379133)
2312+
DEF(eventhandler_register, -0x54B1C0)
2313+
DEF(strlen_trap, -0x46ACB8)
2314+
DEF(lapic_map, 0x28cf838)
2315+
#include "offset_list.txt"
2316+
END_FW()
2317+
22242318
void* dlsym(void*, const char*);
22252319

22262320
int set_offsets(void)
@@ -2252,6 +2346,7 @@ int set_offsets(void)
22522346
case 0x760: set_offsets_760(); break;
22532347
case 0x761: set_offsets_761(); break;
22542348
case 0x800: set_offsets_800(); break;
2349+
case 0x820: set_offsets_820(); break;
22552350
#endif
22562351
default: return -1;
22572352
}

ps5-kstuff/main.c

Lines changed: 63 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1102,6 +1102,38 @@ static struct shellcore_patch shellcore_patches_800[] = {
11021102
{0x6b77b0, "\x48\x31\xc0\xc3", 4}, // PKG Installer
11031103
};
11041104

1105+
static struct shellcore_patch shellcore_patches_820[] = {
1106+
{0xBAF83E, "\x52\xeb\x08", 3}, //push rdx; jmp 0xBAF849 **
1107+
{0xBAF849, "\xe8\xe2\xf8\xff\xff\x58\xc3", 7}, //call 0xBAF130; pop rax; ret
1108+
{0xBAF121, "\xe9\xae\xfd\xff\xff", 5}, // jmp 0xBAEED4 **
1109+
{0xBAEED4, "\x31\xc0\x50\xe8\x54\x02\x00\x00\x58\xc3", 10}, //xor eax, eax; push rax; call 0xBAF130; pop rax; ret
1110+
{0x6B5673, "\xeb\x04", 2},
1111+
{0x2f1d22, "\xeb\x04", 2},
1112+
{0x2f2172, "\xeb\x04", 2},
1113+
{0x6d4b71, "\xeb", 1},
1114+
{0x6bd8b5, "\x90\xe9", 2},
1115+
{0x6d58bd, "\xeb", 1},
1116+
{0x6d6e39, "\x61\x01\x00\x00", 4}, // 0x6D6F9E **
1117+
{0x1f72e2, "\xe8\x29\x6b\x5c\x00\x31\xc9\xff\xc1\xe9\xb3\x02\x00\x00", 14}, // call 0x7BDE10; xor ecx; inc ecx; jmp 0x1f75a3
1118+
{0x1f75a3, "\x83\xf8\x02\x0f\x43\xc1\xe9\xa7\xfb\xff\xff", 11},//cmp eax, 2; cmovae eax, ecx; jmp 0x1F7155
1119+
{0x1f6f9e, "\xe9\x3f\x03\x00\x00", 5}, // JMP 0x1f72e2
1120+
1121+
{0x6F3870, "\xC3", 1}, // callback to sceRifManagerRegisterActivationCallback
1122+
1123+
{0x1607a20, "\x31\xc0\xc3", 3}, // VR2 Min Fw Check
1124+
{0xa33f36, "\xeb\x03", 2}, // disable game error message
1125+
{0x2ea7bb, "\x90\xe9", 2}, // PS4 Disc Installer Patch 1
1126+
{0x2ea839, "\x90\xe9", 2}, // PS5 Disc Installer Patch 1
1127+
{0x2ea93c, "\xeb", 1}, // PS4 PKG Installer Patch 1
1128+
{0x2eaa10, "\xeb", 1}, // PS5 PKG Installer Patch 1
1129+
{0x2eadf7, "\x90\xe9", 2}, // PS4 PKG Installer Patch 2
1130+
{0x2eaf7f, "\xeb", 1}, // PS5 PKG Installer Patch 2
1131+
{0x2eb33e, "\x90\xe9", 2}, // PS4 PKG Installer Patch 3
1132+
{0x2eb3d1, "\x90\xe9", 2}, // PS5 PKG Installer Patch 3
1133+
{0x6b438a, "\xeb", 1}, // PS4 PKG Installer Patch 4
1134+
{0x6b71d4, "\xeb", 1}, // PS5 PKG Installer Patch 4
1135+
{0x6ba660, "\x48\x31\xc0\xc3", 4}, // PKG Installer
1136+
};
11051137

11061138
extern char _start[];
11071139

@@ -1190,7 +1222,8 @@ static const struct shellcore_patch* get_shellcore_patches(size_t* n_patches)
11901222
FW(740);
11911223
FW(760);
11921224
FW(761);
1193-
FW(800);
1225+
FW(800);
1226+
FW(820);
11941227
default:
11951228
*n_patches = 1;
11961229
return 0;
@@ -1806,6 +1839,31 @@ static struct PARASITES(14) parasites_800 = {
18061839
}
18071840
};
18081841

1842+
static struct PARASITES(14) parasites_820 = {
1843+
.lim_syscall = 3,
1844+
.lim_fself = 12,
1845+
.lim_total = 14,
1846+
.parasites = {
1847+
/* syscall parasites */
1848+
{-0x85747E, R13},
1849+
{-0x3ACFBC, RSI},
1850+
{-0x3ACF7C, RSI},
1851+
/* fself parasites */
1852+
{-0x2EB6E6, RAX},
1853+
{-0x2EC238, RAX},
1854+
{-0x2EC100, RAX},
1855+
{-0x2EBE6B, RAX},
1856+
{-0x2EBB9D, RAX},
1857+
{-0x2EB866, RAX},
1858+
{-0x2EB85A, RAX},
1859+
{-0x9ED0EC, RDI},
1860+
{-0x2EBCD7, RAX},
1861+
/* unsorted parasites */
1862+
{-0x49C69F, RAX},
1863+
{-0x49C69F, R15},
1864+
}
1865+
};
1866+
18091867
static struct parasite_desc* get_parasites(size_t* desc_size)
18101868
{
18111869
uint32_t ver = r0gdb_get_fw_version() >> 16;
@@ -1880,7 +1938,10 @@ static struct parasite_desc* get_parasites(size_t* desc_size)
18801938
return (void*)&parasites_761;
18811939
case 0x800:
18821940
*desc_size = sizeof(parasites_800);
1883-
return (void*)&parasites_800;
1941+
return (void*)&parasites_800;
1942+
case 0x820:
1943+
*desc_size = sizeof(parasites_820);
1944+
return (void*)&parasites_820;
18841945
default:
18851946
return 0;
18861947
#else

0 commit comments

Comments
 (0)