Skip to content

Commit

Permalink
This is probably better
Browse files Browse the repository at this point in the history
  • Loading branch information
asdfugil committed Mar 4, 2024
1 parent c31b0ba commit 36d6d31
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions checkra1n/kpf/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -2049,8 +2049,7 @@ bool static_binaries_old_callback(struct xnu_pf_patch* patch, uint32_t* opcode_s
DEVLOG("parse_machfile: Found depth==2 check");

// Step 3: We skip over the dylinker-specific code path and find the call to common code
uint32_t* cbz = find_next_insn(&dylinker_stream[3], 3, 0xb4000000, 0xff000000); // cbz
uint32_t* common_stream = cbz + 1;
uint32_t* common_stream = find_next_insn(&dylinker_stream[3], 3, 0xb4000000, 0xff000000); // cbz

// Step 4: Actually patch the check for static binary to point to the common code
if ((opcode_stream[0] & 0xfff80010) == 0x36100000) { // tbz
Expand Down

0 comments on commit 36d6d31

Please sign in to comment.