Accessing Stack to get Function Arguments
Posted on 2004-10-28
[Working on LINUX]
I have an a.out file( compiled without debugging info I.E. gcc <filename>). Source is not availbale.
I want to find out the details of the user defined function parameters( not system call parameters or library call parameters.)
I know that with the help of EBP + offset, i can get the function parameters.
Right now i am using ptrace to trace my a.out object file. But i am not able to get the values properly. Can anyone direct me to a source of information on this aspect or suggest me a tool. I have tried fenris which gives only first function parameter but not all. Even if the tool is a binary instrumentation tool, i dont mind using it.