From efe97f446a82d90f658bc986b3563fcda29dcdbd Mon Sep 17 00:00:00 2001 From: lotus Date: Wed, 3 Jun 2009 19:03:03 +0000 Subject: [PATCH] better proxy configuration in case of remote proxy git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@6016 6c8d7289-2bf4-0310-a012-ef5d649a1542 --- htroot/autoconfig.pac | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/htroot/autoconfig.pac b/htroot/autoconfig.pac index 5ed509536..435e4587c 100644 --- a/htroot/autoconfig.pac +++ b/htroot/autoconfig.pac @@ -4,6 +4,9 @@ function FindProxyForURL(url,host) { return "DIRECT"; } + // not the proxy itself + if (host == "#[host]#") return "DIRECT"; + // no local adresses ip = dnsResolve(host); if ( isInNet(ip, "127.0.0.0", "255.0.0.0") @@ -13,6 +16,9 @@ function FindProxyForURL(url,host) { return "DIRECT"; } + // not the proxy itself (better: dnsResolve(#[host]#), but an additional lookup) + if (ip == "#[host]#") return "DIRECT"; + // then return "PROXY #[host]#:#[port]#, DIRECT"; } \ No newline at end of file