summary refs log tree commit diff
diff options
context:
space:
mode:
authorJune McEnroe <programble@gmail.com>2016-10-05 23:34:03 -0400
committerJune McEnroe <programble@gmail.com>2016-10-05 23:34:03 -0400
commit886d09b4bda23006f524386ad39772e7acbbb221 (patch)
tree9f32579e536af0a168cda21fbbae0ad96b2ca015
parentBegin JRP (diff)
downloadsrc-886d09b4bda23006f524386ad39772e7acbbb221.tar.gz
src-886d09b4bda23006f524386ad39772e7acbbb221.zip
Use rbp instead of r15 in jrp
-rwxr-xr-x.bin/jrp.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/.bin/jrp.c b/.bin/jrp.c
index 615f8a97..83894342 100755
--- a/.bin/jrp.c
+++ b/.bin/jrp.c
@@ -3,9 +3,8 @@ exec cc -Wall -Wextra $@ -o $(dirname $0)/jrp $0
 #endif
 
 enum op {
-    OP_PROL = 0xfc8948e789495741, // push r15; mov r15, rsp; mov rsp, rdi
-    OP_EPIL = 0x5f41fc894ce08948, // mov rax, rsp; mov rsp, r15; pop r15
-    OP_RET  = 0x90666690666666c3, // ret
+    OP_PROL = 0x90fc8948e5894855, // push ebp; mov rbp, rsp; mov rsp, rdi
+    OP_EPIL = 0xc35dec8948e08948, // mov rax, rsp; mov rsp, rbp; pop rbp; ret
     OP_CALL = 0x90666666d0ff5f58, // pop rax; pop rdi; call rax
     OP_PUSH = 0x9066660000000068, // push strict dword 0
     OP_DROP = 0x9066666608c48348, // add rsp, 8