incubator-sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fmesc...@apache.org
Subject svn commit: r1199406 - /sling/trunk/bundles/jcr/davex/src/main/java/org/apache/sling/jcr/davex/impl/servlets/AuthHttpContext.java
Date Tue, 08 Nov 2011 19:33:33 GMT
Author: fmeschbe
Date: Tue Nov  8 19:33:32 2011
New Revision: 1199406

URL: http://svn.apache.org/viewvc?rev=1199406&view=rev
Log:
SLING-2167 Force HTTP Basic authentication

Modified:
    sling/trunk/bundles/jcr/davex/src/main/java/org/apache/sling/jcr/davex/impl/servlets/AuthHttpContext.java

Modified: sling/trunk/bundles/jcr/davex/src/main/java/org/apache/sling/jcr/davex/impl/servlets/AuthHttpContext.java
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/jcr/davex/src/main/java/org/apache/sling/jcr/davex/impl/servlets/AuthHttpContext.java?rev=1199406&r1=1199405&r2=1199406&view=diff
==============================================================================
--- sling/trunk/bundles/jcr/davex/src/main/java/org/apache/sling/jcr/davex/impl/servlets/AuthHttpContext.java
(original)
+++ sling/trunk/bundles/jcr/davex/src/main/java/org/apache/sling/jcr/davex/impl/servlets/AuthHttpContext.java
Tue Nov  8 19:33:32 2011
@@ -23,6 +23,7 @@ import javax.servlet.http.HttpServletReq
 import javax.servlet.http.HttpServletResponse;
 
 import org.apache.sling.auth.core.AuthenticationSupport;
+import org.apache.sling.auth.core.spi.AuthenticationHandler;
 import org.osgi.service.http.HttpContext;
 
 class AuthHttpContext implements HttpContext {
@@ -67,6 +68,7 @@ class AuthHttpContext implements HttpCon
     throws IOException {
         final AuthenticationSupport localAuthenticator = this.authenticator;
         if ( localAuthenticator != null ) {
+            request.setAttribute(AuthenticationHandler.REQUEST_LOGIN_PARAMETER, "BASIC");
             return localAuthenticator.handleSecurity(request, response);
         }
         // send 503/SERVICE UNAVAILABLE, flush to ensure delivery



Mime
View raw message