Examing Memory,stack and registers in a simple C program using GDB
In this post we look at how a reverse engineer can begin reverse engineering by examining the memory, stack and registers of a running process.
The code is a very simple program to add two integers passed as command line arguments and prints a string with the result
#include <stdio.h> #include <stdlib.h> int add ( int x , int y ){ int z = 10 ; z = x + y ; return z ; } main ( int argc , char ** argv ){ int a = atoi ( argv [ 1 ]...