Hi guys,
I'm stuck with what kind of attack could occur to the code posted below, would it be a buffer overflow or integer overflow?
So what type of vulnerability? and if any one has any remedies that could be put in place to fix such code.


Code:
int grab_request (char buf[], int buf_len)
{
int i;
   for (i=0; i< buf_len; i++) {
       /* put things into buf */
   }
buf[i] = ‘\0’;
return i;
}