diff options
Diffstat (limited to 'pdf-as-web/src/main/webapp/jsp/results.jsp')
-rw-r--r-- | pdf-as-web/src/main/webapp/jsp/results.jsp | 84 |
1 files changed, 84 insertions, 0 deletions
diff --git a/pdf-as-web/src/main/webapp/jsp/results.jsp b/pdf-as-web/src/main/webapp/jsp/results.jsp new file mode 100644 index 0000000..8301e43 --- /dev/null +++ b/pdf-as-web/src/main/webapp/jsp/results.jsp @@ -0,0 +1,84 @@ +<%@page import="at.gv.egiz.pdfas.api.verify.VerifyResult"%>
+<%@page import="at.gv.egiz.pdfas.api.verify.VerifyResults"%>
+<%@ page contentType="text/html; charset=UTF-8" %>
+<%@ page import="java.util.List" %>
+<%@ page import="java.util.Iterator" %>
+
+<%@ include file="language.jsp" %>
+
+<%
+ VerifyResults results = (VerifyResults) request.getAttribute("results");
+ Object bb = request.getAttribute("backbutton");
+ String btlurl = (String)request.getAttribute("btlurl");
+ boolean backbutton = true;
+ if (bb != null && bb.equals("false")) {
+ backbutton = false;
+ }
+%>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html>
+ <head>
+ <title><fmt:message key="common.title"/></title>
+ </head>
+ <body>
+ <h1><fmt:message key="common.title"/></h1>
+ <h2><fmt:message key="results.heading2"/></h2>
+ <%
+ Iterator resit = results.getResults().iterator();
+ while (resit.hasNext()) {
+ VerifyResult result = (VerifyResult) resit.next();
+ String subject = result.getSignerCertificate().getSubjectDN().getName();
+ String issuer = result.getSignerCertificate().getIssuerDN().getName();
+ String serial = result.getSignerCertificate().getSerialNumber().toString();
+ %>
+
+ <div class="pdfasverticalspace"></div>
+ <fieldset class="pdfasresultfieldset">
+ <legend><b><fmt:message key="results.signaturecheck"/></b></legend>
+ <div class="<%= (result.getValueCheckCode().getCode() == 0) ? "pdfasok" : "pdfasnok" %>"><%= result.getValueCheckCode().getMessage() %></div>
+ </fieldset>
+
+ <div class="pdfassmallverticalspace"></div>
+ <fieldset class="pdfasresultfieldset">
+ <legend><b><fmt:message key="results.certificatecheck"/></b></legend>
+ <table class="pdfaslisttable" cellpadding="1" cellspacing="1">
+ <tr><td class="pdfascaption"><fmt:message key="results.signer"/>:</td><td class="pdfasvalue"><%= subject %></td></tr>
+ <tr><td class="pdfascaption"><fmt:message key="results.issuer"/>:</td><td class="pdfasvalue"><%= issuer %></td></tr>
+ <tr><td class="pdfascaption"><fmt:message key="results.serialnumber"/>:</td><td class="pdfasvalue"><%= serial %></td></tr>
+ <%
+ List public_properties = result.getPublicProperties();
+ Iterator propit = public_properties.iterator();
+ while (propit.hasNext()) {
+ String public_property = (String) propit.next();
+ %>
+ <tr><td class="pdfascaption"><fmt:message key="results.property"/>:</td><td class="pdfasvalue"><%= public_property %></td></tr>
+ <%
+ }
+ %>
+ <tr><td class="pdfascaption"><fmt:message key="results.certificate"/>:</td><td class="<%= (result.getCertificateCheck().getCode() == 0) ? "pdfasok" : "pdfasnok" %>"><%= result.getCertificateCheck().getMessage() %></td></tr>
+ </table>
+ </fieldset>
+
+ <div class="pdfassmallverticalspace"></div>
+ <fieldset class="pdfasresultfieldset">
+ <legend><b><fmt:message key="results.manifestcheck"/></b></legend>
+ <div class="<%= (result.getManifestCheckCode().getCode() == 0) ? "pdfasok" : "pdfasnok" %>"><%= result.getManifestCheckCode().getMessage() %></div>
+ </fieldset>
+
+ <%
+ if (resit.hasNext()) {
+ %>
+ <br />
+ <%
+ }
+ }
+ %>
+ <div class="pdfasverticalspace"></div>
+ <% if (backbutton) { %>
+ <a href="<%= request.getContextPath() %>/jsp/verifyupload.jsp"><fmt:message key="common.back"/></a>
+ <% } %>
+ <% if (btlurl != null) { %>
+ <a href="<%=btlurl%>"><fmt:message key="common.backtolist"/></a>
+ <% } %>
+ </body>
+</html>
|