Commit Graph

13108 Commits

Author SHA1 Message Date
reger
60b3adfb43 fix ext2mime to return given default on input=null 2016-11-29 23:32:20 +01:00
reger
f7e9f9be5f move Digest auth checks from DefaultServlet to adminAuthenticated,
eliminating the need to modify http header on Servlet container handled 
Digest authentication, to simulate Basic auth for YaCy servlets.
2016-11-29 03:20:33 +01:00
luccioman
0b4e7795df Fixed JavaScript error "hs.htmlExpand is not a function".
This error occurs on /ConfigSearchPage_p.html and on search results page
when Metadata links are enabled.

The fix was to remove unnecessary use of hs.htmlExpand() which is now
part of highslide-full.js library file, currently not distributed with
YaCy (only includes highslide.js). The Metadata links work correctly and
the initial dynamic expansion offered by htmlExpand() did not bring much
usability.
2016-11-29 02:56:43 +01:00
luccioman
1f4f0eacc2 Fixed a JS undefined error case, occurring when search field is empty. 2016-11-29 02:11:44 +01:00
luccioman
ceb7588880 Converted "clone" URL links in Table_API_p.html to purely relative ones.
Again for easier YaCy integration when running behind a reverse proxy
subfolder.
2016-11-29 01:34:33 +01:00
luccioman
cca3417b87 Fixed image and favicon viewing for unauthenticated local requests.
As reported by @reger24, image and favicon viewing was broken with
unauthenticated requests on peers configured to require authentication
even from localhost.

So I unified viewing rights check in a single new function on
ImageViewer class.
2016-11-28 22:10:05 +01:00
reger
02092de3d8 remove login cookie generation for static admin ind User servlet
cookieAuth is never successful for static admin, leaving the creation and
handling for login cookies for static admin obsolete.
2016-11-26 23:28:30 +01:00
reger
49f19aff75 exclude external link icon in Collage servlet
(icons display not close to image in IE)
2016-11-26 19:53:00 +01:00
reger
a0705c049d include check to prevent adding username identical with static admin
in ConfigAccounts_p
2016-11-26 18:26:14 +01:00
luccioman
89017e17e4 Converted ajax URL to relative and added a check on the response status.
This makes YaCy easier to configure when running behind a reverse Proxy.

The check on status avoids trying to update the page with error text
content when the server returned a 404 or 500 error message for example.
2016-11-25 11:13:16 +01:00
luccioman
fc575fc760 Fixed a NullPointerException case. 2016-11-25 11:07:50 +01:00
reger
9a8691129f fix typing error from commit 60ba5c117c 2016-11-25 04:18:36 +01:00
reger
f9328f07e2 completing the usage of CONNECTION_PROP_CLIENT_HTTPSERVLETREQUEST in
HTTPDProxyHandlers logging facility.
2016-11-25 03:05:53 +01:00
reger
8e3e3ed191 update the older ResponseHeader patch to handle cookies,
to work directly with javax.servlet.http.Cookie (rename headerProps to
cookieStore as is only used for this).
(Re)implement set-cookie in DefaultServlet to make cookieAuthentication
work as designed.
2016-11-25 02:00:20 +01:00
reger
866d3a1960 make RequestHeader login succeed (without throwing exception by default)
correct getAuthType to return Auth Scheme only after authentication
2016-11-25 01:09:42 +01:00
reger
44a6a4e795 fix authentication by hit in userdb (wrong parameter) 2016-11-24 00:16:22 +01:00
luccioman
aa9ddf3c23 Added control over Robots.txt active threads maximum number.
When starting a crawl from a file containing thousands of links,
configuration setting "crawler.MaxActiveThreads" is effective to prevent
saturating the system with too many outgoing HTTP connections threads
launched by the crawler.
But robots.txt was not affected by this setting and was indefinitely
increasing the number of concurrently loading threads until most ot the
connections timed out.

