]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
New squid.conf directive to disable hostname verifications. It isn't
authorhno <>
Sat, 24 Aug 2002 07:54:34 +0000 (07:54 +0000)
committerhno <>
Sat, 24 Aug 2002 07:54:34 +0000 (07:54 +0000)
really our business to enforce what characters is used in hostnames.

src/cf.data.pre
src/structs.h
src/url.cc

index 9bd73f3fe03280ef4263ef2cb5516f5ea068d125..83911c1435b4320468b96ae5cfc6fd38c2d5187c 100644 (file)
@@ -1,6 +1,6 @@
 
 #
-# $Id: cf.data.pre,v 1.276 2002/08/21 09:12:44 hno Exp $
+# $Id: cf.data.pre,v 1.277 2002/08/24 01:54:34 hno Exp $
 #
 #
 # SQUID Web Proxy Cache          http://www.squid-cache.org/
@@ -1092,6 +1092,16 @@ DOC_START
        connection then turn this off.
 DOC_END
 
+NAME: check_hostnames
+TYPE: onoff
+DEFAULT: on
+LOC: Config.onoff.check_hostnames
+DOC_START
+       For security and stability reasons Squid by default checks
+       hostnames for Internet standard RFC compliance. If you do not want
+       Squid to perform these checks then turn this directive off.
+DOC_END
+
 NAME: cache_dns_program
 TYPE: string
 IFDEF: USE_DNSSERVERS
@@ -3809,12 +3819,11 @@ LOC: Config.onoff.pipeline_prefetch
 DEFAULT: off
 DOC_START
        To boost the performance of pipelined requests to closer
-       match that of a non-proxied environment Squid tries to fetch
+       match that of a non-proxied environment Squid can try to fetch
        up to two requests in parallell from a pipeline.
 
-       Note: This is known to be broken in Squid-DEVEL due to changes
-       in the internal store_client_copy() interface. Do not enable
-       for now.
+       Defaults to off for bandwidth management and access logging
+       reasons.
 DOC_END
 
 NAME: extension_methods
index d8ffa169eb95f04bcccdcc530ead6e0057b6f092..dc1be6edd1ae22bbd388f02e6e1fdad1491cc3d3 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: structs.h,v 1.423 2002/08/09 10:57:43 robertc Exp $
+ * $Id: structs.h,v 1.424 2002/08/24 01:54:34 hno Exp $
  *
  *
  * SQUID Web Proxy Cache          http://www.squid-cache.org/
@@ -589,6 +589,7 @@ struct _SquidConfig {
        int ie_refresh;
        int vary_ignore_expire;
        int pipeline_prefetch;
+       int check_hostnames;
     } onoff;
     acl *aclList;
     struct {
index 9f242a4ab845f114d2cc16b7eba6d883347e292a..b7e3ca9239a4eb24a22ad8c05443c036920a930e 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: url.cc,v 1.135 2002/08/19 22:47:54 hno Exp $
+ * $Id: url.cc,v 1.136 2002/08/24 01:54:34 hno Exp $
  *
  * DEBUG: section 23    URL Parsing
  * AUTHOR: Duane Wessels
@@ -304,7 +304,7 @@ urlParse(method_t method, char *url)
            *q = '\0';
        }
     }
-    if (strspn(host, valid_hostname_chars) != strlen(host)) {
+    if (Config.onoff.check_hostnames && strspn(host, valid_hostname_chars) != strlen(host)) {
        debug(23, 1) ("urlParse: Illegal character in hostname '%s'\n", host);
        return NULL;
     }