]> git.donarmstrong.com Git - debbugs.git/blobdiff - Debbugs/CGI/Bugreport.pm
Linkify CVE reports (closes: #568464). Thanks to Martin Zobel-Helas.
[debbugs.git] / Debbugs / CGI / Bugreport.pm
index c9103ba470bdc8cb6797a9da1f59d90c9ae78b9d..ba4c7a4f30ee3185b9eb5dc377a177bc914b18da 100644 (file)
@@ -251,7 +251,13 @@ sub display_entity {
                    $temp =~ s{(\d+)}
                              {bug_links(bug=>$1)}ge;
                    $temp;]gxie;
-
+        if (defined $config{cve_tracker} and
+            length $config{cve_tracker}
+           ) {
+            # Add links to CVE vulnerabilities (closes #568464)
+            $body =~ s{(CVE-\d{4}-\d{4,})}
+                      {<a href="http://$config{cve_tracker}$1">$1</a>}gx;
+        }
         if (not exists $param{att}) {
              print {$param{output}} qq(<pre class="message">$body</pre>\n);
         }