Format String Vulnerability
Format String Vulnerability
int c;
printf (“%d”,c);
• Below are some format parameters which can be used and their consequences:
“%x” Read data from the stack
“%s” Read character strings from the process’ memory
“%n” Write an integer to locations in the process’ memory
Common parameters used in a Format String Attack.
External representation of
%p Reference
a pointer to void
%d Decimal Value
%c Character
%x Hexadecimal Value
%s String Reference
Demo
A simple C Program with format string Vulnerability
Demo
END