From 805788e0434f4f09d8049c51000af604efb800ed Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Wed, 21 Mar 2012 23:21:52 +0100 Subject: SWS: refuse to serve CONNECT unless running as proxy --- tests/server/sws.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/server/sws.c b/tests/server/sws.c index dddc606db..ef54bc65e 100644 --- a/tests/server/sws.c +++ b/tests/server/sws.c @@ -1944,7 +1944,11 @@ int main(int argc, char *argv[]) if(DOCNUMBER_CONNECT == req.testno) { /* a CONNECT request, setup and talk the tunnel */ - http_connect(&msgsock, sock, &req, hostport); + if(!is_proxy) { + logmsg("received CONNECT but isn't running as proxy! EXIT"); + } + else + http_connect(&msgsock, sock, &req, hostport); break; } -- cgit v1.2.3