From c815978123f4bff4d986a9d16a525acd8cc8b218 Mon Sep 17 00:00:00 2001 From: Mike Taylor Date: Tue, 9 Sep 2014 13:50:59 +0100 Subject: [PATCH] Update default configuration to use sp-mkws.indexdata.com for Pazpar2 interactions, including Service Proxy authentication. By default we no longer authenticate as mkws/mkws, but leave it for referer, hostname or IP-based authentication to work their magic. (For now, we always send username/password=XXX/XXX unless told to use something different by the application. This is a workaround for bug MKSP-125 and should be changed soon!) See the manual for details of how to set up authentication: http://mkws.indexdata.com/mkws-manual.html#authenticating-your-mwks-application-onto-the-library -- Note that, while existing applications that already set the config item service_proxy_auth will continue to honour it, those that just use the default value (mkws/mkws) WILL NO LONGER WORK. This is a BACKWARDS INCOMPATIBLE CHANGE. There are two ways to fix this in an application. One is to modify the application itself so that it sets mkws_config.sp_auth_credentials to "username/password". The other is to add an end-user record to the library "DEMO MKWS: the MasterKey Widget Set" which recognises the URL of the application as a referring URL. --- src/mkws-core.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/mkws-core.js b/src/mkws-core.js index 28f095c..6b3e00d 100644 --- a/src/mkws-core.js +++ b/src/mkws-core.js @@ -168,12 +168,12 @@ mkws.setMkwsConfig = function(overrides) { var config_default = { use_service_proxy: true, pazpar2_url: undefined, - pp2_hostname: "mkws.indexdata.com", + pp2_hostname: "sp-mkws.indexdata.com", pp2_path: "service-proxy", service_proxy_auth: undefined, - sp_auth_path: "service-proxy-auth", - sp_auth_query: undefined, // Will be: "command=auth&action=perconfig", - sp_auth_credentials: undefined, + sp_auth_path: "service-proxy/", + sp_auth_query: "command=auth&action=perconfig", + sp_auth_credentials: "XXX/XXX", // Should be undefined: see bug MKSP-125. lang: "", sort_options: [["relevance"], ["title:1", "title"], ["date:0", "newest"], ["date:1", "oldest"]], perpage_options: [10, 20, 30, 50], -- 1.7.10.4