I'm writing a program that involves traversing the stack, and I need to find out how to locate the current base pointer without information about the current function. I know there is a way to do it with just regular C code (as opposed to inline assembly, etc.).
I know that there are some things that have a fixed location from the current ebp, such as function arguments or where the return address is stored, so if I knew the address of these, I could find ebp, but I have no idea how to access these addresses. Does anyone have insight or suggestions?