To improve performance control, added a pool of threads for Robots.txt,
consistently used in its ensureExist() and massCrawlCheck() methods.
The Robots.txt threads pool max size can now be configured in the
/PerformanceQueus_p.html page, or with the new
"robots.txt.MaxActiveThreads" setting, initialized with the same default
value as the crawler.
2016-11-23 18:13:05 +01:00
luccioman
3092a8ced5 Fixed thread name consistency for improved monitoring.
Some tasks were modifying the current thread name without restoring it
once finished as it is effectively done elsewhere.
2016-11-23 17:59:52 +01:00
luccioman
eec5779889 Added a name prefix to pooled threads for easier monitoring.
Using JVM monitoring tools, it is then easier to identify tasks running
inside thread pool with a custom prefix rather than the generic one :
"pool-".
2016-11-23 11:21:14 +01:00
reger
baf6d21cfe ConfigSearchPage, move protocol navi up to better simulate actual design.
Because here btn-group-justified screws up table column width (Explorer
and Firefox) bootstrap btn-group is used.
2016-11-23 01:33:01 +01:00
luccioman
176f7c2aab RWI Ranking Configuration page : fixed missing required dependencies.
Fix for mantis 707 (http://mantis.tokeek.de/view.php?id=707)
2016-11-22 09:40:22 +01:00
reger
59130777a6 add high scored items first to YearNavigator (to make sure to be included
in sorted view)
2016-11-22 01:17:33 +01:00
luccioman
0ba5a838f7 Added charset meta to Solr HTML writers.
Non-ASCII characters are thus correctly rendered in browsers.
This is a fix ro mantis 706 : http://mantis.tokeek.de/view.php?id=706
2016-11-21 19:55:13 +01:00
reger
08a0acc35d make a YearNavigator availabel, useable as SearchEvent.naviator plugin.
It can take any Date field of the index and displays a list of year strings
in reverse order by the year (not the score/count).
To allow to define the index field to use, the fieldname (and title can be 
appended to the navi's name "year" e.g. year:load_date_dt:LoadDate
It works also with dates_in_content_dts field (from the graphical date
navigator). Here the query parameter from: to: are used on selection as
Query modifier (for other dates currently no query parameter available, so
selection won't work to filter search results).
Not included in the UI Searchpage layout config so far (for experiment with
it manual change to conf needed).
2016-11-21 16:52:53 +01:00
reger
7742579ca4 make a LanguageNavigator availabel, useable for the SearchEvent.naviator
plugin (not activated yet).
2016-11-21 00:19:11 +01:00
reger
0d3bef659b implement RequestHeader.setCharacterEncoding for legacy header,
make sure .getProtocol returns a http version
move the patch for Set-Cookie to ResponseHeader (applies only here)
2016-11-20 19:30:38 +01:00
Michael Peter Christen
5320209963 Merge branch 'master' of https://github.com/yacy/yacy_search_server.git 2016-11-20 12:13:07 +01:00
Michael Peter Christen
83f5e3d715 added+disabled a federate search experiment 2016-11-20 12:13:00 +01:00
reger
4eeb448eb3 use DigestURL in UrlProxyServlet as parameter to pass requested url to
handler.
UrlProxyServlet splits url in parts to pass it on as parameter and 
HeaderFramework constructs a url from param parts. This is obsolete if
already created url is used (makes HeaderFramework.getRequestURL obsolete
= removed)
2016-11-20 05:27:33 +01:00
reger
3630fcc458 adjust messages_p servlet to standard header.getPathInfo, too
(replacing non standard http header)
2016-11-20 04:02:28 +01:00
reger
bad8f87998 remove old/obsolete clear text "adminAccount" credential entry from init
and setConfig (.,empty) from servlets/code
2016-11-20 00:20:47 +01:00
reger
811cf637f8 fix Jetty9YaCySecurityHandler, length check of Basic credential,
add comment to SwitchboardConstants.AdminAccount const
2016-11-20 00:15:21 +01:00
reger
fdcf33f08f fix Domain.stripToHostName for some IPv6 cases
add unit test for it
2016-11-19 16:37:16 +01:00
reger
ac6e198bd1 add unit test for Domains.stripToPort,
simplify ipv6 check
2016-11-19 06:22:55 +01:00
reger
f27531f5ec fix Domains.stripToPort, make ipv6 save 2016-11-19 05:56:48 +01:00
reger
67744a8038 fix HeaderFramework.getRequestURL on host with port considering ipv6 host 2016-11-19 05:08:11 +01:00
reger
66cc0dd173 refactor: move GSA specific date formatter to GSAservlet
adjust return type to String for HeaderFrameWork.getSingle
2016-11-19 03:29:23 +01:00
reger
d525967999 refactor: move convertHeaderFromJetty to ProxHandler (only used with active proxy
not needed for standard servlets)
2016-11-19 02:10:21 +01:00
reger
20c9b0138e let User servlet detect static admin with (newer) md5 encoded pwd
(complete a old todo)
2016-11-19 01:02:05 +01:00
reger
60ba5c117c fix legacy getHeaderCookies to work with cookies from original
HttpServletRequest, by moving to RequestHeader.
2016-11-18 21:44:16 +01:00
reger
30f8d1e2d7 let RequestHeader.logout succeed w/o throwing exception by default 2016-11-18 03:00:30 +01:00
reger
b449b0b660 remove login request directly after logout,
and add logout from servlet container
make logout button red
2016-11-18 02:39:53 +01:00
reger
28afd3a2f8 fix UserDB.proxyAuth from header string
(take care of prefix "Basic" in header entry)
2016-11-18 01:12:14 +01:00
luccioman
fd22d8c08b Upgraded Bootstrap to 3.3.7 and upgraded its related js dependencies.
Upgraded the following JavaScript libraries dependencies :
 - bootstrap-switch to 3.3.2
 - html5shiv to 3.7.3 and switched to minified version
 - typeahead to 0.10.5
 - jQuery to 1.12.4

Removed unused bootstratp-rtl.css and bootstrap-rtl.min.css.

Tested non regressions on the following systems :
 - Debian Jessie : 
  - Firefox 45.4.0

 - MS Windows 10 :
  - Chrome 54.0.2840.99 
  - Firefox 50.0
  - Edge
  - Emulated IE 11, 10 and 9
2016-11-17 14:17:08 +01:00
luccioman
0806de8fdc Ensure file input stream are closed in both normal and error cases. 2016-11-16 15:13:58 +01:00
luccioman
a0dfbaca6a FileUtils : added some JavaDocs and unit test cases 2016-11-16 15:12:21 +01:00
reger
59448461d3 make use of userInRole for quick login verification 2016-11-16 01:42:53 +01:00
reger
2a4d826d9e adjust servlet RequestHeader.getLocale
init jvm defaultLocale matching UI language
2016-11-15 02:37:03 +01:00
luccioman
200e7a7292 upd to jsoup-1.10.1 : fixed to Eclipse classpath and Ant configuration. 2016-11-15 01:13:31 +01:00
reger
c55172f629 upd to jsoup-1.10.1.jar 2016-11-14 23:10:32 +01:00