diff --git a/dspace-xmlui/src/main/java/org/dspace/app/xmlui/cocoon/DSpaceCocoonServletFilter.java b/dspace-xmlui/src/main/java/org/dspace/app/xmlui/cocoon/DSpaceCocoonServletFilter.java index 17cb705e33..cb3d56b5f1 100644 --- a/dspace-xmlui/src/main/java/org/dspace/app/xmlui/cocoon/DSpaceCocoonServletFilter.java +++ b/dspace-xmlui/src/main/java/org/dspace/app/xmlui/cocoon/DSpaceCocoonServletFilter.java @@ -257,7 +257,7 @@ public class DSpaceCocoonServletFilter implements Filter realResponse.sendRedirect(locationWithTrailingSlash); } // if force ssl is on and the user has authenticated and the request is not secure redirect to https - else if ((ConfigurationManager.getBooleanProperty("xmlui.force.ssl")) && (realRequest.getSession().getAttribute("dspace.current.user.id")!=null) && (!realRequest.isSecure())) { + else if ((ConfigurationManager.getBooleanProperty("xmlui.force.ssl")) && (realRequest.getSession().getAttribute("dspace.user.effective")!=null) && (!realRequest.isSecure())) { StringBuffer location = new StringBuffer("https://"); location.append(ConfigurationManager.getProperty("dspace.hostname")).append(realRequest.getContextPath()).append(realRequest.getServletPath()).append( realRequest.getQueryString() == null ? ""