-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added additional templates for rendering the results as an html table (…
…#15) Co-authored-by: Britton Hayes <[email protected]>
- Loading branch information
1 parent
2b35e86
commit 4a9eff0
Showing
8 changed files
with
146 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
<!DOCTYPE html> | ||
<html lang="en-us"> | ||
<head> | ||
<meta charset="utf-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1"> | ||
<title>Pillager - Scan Results</title> | ||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/css/bulma.min.css"> | ||
</head> | ||
<body> | ||
<section class="section"> | ||
<div class="container"> | ||
<h1 class="title has-text-info"> | ||
Pillager | ||
</h1> | ||
<p class="subtitle"> | ||
Results of your latest hunt | ||
</p> | ||
<div class="columns is-multiline"> | ||
{{ range .Leaks }} | ||
<div class="column"> | ||
<div class="box shadow-md"> | ||
<p class="is-size-4">{{.File}}</p> | ||
<p> | ||
<span class="has-text-weight-bold">Tags:</span> | ||
<span class="tag">{{.Tags}}</span> | ||
</p> | ||
<p> | ||
<span class="has-text-weight-bold">Leak:</span> | ||
<span class="is-family-code has-text-danger">{{.Offender}}</span> | ||
</p> | ||
<p> | ||
<span class="has-text-weight-bold">Line:</span> | ||
{{.LineNumber}} | ||
</p> | ||
</div> | ||
</div> | ||
{{end}} | ||
</div> | ||
</div> | ||
</section> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{{/*markdown.tmpl*/}} | ||
# Results | ||
{{ range .Leaks}} | ||
{{ range .Leaks -}} | ||
## {{ .File }} | ||
- Location: {{.LineNumber}} | ||
{{end}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
<!DOCTYPE html> | ||
<html lang="en-us"> | ||
<head> | ||
<meta charset="utf-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1"> | ||
<title>Pillager - Scan Results</title> | ||
<style type="text/css"> | ||
.offender { | ||
-webkit-text-security: disc !important; | ||
} | ||
|
||
.offender:hover { | ||
-webkit-text-security: none; | ||
} | ||
</style> | ||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/css/bulma.min.css"> | ||
</head> | ||
<body> | ||
<section class="hero is-black"> | ||
<div class="hero-body"> | ||
<p class="title"> | ||
Pillager | ||
</p> | ||
<p class="subtitle"> | ||
Results of your latest hunt | ||
</p> | ||
</div> | ||
</section> | ||
<section class="section"> | ||
<div class="container"> | ||
<div class="table-container"> | ||
<table class="table is-fullwidth"> | ||
<thead> | ||
<tr> | ||
<th><abbr title="Filename">File</abbr></th> | ||
<th><abbr title="Line Number">Line</abbr></th> | ||
<th><abbr title="Offender">Leak</abbr></th> | ||
</tr> | ||
</thead> | ||
<tbody> | ||
{{ range .Leaks }} | ||
<tr> | ||
<th>{{.File}}</th> | ||
<td>{{.LineNumber}}</td> | ||
<td class="has-text-danger">{{.Offender}}</td> | ||
</tr> | ||
{{ end }} | ||
</tbody> | ||
</table> | ||
</div> | ||
</div> | ||
</section> | ||
|
||
</body> | ||
</html> |