mirror of
https://github.com/ysoftdevs/DependencyCheck.git
synced 2026-03-25 02:21:28 +01:00
updated to add scan information
Former-commit-id: b73ea598f34cbdbaf6d8f97ada6624875232f1da
This commit is contained in:
@@ -16,7 +16,7 @@ limitations under the License.
|
|||||||
Copyright (c) 2012 Jeremy Long. All Rights Reserved.
|
Copyright (c) 2012 Jeremy Long. All Rights Reserved.
|
||||||
|
|
||||||
@author Jeremy Long <jeremy.long@owasp.org>
|
@author Jeremy Long <jeremy.long@owasp.org>
|
||||||
@version 1
|
@version 1.1
|
||||||
*#
|
*#
|
||||||
|
|
||||||
|
|
||||||
@@ -52,17 +52,17 @@ Copyright (c) 2012 Jeremy Long. All Rights Reserved.
|
|||||||
});
|
});
|
||||||
|
|
||||||
$(function(){
|
$(function(){
|
||||||
$("#modal-background, #modal-close").click(function () {
|
$('#modal-background, #modal-close').click(function () {
|
||||||
$("#modal-content,#modal-background").toggleClass("active");
|
$('#modal-content,#modal-background').toggleClass('active');
|
||||||
});
|
});
|
||||||
$("#modal-text").bind('copy cut', function() {
|
$('#modal-text').bind('copy cut', function() {
|
||||||
setTimeout('$("#modal-content,#modal-background").toggleClass("active");',100);
|
setTimeout('$("#modal-content,#modal-background").toggleClass("active");',100);
|
||||||
});
|
});
|
||||||
$("#modal-add-header").click(function () {
|
$('#modal-add-header').click(function () {
|
||||||
xml = '<?xml version="1.0" encoding="UTF-8"?>\n<suppressions xmlns="https://www.owasp.org/index.php/OWASP_Dependency_Check_Suppression">\n ';
|
xml = '<?xml version="1.0" encoding="UTF-8"?>\n<suppressions xmlns="https://www.owasp.org/index.php/OWASP_Dependency_Check_Suppression">\n ';
|
||||||
xml += $("#modal-text").text().replace(/\n/g,'\n ');
|
xml += $("#modal-text").text().replace(/\n/g,'\n ');
|
||||||
xml += '\n</suppressions>';
|
xml += '\n</suppressions>';
|
||||||
$("#modal-text").text(xml).focus().select();
|
$('#modal-text').text(xml).focus().select();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -72,14 +72,28 @@ Copyright (c) 2012 Jeremy Long. All Rights Reserved.
|
|||||||
xml += ' <sha1>' + sha1 + '</sha1>\n';
|
xml += ' <sha1>' + sha1 + '</sha1>\n';
|
||||||
xml += ' <'+type+'>' + val + '</'+type+'>\n';
|
xml += ' <'+type+'>' + val + '</'+type+'>\n';
|
||||||
xml += '</suppress>';
|
xml += '</suppress>';
|
||||||
$("#modal-text").text(xml);
|
$('#modal-text').text(xml);
|
||||||
$("#modal-content,#modal-background").toggleClass("active");
|
$('#modal-content,#modal-background').toggleClass('active');
|
||||||
$("#modal-text").focus();
|
$('#modal-text').focus();
|
||||||
$("#modal-text").select();
|
$('#modal-text').select();
|
||||||
}
|
}
|
||||||
|
|
||||||
function toggleVuln() {
|
function toggleVuln(el) {
|
||||||
$(".notvulnerable").toggle();
|
$('.notvulnerable').toggle();
|
||||||
|
if (el.innerHTML == 'show all') {
|
||||||
|
el.innerHTML = 'hide';
|
||||||
|
} else {
|
||||||
|
el.innerHTML = 'show all';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function toggleMore(el) {
|
||||||
|
$('.hiddenInfo').toggle();
|
||||||
|
$('.nothidden').toggle();
|
||||||
|
if (el.innerHTML == 'more') {
|
||||||
|
el.innerHTML = 'less';
|
||||||
|
} else {
|
||||||
|
el.innerHTML = 'more';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<style type="text/css">
|
<style type="text/css">
|
||||||
@@ -406,6 +420,15 @@ Copyright (c) 2012 Jeremy Long. All Rights Reserved.
|
|||||||
.notvulnerable {
|
.notvulnerable {
|
||||||
display:none;
|
display:none;
|
||||||
}
|
}
|
||||||
|
.hiddenInfo {
|
||||||
|
display:none;
|
||||||
|
}
|
||||||
|
.hiddennow {
|
||||||
|
display:none;
|
||||||
|
}
|
||||||
|
.nothidden {
|
||||||
|
display:block;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
@@ -420,6 +443,14 @@ Copyright (c) 2012 Jeremy Long. All Rights Reserved.
|
|||||||
]]#
|
]]#
|
||||||
<h2 class="sectionheader white">Project: $esc.html($applicationName)</h2>
|
<h2 class="sectionheader white">Project: $esc.html($applicationName)</h2>
|
||||||
<div class="sectioncontent">Report Generated On: $date<br/><br/>
|
<div class="sectioncontent">Report Generated On: $date<br/><br/>
|
||||||
|
Scan Information (<a href="#" onclick="toggleMore(this);">more</a>):<br/>
|
||||||
|
<ul class="indent">
|
||||||
|
<li><i>dependency-check version</i>: $version</li>
|
||||||
|
<li class="hiddennow nothidden">...</li>
|
||||||
|
#foreach($prop in $properties.getMetaData().entrySet())
|
||||||
|
<li class="hiddenInfo"><i>$esc.html($prop.key)</i>: $esc.html($prop.value)</li>
|
||||||
|
#end
|
||||||
|
</ul><br/>
|
||||||
#set($depCount=$dependencies.size())
|
#set($depCount=$dependencies.size())
|
||||||
#set($vulnCount=0)
|
#set($vulnCount=0)
|
||||||
|
|
||||||
@@ -429,7 +460,7 @@ Copyright (c) 2012 Jeremy Long. All Rights Reserved.
|
|||||||
#set($vulnCount=$vulnCount+1)
|
#set($vulnCount=$vulnCount+1)
|
||||||
#end
|
#end
|
||||||
#end
|
#end
|
||||||
Dependencies Scanned: $depCount (<a href="#" onclick="toggleVuln()">show all</a>)<br/>
|
Dependencies Scanned: $depCount (<a href="#" onclick="toggleVuln(this)">show all</a>)<br/>
|
||||||
Vulnerable Dependencies: $vulnCount<br/><br/>
|
Vulnerable Dependencies: $vulnCount<br/><br/>
|
||||||
<ul class="indent">
|
<ul class="indent">
|
||||||
#set($lnkcnt=0)
|
#set($lnkcnt=0)
|
||||||
|
|||||||
Reference in New Issue
Block a user