+int is_eor(char *buf)
+{
+ int eor = 0;
+
+ /* This does not completely work, when the request is split
+ in multiple packets... */
+ if (strstr(buf, "\x0d\x0a\x0d\x0a")) {
+ eor = 1;
+ } else if (strstr(buf, "\x0a\x0a")) {
+ eor = 1;
+ } else if (strcmp(buf, "\x0d\x0a") == 0) {
+ eor = 1;
+ } else if (strcmp(buf, "\x0a") == 0) {
+ eor = 1;
+ }
+
+ return eor;
+}
+
+
+static void parse_request(int s, struct scope *sc)