MINOR: tcp: add custom actions that can continue tcp-(request|response) processing

Actually, the tcp-request and tcp-response custom ation are always final
actions. This patch create a new type of action that can permit to
continue the evaluation of tcp-request and tcp-response processing.
This commit is contained in:
Thierry FOURNIER 2015-05-29 17:29:14 +02:00 committed by Willy Tarreau
parent b3971ab062
commit 561a0f989d
2 changed files with 9 additions and 4 deletions

View File

@ -40,6 +40,7 @@ enum {
TCP_ACT_CLOSE, /* close at the sender's */
TCP_ACT_CAPTURE, /* capture a fetched sample */
TCP_ACT_CUSTOM, /* Use for custom registered keywords. */
TCP_ACT_CUSTOM_CONT, /* Use for custom registered keywords. */
};
struct capture_prm {

View File

@ -1221,8 +1221,10 @@ int tcp_inspect_request(struct stream *s, struct channel *req, int an_bit)
goto missing_data;
}
/* otherwise accept */
break;
/* accept */
if (rule->action == TCP_ACT_CUSTOM)
break;
/* otherwise continue */
}
}
}
@ -1342,8 +1344,10 @@ int tcp_inspect_response(struct stream *s, struct channel *rep, int an_bit)
return 0;
}
/* otherwise accept */
break;
/* accept */
if (rule->action == TCP_ACT_CUSTOM)
break;
/* otherwise continue */
}
}
}