View Single Post
  #4  
Old 07-21-2018, 05:05
ionioni ionioni is offline
Friend
 
Join Date: Jul 2016
Posts: 80
Rept. Given: 8
Rept. Rcvd 3 Times in 3 Posts
Thanks Given: 124
Thanks Rcvd at 154 Times in 49 Posts
ionioni Reputation: 3
Quote:
Originally Posted by vic4key View Post
ADD RSP, 40 ; Cleanup the stack... ; Not needed. The LEAVE instruction did it.
Quote:
Originally Posted by Insid3Code View Post
Hi Vic,
Are you already tested your snippets ?
Attached, both snippets (allocate/align) and binaries (one crash the other works fine)

I don't know if you can download the attachment from this topic, here external link:
PHP Code:
http://www.mediafire.com/file/s9dd88iel47s7h8/poc.rar 
Compiled and tested (MSVC 2017 15.7.3)
leave is short for
mov rsp, rbp
pop rbp

lose "add rsp, ..."
Reply With Quote
The Following 2 Users Say Thank You to ionioni For This Useful Post:
niculaita (07-21-2018), vic4key (07-21-2018)