From b4aa195c27beb06af96f430ed26368eb13a1e6f9 Mon Sep 17 00:00:00 2001 From: orbiter Date: Tue, 6 Feb 2007 09:53:02 +0000 Subject: [PATCH] added user-agent check for yacy-hop proxy authentication git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@3343 6c8d7289-2bf4-0310-a012-ef5d649a1542 --- source/de/anomic/http/httpd.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/source/de/anomic/http/httpd.java b/source/de/anomic/http/httpd.java index ea0df6d9f..33f1dd1f6 100644 --- a/source/de/anomic/http/httpd.java +++ b/source/de/anomic/http/httpd.java @@ -350,8 +350,7 @@ public final class httpd implements serverHandler { if (!test.equals(auth.trim().substring(6))) return false; // the accessing client must use a yacy user-agent - - return true; + return (((String) header.get(httpHeader.USER_AGENT,"")).startsWith("yacy")); } private boolean handleProxyAuthentication(httpHeader header) throws IOException {