I looked through your "request.c", this module parse http string and save it to a REQUEST data struct.
But I suggest you use a switch statement that analyse http char array one by one , I think it will increase efficiency and it's easy to filter invalid request.
If you read the source code of "Nginx", it had used this algorithm.
I looked through your "request.c", this module parse http string and save it to a REQUEST data struct.
But I suggest you use a switch statement that analyse http char array one by one , I think it will increase efficiency and it's easy to filter invalid request.
If you read the source code of "Nginx", it had used this algorithm.