I am trying to debug a simple buffer overflow program using gdb . I analyzed the program on windows without any issues .But now i am using linux gdb with exact same program but i am getting "Cannot access memory at address 0xffffffffffffdfa0" error while accessing esp and a variable. enter image description here

Can anyone help me out thanks

  • 2
    Include code as a text Jun 20 '18 at 15:43
  • Even when using RSP or SP keeps giving me the "Cannot access memory" error. Any help would be appriciated. Dec 7 '18 at 6:48

Try examining rsp instead of esp.


It is similar for stack pointer too. sp->16-bit, esp->32-bits and rsp->64-bit. When you are examining the esp, the address is actually 64 bits but you are trying examine and forcing it to split to 32 bits addresses.

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.