From bcbc11b09d52aad0b6441ae79f79af2559bdf90e Mon Sep 17 00:00:00 2001 From: wessels <> Date: Wed, 16 Dec 1998 00:33:58 +0000 Subject: [PATCH] strip_query_terms option --- src/cf.data.pre | 12 +++++++++++- src/structs.h | 3 ++- src/url.cc | 7 ++++--- 3 files changed, 17 insertions(+), 5 deletions(-) diff --git a/src/cf.data.pre b/src/cf.data.pre index c5a2dbc945..9601f27c67 100644 --- a/src/cf.data.pre +++ b/src/cf.data.pre @@ -1,6 +1,6 @@ # -# $Id: cf.data.pre,v 1.130 1998/12/11 20:06:50 wessels Exp $ +# $Id: cf.data.pre,v 1.131 1998/12/15 17:34:00 wessels Exp $ # # # SQUID Internet Object Cache http://squid.nlanr.net/Squid/ @@ -2764,4 +2764,14 @@ DOC_START prefer_direct on DOC_END +NAME: strip_query_terms +TYPE: onoff +LOC: Config.onoff.strip_query_terms +DEFAULT: on +DOC_START + By default, Squid strips query terms from requested URLs before + logging. This protects your user's privacy. +strip_query_terms on +DOC_END + EOF diff --git a/src/structs.h b/src/structs.h index 1fe89e700d..74ccd10ad7 100644 --- a/src/structs.h +++ b/src/structs.h @@ -1,7 +1,7 @@ /* - * $Id: structs.h,v 1.253 1998/12/11 20:06:52 wessels Exp $ + * $Id: structs.h,v 1.254 1998/12/15 17:33:58 wessels Exp $ * * * SQUID Internet Object Cache http://squid.nlanr.net/Squid/ @@ -352,6 +352,7 @@ struct _SquidConfig { int redir_rewrites_host; int persistent_client_posts; int prefer_direct; + int strip_query_terms; } onoff; acl *aclList; struct { diff --git a/src/url.cc b/src/url.cc index fc0853dbc0..72cdcf3b52 100644 --- a/src/url.cc +++ b/src/url.cc @@ -1,6 +1,6 @@ /* - * $Id: url.cc,v 1.110 1998/12/09 04:16:48 wessels Exp $ + * $Id: url.cc,v 1.111 1998/12/15 17:33:59 wessels Exp $ * * DEBUG: section 23 URL Parsing * AUTHOR: Duane Wessels @@ -351,8 +351,9 @@ urlCanonicalClean(const request_t * request) /* * strip arguments AFTER a question-mark */ - if ((t = strchr(buf, '?'))) - *(++t) = '\0'; + if (Config.onoff.strip_query_terms) + if ((t = strchr(buf, '?'))) + *(++t) = '\0'; break; } } -- 2.47.2