diff --git a/fess-crawler/src/main/java/org/codelibs/fess/crawler/client/http/HcHttpClient.java b/fess-crawler/src/main/java/org/codelibs/fess/crawler/client/http/HcHttpClient.java index adfd515d..5a40a1ee 100644 --- a/fess-crawler/src/main/java/org/codelibs/fess/crawler/client/http/HcHttpClient.java +++ b/fess-crawler/src/main/java/org/codelibs/fess/crawler/client/http/HcHttpClient.java @@ -142,7 +142,7 @@ public class HcHttpClient extends AbstractCrawlerClient { public static final String ROBOTS_TXT_ENABLED_PROPERTY = "robotsTxtEnabled"; - public static final String BASIC_AUTHENTICATIONS_PROPERTY = "basicAuthentications"; + public static final String AUTHENTICATIONS_PROPERTY = "webAuthentications"; public static final String REQUERT_HEADERS_PROPERTY = "requestHeaders"; @@ -162,6 +162,9 @@ public class HcHttpClient extends AbstractCrawlerClient { public static final String TIME_TO_LIVE_PROPERTY = "timeToLive"; + @Deprecated + public static final String BASIC_AUTHENTICATIONS_PROPERTY = AUTHENTICATIONS_PROPERTY; + private static final Logger logger = LoggerFactory.getLogger(HcHttpClient.class); @Resource @@ -298,7 +301,7 @@ public synchronized void init() { // Authentication final Authentication[] siteCredentialList = - getInitParameter(BASIC_AUTHENTICATIONS_PROPERTY, new Authentication[0], Authentication[].class); + getInitParameter(AUTHENTICATIONS_PROPERTY, new Authentication[0], Authentication[].class); final List> formSchemeList = new ArrayList<>(); for (final Authentication authentication : siteCredentialList) { final AuthScheme authScheme = authentication.getAuthScheme(); diff --git a/fess-crawler/src/test/java/org/codelibs/fess/crawler/client/http/HcHttpClientTest.java b/fess-crawler/src/test/java/org/codelibs/fess/crawler/client/http/HcHttpClientTest.java index dc735aab..9b3e3521 100644 --- a/fess-crawler/src/test/java/org/codelibs/fess/crawler/client/http/HcHttpClientTest.java +++ b/fess-crawler/src/test/java/org/codelibs/fess/crawler/client/http/HcHttpClientTest.java @@ -188,7 +188,7 @@ public void test_buildRedirectLocation() throws Exception { // new UsernamePasswordCredentials("username", "password"), // digestScheme)); // paramMap.put( - // HcHttpClient.BASIC_AUTHENTICATIONS_PROPERTY, + // HcHttpClient.AUTHENTICATIONS_PROPERTY, // basicAuthList.toArray(new Authentication[basicAuthList.size()])); // // List> list =