From: James Moger Date: Tue, 1 Jul 2014 01:29:01 +0000 (-0400) Subject: Use forked guice-servlet jar rather than stock jar from Google X-Git-Tag: v1.7.0~1^2~202^2~11 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=94146dd495aad8157c423bfd9a1ae47c8e26b32c;p=gitblit.git Use forked guice-servlet jar rather than stock jar from Google --- diff --git a/.classpath b/.classpath index a7a89634..274dee2b 100644 --- a/.classpath +++ b/.classpath @@ -9,7 +9,7 @@ - + diff --git a/build.moxie b/build.moxie index 3514577e..8ca52755 100644 --- a/build.moxie +++ b/build.moxie @@ -96,9 +96,10 @@ registeredRepositories: - { id: eclipse, url: 'http://repo.eclipse.org/content/groups/releases' } - { id: eclipse-snapshots, url: 'http://repo.eclipse.org/content/groups/snapshots' } - { id: atlassian-contrib, url: 'https://maven.atlassian.com/content/repositories/atlassian-3rdparty' } +- { id: gitblit, url: 'http://gitblit.github.io/gitblit-maven' } # Source all dependencies from the following repositories in the specified order -repositories: central, eclipse-snapshots, eclipse, atlassian-contrib +repositories: central, eclipse-snapshots, eclipse, atlassian-contrib, gitblit # Convenience properties for dependencies properties: { @@ -113,7 +114,8 @@ properties: { sshd.version: 0.11.1-atlassian-1 mina.version: 2.0.7 guice.version : 4.0-beta4 - guice-servlet.version : 4.0-SNAPSHOT + # Gitblit maintains a fork of guice-servlet + guice-servlet.version : 4.0-gb1 } # Dependencies diff --git a/gitblit.iml b/gitblit.iml index 8912282a..cc9324f5 100644 --- a/gitblit.iml +++ b/gitblit.iml @@ -58,13 +58,13 @@ - + - + - + diff --git a/src/main/java/com/gitblit/servlet/AuthenticationFilter.java b/src/main/java/com/gitblit/servlet/AuthenticationFilter.java index 35a62365..6f13252a 100644 --- a/src/main/java/com/gitblit/servlet/AuthenticationFilter.java +++ b/src/main/java/com/gitblit/servlet/AuthenticationFilter.java @@ -99,12 +99,8 @@ public abstract class AuthenticationFilter implements Filter { * @return url */ protected String getFullUrl(HttpServletRequest httpRequest) { - String contextPath = httpRequest.getContextPath(); - String servletPath = httpRequest.getServletPath(); - String pathInfo = httpRequest.getPathInfo(); - String servletUrl = contextPath + servletPath; - String requestURI = httpRequest.getRequestURI(); - String url = requestURI.substring(servletUrl.length()); + String servletUrl = httpRequest.getContextPath() + httpRequest.getServletPath(); + String url = httpRequest.getRequestURI().substring(servletUrl.length()); String params = httpRequest.getQueryString(); if (url.length() > 0 && url.charAt(0) == '/') { url = url.substring(1);