Forcing SSL on a JSP
I'm trying to replicate the behavior that occurs when you set
<% // TODO: Make this into a tag library Boolean secureLogin = (Boolean)application.getAttribute(Constants.SECURE_LOGIN); System.out.println("secureLogin: " + secureLogin); if (secureLogin.booleanValue()) { // make sure we're using https if (request.getScheme().equals("http")) { String redirectString = SslUtil.getRedirectString(request, application, true); System.out.println("redirecting to: " + response.encodeRedirectURL(redirectString)); %> <logic:redirect href="<%=response.encodeRedirectURL(redirectString)%>"/> <% } } %>
Everything looks the same in Tomcat's log when using either browser.