title: X.509 : Server not able to extract user information from client certificate
body: <p>I have jetty working with SSL set up, client and server certificates (X.509) provided as required according to Spring Security and upto this it all seems working fine and verified by logs.</p>
  
  <p>Now! The problem is when I access a secure page, client(Chrome) is sending a certificate and server is receiving it successfully but after that it is returning me an empty user. Does any body have any idea what is happening here?</p>
  
  <p>I am providing some information about what I am trying here :</p>
  
  <p><strong>Environment</strong></p>
  
  <p>Windows/Jetty (version: 8.1.11.v20130520)/Spring Security (3.2.0)</p>
  
  <p><strong>Connector in jetty (version: 8.1.11.v20130520)</strong></p>
  
  <pre><code>&lt;connector implementation="org.eclipse.jetty.server.ssl.SslSocketConnector"&gt;
      &lt;port&gt;9443&lt;/port&gt;
      &lt;keystore&gt;src/test/resources/server.jks&lt;/keystore&gt;
      &lt;needClientAuth&gt;true&lt;/needClientAuth&gt;
      &lt;keyPassword&gt;password&lt;/keyPassword&gt;
      &lt;password&gt;password&lt;/password&gt;
  &lt;/connector&gt;
  </code></pre>
  
  <p><strong>Security Configuration file</strong></p>
  
  <pre><code>&lt;sec:x509 subject-principal-regex="CN=(.*?)" 
            user-service-ref="myUserDetailsService" /&gt;
  </code></pre>
  
  <p><strong>Log extract</strong></p>
  
  <p>09:42:24:214 DEBUG org.springframework.security.web.authentication.preauth.x509.SubjectDnX509PrincipalExtractor (SubjectDnX509PrincipalExtractor.java:43) - Subject DN is 'CN=rod, OU=Spring Security, O=Spring Framework'
  09:42:24:218 DEBUG org.springframework.security.web.authentication.preauth.x509.SubjectDnX509PrincipalExtractor (SubjectDnX509PrincipalExtractor.java:58) - Extracted Principal name is ''</p>