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=13660>.
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=13660

HttpServletRequest.getAttributeNames() doesn't return 
javax.servlet.request.cipher_suite attribute

           Summary: HttpServletRequest.getAttributeNames() doesn't return
                    javax.servlet.request.cipher_suite attribute
           Product: Tomcat 4
           Version: 4.1.12
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: Connector:Coyote HTTP/1.1
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]


Attribute javax.servlet.request.cipher_suite is set on SSL connections. It 
used to be the case that you could see the name of this attribute when you 
called HttpServletRequest.getAttributeNames(). This no longer happens. Even 
though the attribute has a value, it's name isn't returned when you call 
HttpServletRequest.getAttributeNames(). The following example demonstrates,

import java.io.*;
import java.util.*;
import javax.servlet.*;
import javax.servlet.http.*;

public class AttributesServlet extends HttpServlet {
        public void doGet(HttpServletRequest req, HttpServletResponse resp) 
throws IOException {
                try {
                        resp.setContentType("text/html");
                        PrintWriter pw = resp.getWriter();
                        pw.println
("<html><head><title>AttributesServlet</title></head><body>");
                        Enumeration e = req.getAttributeNames();
                        while(e.hasMoreElements()) {
                                String s = (String)e.nextElement();
                                pw.println("<p>" + s + ": " + req.getAttribute
(s) + "</p>");
                        }

                        pw.println("<p>" + req.getAttribute
("javax.servlet.request.cipher_suite") + "</p>");
                        
                        pw.println("</body></html>");
                        pw.close();
                }
                catch(Exception e) {
                        e.printStackTrace();
                }
        }
}

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to