diff xsls/security.xsls @ 0:61e04fc01027

Initial import of the nginx.org website.
author Ruslan Ermilov <ru@nginx.com>
date Thu, 11 Aug 2011 12:19:13 +0000
parents
children c007b57d617c
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/xsls/security.xsls	Thu Aug 11 12:19:13 2011 +0000
@@ -0,0 +1,113 @@
+X:stylesheet {
+
+X:output method="html" indent="no" encoding="utf-8";
+
+X:strip-space elements = "*";
+
+<!--
+  -- a current directory of a XSLT script is where the script is stored,
+  -- but not where XSLT processor has been started to run the script
+  -->
+X:param XML = "'../xml'";
+X:param YEAR;
+
+X:var LINK = "/article/@link";
+
+X:include href = "dirname.xslt";
+X:include href = "link.xslt";
+X:include href = "style.xslt";
+X:include href = "body.xslt";
+X:include href = "menu.xslt";
+X:include href = "content.xslt";
+
+
+X:template = "/article" {
+    <html><head>
+
+    <title> !{@title} </title>
+
+    !style ()
+
+    </head>
+
+    !body (lang="/article/@lang")
+
+    </html>
+}
+
+
+X:template = "security" { <ul> !!; </ul> }
+
+
+X:template = "security/item" {
+
+    <li>
+    <p class="noindent">
+
+    !{@title}<br/>
+
+    X:if "@severity = 'major'" {
+        X:text{Severity: } <b>!{@severity}</b><br/>
+    } else {
+        X:text{Severity: } !{@severity}<br/>
+    }
+
+    X:if "@cert" {
+        <a>
+        X:attribute "href" {
+            X:text {http://www.kb.cert.org/vuls/id/} !{@cert}
+        }
+        X:text {VU#} !{@cert}
+        </a>
+    }
+
+    X:if "@cve" {
+        X:if "@cert" {
+            X:text {&#xA0;&#xA0;}
+        }
+        <a>
+        X:attribute "href" {
+            X:text {http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-} !{@cve}
+        }
+        X:text {CVE-} !{@cve}
+        </a>
+    }
+
+    X:if "@core" {
+        X:if "@cert or @cve" {
+            X:text {&#xA0;&#xA0;}
+        }
+        <a href="{@href}"> !{@core} </a>
+    }
+
+    X:if "@cert or @cve or @core" {
+        <br/>
+    }
+
+    X:text {Not vulnerable: } !{@good} <br/>
+    X:text {Vulnerable: } !{@vulnerable} <br/>
+
+    X:if "@patch" {
+        <a>
+        X:attribute "href" {
+            X:text {/download/} !{@patch}
+        }
+        X:text {The patch}
+        </a>
+
+        X:text {&#xA0;&#xA0;}
+
+        <a>
+        X:attribute "href" {
+            X:text {/download/} !{@patch} X:text {.asc}
+        }
+        X:text {pgp}
+        </a>
+    }
+
+    </p>
+    </li>
+}
+
+
+}