[MEDIUM] add support for RDP cookie persistence
The new statement "persist rdp-cookie" enables RDP cookie
persistence. The RDP cookie is then extracted from the RDP
protocol, and compared against available servers. If a server
matches the RDP cookie, then it gets the connection.
diff --git a/src/proxy.c b/src/proxy.c
index f6c142f..4e75b59 100644
--- a/src/proxy.c
+++ b/src/proxy.c
@@ -677,6 +677,12 @@
s->req->analysers |= AN_REQ_WAIT_HTTP | AN_REQ_HTTP_PROCESS_BE | AN_REQ_HTTP_INNER;
}
+ /* If the backend does requires RDP cookie persistence, we have to
+ * enable the corresponding analyser.
+ */
+ if (s->be->options2 & PR_O2_RDPC_PRST)
+ s->req->analysers |= AN_REQ_PRST_RDP_COOKIE;
+
return 1;
}