How to do it...

Use the below steps to review the binary containing the decoder stub.

  1. Run the signature detection script against the binary by typing the following in the open Terminal session:
$ ./sigDetect.py ch09-revshell64-decoder
  1. Next, run objdump against the binary:
$ objdump -d -M intel ch09-revshell64-decoder
  1. After reviewing the output, let's look at the binary in EDB:
$ edb --run ./ch09-revshell64-decoder
  1. Next, press the Run button so that EDB hits the breakpoint on the main function within the binary.
  2. Left-click and highlight the call rdx instruction at 004004ef and press F2 on the keyboard to place a breakpoint.
  3. Press the Run button so that EDB hits the breakpoint.
  4. Step into the call rdx instruction by pressing the Step Into button.
  5. Press the Step Into button.
  6. Press the Step Into button.
  7. Place a breakpoint on the jmp 0x60105c instruction at the 00601055 address by highlighting that line and pressing F2 on the keyboard.
  8. Press the Step Into button.
  9. Review the Registers window, specifically the rcx register and the r10 register.
  10. Press the Step Into button. 
  11. Continue to press the Step Into button and watch the instructions beginning at address 0060105c transform.
  12. Press the Run button to hit the breakpoint we set in step 10.
  13. Review the decoded instructions starting at address 060105c. Do they look familiar?
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
13.59.36.203