#
-# $Id: cf.data.pre,v 1.390 2005/05/09 01:41:25 hno Exp $
+# $Id: cf.data.pre,v 1.391 2005/06/05 23:29:02 hno Exp $
#
#
# SQUID Web Proxy Cache http://www.squid-cache.org/
@DEFAULT_ICON_DIR@
DOC_END
+NAME: global_internal_static
+TYPE: onoff
+LOC: Config.onoff.global_internal_static
+DEFAULT: on
+DOC_START
+ This directive controls is Squid should intercept all requests for
+ /squid-internal-static/ no matter which host the URL is requesting
+ (default on setting), or if nothing special should be done for
+ such URLs (off setting). The purpose of this directive is to make
+ icons etc work better in complex cache hierarchies where it may
+ not always be possible for all corners in the cache mesh to reach
+ the server generating a directory listing.
+DOC_END
+
NAME: short_icon_urls
TYPE: onoff
LOC: Config.icons.use_short_names
/*
- * $Id: client_side.cc,v 1.684 2005/03/19 19:43:39 serassio Exp $
+ * $Id: client_side.cc,v 1.685 2005/06/05 23:29:02 hno Exp $
*
* DEBUG: section 33 Client-side Routines
* AUTHOR: Duane Wessels
if (internalCheck(url)) {
/* prepend our name & port */
http->uri = xstrdup(internalLocalUri(NULL, url));
- http->flags.internal = 1;
} else if (vhost && (host = mime_get_header(req_hdr, "Host")) != NULL) {
int url_sz = strlen(url) + 32 + Config.appendDomainLen +
strlen(host);
/* BUG: Squid cannot deal with '*' URLs (RFC2616 5.1.2) */
- if (internalCheck(url)) {
- /* prepend our name & port */
- http->uri = xstrdup(internalLocalUri(NULL, url));
- http->flags.internal = 1;
- } else if ((host = mime_get_header(req_hdr, "Host")) != NULL) {
+ if ((host = mime_get_header(req_hdr, "Host")) != NULL) {
int url_sz = strlen(url) + 32 + Config.appendDomainLen +
strlen(host);
http->uri = (char *)xcalloc(url_sz, 1);
} else if (internalCheck(url)) {
/* prepend our name & port */
http->uri = xstrdup(internalLocalUri(NULL, url));
- http->flags.internal = 1;
http->flags.accel = 1;
}
request->flags.transparent = http->flags.transparent;
- if (!http->flags.internal) {
- if (internalCheck(request->urlpath.buf())) {
- if (internalHostnameIs(request->host) &&
- request->port == getMyPort()) {
- http->flags.internal = 1;
- } else if (internalStaticCheck(request->urlpath.buf())) {
- xstrncpy(request->host, internalHostname(),
- SQUIDHOSTNAMELEN);
- request->port = getMyPort();
- http->flags.internal = 1;
- }
+ if (internalCheck(request->urlpath.buf())) {
+ if (internalHostnameIs(request->host) &&
+ request->port == getMyPort()) {
+ http->flags.internal = 1;
+ } else if (Config.onoff.global_internal_static && internalStaticCheck(request->urlpath.buf())) {
+ xstrncpy(request->host, internalHostname(),
+ SQUIDHOSTNAMELEN);
+ request->port = getMyPort();
+ http->flags.internal = 1;
}
+ }
- if (http->flags.internal) {
- request->protocol = PROTO_HTTP;
- request->login[0] = '\0';
- }
+ if (http->flags.internal) {
+ request->protocol = PROTO_HTTP;
+ request->login[0] = '\0';
}
request->flags.internal = http->flags.internal;