cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cohei...@apache.org
Subject svn commit: r1478322 - in /cxf/fediz/trunk/plugins: jetty/src/main/java/org/apache/cxf/fediz/jetty/ spring/src/main/java/org/apache/cxf/fediz/spring/web/ spring2/src/main/java/org/apache/cxf/fediz/spring/web/
Date Thu, 02 May 2013 10:42:21 GMT
Author: coheigea
Date: Thu May  2 10:42:21 2013
New Revision: 1478322

URL: http://svn.apache.org/r1478322
Log:
[FEDIZ-4] - Set client certs in different containers

Modified:
    cxf/fediz/trunk/plugins/jetty/src/main/java/org/apache/cxf/fediz/jetty/FederationAuthenticator.java
    cxf/fediz/trunk/plugins/spring/src/main/java/org/apache/cxf/fediz/spring/web/FederationAuthenticationFilter.java
    cxf/fediz/trunk/plugins/spring2/src/main/java/org/apache/cxf/fediz/spring/web/FederationAuthenticationFilter.java

Modified: cxf/fediz/trunk/plugins/jetty/src/main/java/org/apache/cxf/fediz/jetty/FederationAuthenticator.java
URL: http://svn.apache.org/viewvc/cxf/fediz/trunk/plugins/jetty/src/main/java/org/apache/cxf/fediz/jetty/FederationAuthenticator.java?rev=1478322&r1=1478321&r2=1478322&view=diff
==============================================================================
--- cxf/fediz/trunk/plugins/jetty/src/main/java/org/apache/cxf/fediz/jetty/FederationAuthenticator.java
(original)
+++ cxf/fediz/trunk/plugins/jetty/src/main/java/org/apache/cxf/fediz/jetty/FederationAuthenticator.java
Thu May  2 10:42:21 2013
@@ -21,6 +21,7 @@ package org.apache.cxf.fediz.jetty;
 
 import java.io.File;
 import java.io.IOException;
+import java.security.cert.X509Certificate;
 
 import javax.servlet.ServletRequest;
 import javax.servlet.ServletResponse;
@@ -164,6 +165,10 @@ public class FederationAuthenticator ext
                         FederationRequest wfReq = new FederationRequest();
                         wfReq.setWa(wa);
                         wfReq.setWresult(wresult);
+                        
+                        X509Certificate certs[] = 
+                            (X509Certificate[])request.getAttribute("javax.servlet.request.X509Certificate");
+                        wfReq.setCerts(certs);
 
                         //Not supported in jetty 7.6
                         //String contextName = request.getServletContext().getContextPath();

Modified: cxf/fediz/trunk/plugins/spring/src/main/java/org/apache/cxf/fediz/spring/web/FederationAuthenticationFilter.java
URL: http://svn.apache.org/viewvc/cxf/fediz/trunk/plugins/spring/src/main/java/org/apache/cxf/fediz/spring/web/FederationAuthenticationFilter.java?rev=1478322&r1=1478321&r2=1478322&view=diff
==============================================================================
--- cxf/fediz/trunk/plugins/spring/src/main/java/org/apache/cxf/fediz/spring/web/FederationAuthenticationFilter.java
(original)
+++ cxf/fediz/trunk/plugins/spring/src/main/java/org/apache/cxf/fediz/spring/web/FederationAuthenticationFilter.java
Thu May  2 10:42:21 2013
@@ -20,6 +20,7 @@
 package org.apache.cxf.fediz.spring.web;
 
 import java.io.IOException;
+import java.security.cert.X509Certificate;
 
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
@@ -50,6 +51,10 @@ public class FederationAuthenticationFil
         wfReq.setWa(wa);
         wfReq.setWresult(wresult);
         
+        X509Certificate certs[] = 
+            (X509Certificate[])request.getAttribute("javax.servlet.request.X509Certificate");
+        wfReq.setCerts(certs);
+        
         final UsernamePasswordAuthenticationToken authRequest = new UsernamePasswordAuthenticationToken(null,
wfReq);
 
         authRequest.setDetails(authenticationDetailsSource.buildDetails(request));

Modified: cxf/fediz/trunk/plugins/spring2/src/main/java/org/apache/cxf/fediz/spring/web/FederationAuthenticationFilter.java
URL: http://svn.apache.org/viewvc/cxf/fediz/trunk/plugins/spring2/src/main/java/org/apache/cxf/fediz/spring/web/FederationAuthenticationFilter.java?rev=1478322&r1=1478321&r2=1478322&view=diff
==============================================================================
--- cxf/fediz/trunk/plugins/spring2/src/main/java/org/apache/cxf/fediz/spring/web/FederationAuthenticationFilter.java
(original)
+++ cxf/fediz/trunk/plugins/spring2/src/main/java/org/apache/cxf/fediz/spring/web/FederationAuthenticationFilter.java
Thu May  2 10:42:21 2013
@@ -19,6 +19,8 @@
 
 package org.apache.cxf.fediz.spring.web;
 
+import java.security.cert.X509Certificate;
+
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 
@@ -65,6 +67,10 @@ public class FederationAuthenticationFil
         wfReq.setWa(wa);
         wfReq.setWresult(wresult);
         
+        X509Certificate certs[] = 
+            (X509Certificate[])request.getAttribute("javax.servlet.request.X509Certificate");
+        wfReq.setCerts(certs);
+        
         final UsernamePasswordAuthenticationToken authRequest = new UsernamePasswordAuthenticationToken(null,
wfReq);
 
         authRequest.setDetails(authenticationDetailsSource.buildDetails(request));



Mime
View raw message