/*
- * $Id: cache_cf.cc,v 1.205 1997/07/14 23:44:57 wessels Exp $
+ * $Id: cache_cf.cc,v 1.206 1997/07/15 23:15:34 wessels Exp $
*
* DEBUG: section 3 Configuration File Parsing
* AUTHOR: Harvest Derived
configDoConfigure(void)
{
LOCAL_ARRAY(char, buf, BUFSIZ);
+ cache_peer *p;
memset(&Config2, '\0', sizeof(SquidConfig2));
if (Config.Accel.host) {
snprintf(buf, BUFSIZ, "http://%s:%d", Config.Accel.host, Config.Accel.port);
Config.appendDomainLen = 0;
safe_free(debug_options)
debug_options = xstrdup(Config.debugOptions);
+ /* ICK */
+ for (p = Config.peers; p; p=p->next) {
+ neighborAdd(p->host,
+ p->type,
+ p->http,
+ p->icp,
+ p->options,
+ p->weight,
+ p->mcast_ttl);
+ }
}
/* Parse a time specification from the config file. Store the
tcp_recv_bufsize 0 bytes
DOC_END
-
-NAME: ssl_proxy
-TYPE: cache_peer
-LOC: Config.sslProxy
-DEFAULT: none
-DOC_START
- Specify a hostname and port number where all SSL requests
- should be forwarded to.
-
- XXX For now, ssl_proxy has the same format as cache_peer
- because they share the same data structure. All files
- must be present in the config file, but some will be ignored.
-
- Usage: ssl_proxy hostname type-ignored port icpport-ignored
-
-ssl_proxy
-DOC_END
-
-
-NAME: passthrough_proxy
-TYPE: cache_peer
-LOC: Config.passProxy
-DEFAULT: none
-DOC_START
- Specify a hostname and port number where all non-GET (i.e.
- POST, PUT) requests should be forwarded to.
-
- XXX For now, ssl_proxy has the same format as cache_peer
- because they share the same data structure. All files
- must be present in the config file, but some will be ignored.
-
- Usage: passthrough_proxy hostname type-ignored port icpport-ignored
-
-passthrough_proxy
-DOC_END
-
-
NAME: proxy_auth_passwd
TYPE: string
LOC: Config.proxyAuth.File
SOURCE_FASTEST,
SIBLING_UDP_HIT_OBJ,
PARENT_UDP_HIT_OBJ,
- PASS_PARENT,
- SSL_PARENT,
ROUNDROBIN_PARENT,
HIER_MAX
} hier_code;
/*
- * $Id: neighbors.cc,v 1.149 1997/07/07 05:29:49 wessels Exp $
+ * $Id: neighbors.cc,v 1.150 1997/07/15 23:15:36 wessels Exp $
*
* DEBUG: section 15 Neighbor Routines
* AUTHOR: Harvest Derived
peer *peers_tail;
peer *first_ping;
peer *removed;
- peer *ssl_parent;
- peer *pass_parent;
} Peers = {
0, NULL, NULL, NULL
return NULL;
}
-peer *
-getSslParent(void)
-{
- return Peers.ssl_parent;
-}
-
-peer *
-getPassParent(void)
-{
- return Peers.pass_parent;
-}
-
peer *
getNextPeer(peer * p)
{
{
peer *p = NULL;
peer *next = NULL;
-
debug(15, 3) ("neighborsDestroy: called\n");
-
for (p = Peers.peers_head; p; p = next) {
next = p->next;
peerDestroy(p);
/*
- * $Id: peer_select.cc,v 1.18 1997/07/14 05:57:55 wessels Exp $
+ * $Id: peer_select.cc,v 1.19 1997/07/15 23:15:36 wessels Exp $
*
* DEBUG: section 44 Peer Selection Algorithm
* AUTHOR: Duane Wessels
peerGetSomeParent(request_t * request, hier_code * code)
{
peer *p;
- if (request->method == METHOD_CONNECT)
- if ((p = getSslParent())) {
- *code = SSL_PARENT;
- return p;
- }
- if (request->method != METHOD_GET)
- if ((p = getPassParent())) {
- *code = PASS_PARENT;
- return p;
- }
if ((p = getDefaultParent(request))) {
*code = DEFAULT_PARENT;
return p;
extern void useragentRotateLog _PARAMS((void));
extern void logUserAgent _PARAMS((const char *, const char *));
extern peer_t parseNeighborType _PARAMS((const char *s));
-extern peer *getSslParent _PARAMS((void));
-extern peer *getPassParent _PARAMS((void));