001 package jsp;
002
003 import javax.servlet.*;
004 import javax.servlet.http.*;
005 import javax.servlet.jsp.*;
006
007 public final class confirmRequest_jsp extends org.apache.jasper.runtime.HttpJspBase
008 implements org.apache.jasper.runtime.JspSourceDependent {
009
010 private static final JspFactory _jspxFactory = JspFactory.getDefaultFactory();
011
012 private static java.util.List _jspx_dependants;
013
014 private javax.el.ExpressionFactory _el_expressionfactory;
015 private org.apache.InstanceManager _jsp_instancemanager;
016
017 public Object getDependants() {
018 return _jspx_dependants;
019 }
020
021 public void _jspInit() {
022 _el_expressionfactory = _jspxFactory.getJspApplicationContext(getServletConfig().getServletContext()).getExpressionFactory();
023 _jsp_instancemanager = org.apache.jasper.runtime.InstanceManagerFactory.getInstanceManager(getServletConfig());
024 }
025
026 public void _jspDestroy() {
027 }
028
029 public void _jspService(HttpServletRequest request, HttpServletResponse response)
030 throws java.io.IOException, ServletException {
031
032 PageContext pageContext = null;
033 HttpSession session = null;
034 ServletContext application = null;
035 ServletConfig config = null;
036 JspWriter out = null;
037 Object page = this;
038 JspWriter _jspx_out = null;
039 PageContext _jspx_page_context = null;
040
041
042 try {
043 response.setContentType("text/html; charset=ISO-8859-1");
044 pageContext = _jspxFactory.getPageContext(this, request, response,
045 null, true, 8192, true);
046 _jspx_page_context = pageContext;
047 application = pageContext.getServletContext();
048 config = pageContext.getServletConfig();
049 session = pageContext.getSession();
050 out = pageContext.getOut();
051 _jspx_out = out;
052
053 out.write("<!DOCTYPE html PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">\r\n<html>\r\n<head>\r\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=ISO-8859-1\">\r\n<title>Request Certificate - Confirm Request</title>\r\n</head>\r\n");
054
055 String reqCN = request.getParameter("reqCN");
056 String reqOU = request.getParameter("reqOU");
057 String reqO = request.getParameter("reqO");
058 String reqL = request.getParameter("reqL");
059 String reqST = request.getParameter("reqST");
060 String reqC = request.getParameter("reqC");
061 String challenge = request.getParameter("challenge");
062
063 out.write("<body>\r\n<h2>Request Certificate: Confirm and Submit Request</h2>\r\n<div id=\"Non-IE-Content\" style=\"display:none\">\r\n<p>This is step 2 of 2 in requesting your certificate. Please review your name details and select the keysize for\r\nyour keypair. Upon clicking the <i>Submit Certificate Request</i> button, your certificate request will be generated\r\nand sent to the CA for further processing.</p>\r\n\r\n<form action=\"CertificateRequestServlet\" method=\"post\">\r\n <table border=\"0\">\r\n <tr>\r\n <th align=\"right\">Common Name (CN):</th>\r\n <td>\r\n <input type=\"hidden\" name=\"reqCN\" value=\"");
064 out.print(reqCN);
065 out.write("\"/> ");
066 out.print(reqCN);
067 out.write("</td>\r\n </tr>\r\n <tr>\r\n <th align=\"right\">Division/Business Unit (OU):</th>\r\n <td>\r\n <input type=\"hidden\" name=\"reqOU\" value=\"");
068 out.print(reqOU);
069 out.write("\"/> ");
070 out.print(reqOU);
071 out.write("</td>\r\n </tr>\r\n <tr>\r\n <th align=\"right\">Company/Organization (O):</th>\r\n <td>\r\n <input type=\"hidden\" name=\"reqO\" value=\"");
072 out.print(reqO);
073 out.write("\"/> ");
074 out.print(reqO);
075 out.write("</td>\r\n </tr>\r\n <tr>\r\n <th align=\"right\">City/Locality (L):</th>\r\n <td>\r\n <input type=\"hidden\" name=\"reqL\" value=\"");
076 out.print(reqL);
077 out.write("\"/> ");
078 out.print(reqL);
079 out.write("</td>\r\n </tr>\r\n <tr>\r\n <th align=\"right\">State/Province (ST):</th>\r\n <td>\r\n <input type=\"hidden\" name=\"reqST\" value=\"");
080 out.print(reqST);
081 out.write("\"/> ");
082 out.print(reqST);
083 out.write("</td>\r\n </tr>\r\n <tr>\r\n <th align=\"right\">Country Code (2 char) (C):</th>\r\n <td>\r\n <input type=\"hidden\" name=\"reqC\" value=\"");
084 out.print(reqC);
085 out.write("\"/> ");
086 out.print(reqC);
087 out.write("</td>\r\n </tr>\r\n <tr>\r\n <th align=\"right\">Challenge Phrase:</th>\r\n <td>\r\n ********\r\n </td>\r\n </tr>\r\n <tr>\r\n <th align=\"right\">Key Size:</th>\r\n <td>\r\n <keygen name=\"spkac\" challenge=\"");
088 out.print(challenge);
089 out.write("\"/>\r\n </td>\r\n </tr>\r\n </table>\r\n <input type=\"submit\" value=\"Submit Certificate Request\"/>\r\n <input type=\"reset\" name=\"reset\" value=\"Reset\"/>\r\n</form>\r\n");
090 out.write("</div>\r\n\r\n<div id=\"IE-Content\" style=\"display:none\">\r\n<p> This is step 2 of 2 in requesting your certificate. Please review your name details.\r\n Upon clicking the <i>Submit Certificate Request</i> button, your certificate request will be generated\r\n and sent to the CA for further processing.</p>\r\n\r\n");
091 out.write("<object classid=\"clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1\"\r\n codebase=\"xenroll.dll\"\r\n id=\"newCertHelper\">\r\n</object>\r\n\r\n");
092 out.write("<SCRIPT language=\"VBScript\">\r\n<!--\r\nSub GenerateReq\r\n ' Distinguished name variable.\r\n Dim strDN\r\n\r\n ' Request Variable.\r\n Dim strReq\r\n\r\n ' Request Disposition.\r\n Dim nDisp\r\n\r\n ' Enable error handling.\r\n On Error Resume Next\r\n\r\n ' Constants For CertRequest object.\r\n const CR_IN_BASE64 = &H1\r\n const CR_IN_PKCS10 = &H100\r\n\r\n ' Build the DN.\r\n strDN = \"CN=\"&document.Confirmform.reqCN.value _\r\n &\",OU=\"&document.Confirmform.reqOU.value _\r\n &\",O=\"&document.Confirmform.reqO.value _\r\n &\",L=\"&document.Confirmform.reqL.value _\r\n &\",ST=\"&document.Confirmform.reqST.value _\r\n &\",C=\"&document.Confirmform.reqC.value _\r\n '&\",CC=ask\" \r\n ' Attempt to use the control, in this case, to create a PKCS #10.\r\n strReq = newCertHelper.CreatePKCS10(strDN, \" \")\r\n ' If above line failed, Err.Number will not be 0.\r\n if ( Err.Number <> 0 ) then\r\n MsgBox(\"Error in call to createPKCS10 \" & Err.Number)\r\n err.clear\r\n return\r\n");
093 out.write(" else\r\n document.Confirmform.pkcs10req.value = strReq\r\n end if\r\n document.Confirmform.submit()\r\nEnd Sub\r\n-->\r\n</SCRIPT>\r\n\r\n<form name=\"Confirmform\" action=\"CertificateRequestServlet\" method=\"post\">\r\n <table border=\"0\">\r\n <tr>\r\n <th align=\"right\">Common Name (CN):</th>\r\n <td>\r\n <input type=\"hidden\" name=\"reqCN\" value=\"");
094 out.print(reqCN);
095 out.write("\"/> ");
096 out.print(reqCN);
097 out.write("</td>\r\n </tr>\r\n <tr>\r\n <th align=\"right\">Division/Business Unit (OU):</th>\r\n <td>\r\n <input type=\"hidden\" name=\"reqOU\" value=\"");
098 out.print(reqOU);
099 out.write("\"/> ");
100 out.print(reqOU);
101 out.write("</td>\r\n </tr>\r\n <tr>\r\n <th align=\"right\">Company/Organization (O):</th>\r\n <td>\r\n <input type=\"hidden\" name=\"reqO\" value=\"");
102 out.print(reqO);
103 out.write("\"/> ");
104 out.print(reqO);
105 out.write("</td>\r\n </tr>\r\n <tr>\r\n <th align=\"right\">City/Locality (L):</th>\r\n <td>\r\n <input type=\"hidden\" name=\"reqL\" value=\"");
106 out.print(reqL);
107 out.write("\"/> ");
108 out.print(reqL);
109 out.write("</td>\r\n </tr>\r\n <tr>\r\n <th align=\"right\">State/Province (ST):</th>\r\n <td>\r\n <input type=\"hidden\" name=\"reqST\" value=\"");
110 out.print(reqST);
111 out.write("\"/> ");
112 out.print(reqST);
113 out.write("</td>\r\n </tr>\r\n <tr>\r\n <th align=\"right\">Country Code (2 char) (C):</th>\r\n <td>\r\n <input type=\"hidden\" name=\"reqC\" value=\"");
114 out.print(reqC);
115 out.write("\"/> ");
116 out.print(reqC);
117 out.write("<input type=\"hidden\" name=\"pkcs10req\"> ");
118 out.write("</td>\r\n </tr>\r\n <tr>\r\n <th align=\"right\">Challenge Phrase:</th>\r\n <td>\r\n Not Supported for IE\r\n </td>\r\n </tr>\r\n </table>\r\n <input type=\"button\" value=\"Submit Certificate Request\" onClick=\"GenerateReq()\"/>\r\n</form>\r\n");
119 out.write("</div>\r\n\r\n<!-- The following is used to detect if the browser supports KEYGEN tag and disply only the relevant form -->\r\n<div style=\"display:none\"><form name='keygentest' method=\"POST\"><keygen name=\"test\"/></form></div>\r\n<SCRIPT language=\"JavaScript\">\r\nif(document.keygentest.elements.length == 0)\r\n document.getElementById('IE-Content').style.display = 'block'\r\nelse\r\n document.getElementById('Non-IE-Content').style.display = 'block'\r\n</SCRIPT>\r\n\r\n<a href=\"");
120 out.print(request.getContextPath());
121 out.write("\">Cancel</a>\r\n</body>\r\n</html>\r\n");
122 } catch (Throwable t) {
123 if (!(t instanceof SkipPageException)){
124 out = _jspx_out;
125 if (out != null && out.getBufferSize() != 0)
126 try { out.clearBuffer(); } catch (java.io.IOException e) {}
127 if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
128 }
129 } finally {
130 _jspxFactory.releasePageContext(_jspx_page_context);
131 }
132 }
133 }