tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 12218] - GetAttribute returns Null
Date Tue, 26 Aug 2003 19:05:17 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12218>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12218

GetAttribute returns Null

medthomas@ntlworld.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |WORKSFORME



------- Additional Comments From medthomas@ntlworld.com  2003-08-26 19:05 -------
I have checked this with the HEAD of 4.1 and 5.0 and both work using the 
following code snippet in the jsp page.

<%@ page import="java.security.cert.*" %>
<%
  X509Certificate[] certChain;
  X509Certificate clientCert;
  java.security.Principal userDN;

  certChain = (X509Certificate[])request.getAttribute
("javax.servlet.request.X509Certificate");
  clientCert = certChain[0];
  userDN = clientCert.getSubjectDN();

  out.println("<P>Subject distinguished name is: " + userDN + "</P>");
  out.println("<p>getRemoteUser() returns: " + request.getRemoteUser() 
+ "</P>");
%>

Your suspicion that your custom SSL factory might be the root cause would 
appear to be correct.

Mime
View raw message