diff --git a/core/src/main/java/org/acegisecurity/ui/AbstractProcessingFilter.java b/core/src/main/java/org/acegisecurity/ui/AbstractProcessingFilter.java index d6c54c4b76..4403a8b052 100644 --- a/core/src/main/java/org/acegisecurity/ui/AbstractProcessingFilter.java +++ b/core/src/main/java/org/acegisecurity/ui/AbstractProcessingFilter.java @@ -310,6 +310,10 @@ public abstract class AbstractProcessingFilter implements Filter, InitializingBe uri = uri.substring(0, pathParamIndex); } + if ("".equals(request.getContextPath())) { + return uri.endsWith(filterProcessesUrl); + } + return uri.endsWith(request.getContextPath() + filterProcessesUrl); } diff --git a/core/src/main/java/org/acegisecurity/ui/logout/LogoutFilter.java b/core/src/main/java/org/acegisecurity/ui/logout/LogoutFilter.java index 44d155c1a2..e962a9e1bd 100644 --- a/core/src/main/java/org/acegisecurity/ui/logout/LogoutFilter.java +++ b/core/src/main/java/org/acegisecurity/ui/logout/LogoutFilter.java @@ -132,6 +132,10 @@ public class LogoutFilter implements Filter { uri = uri.substring(0, pathParamIndex); } + if ("".equals(request.getContextPath())) { + return uri.endsWith(filterProcessesUrl); + } + return uri.endsWith(request.getContextPath() + filterProcessesUrl); }