-
Notifications
You must be signed in to change notification settings - Fork 131
Expand file tree
/
Copy pathreport_template.html
More file actions
executable file
·168 lines (154 loc) · 3.99 KB
/
Copy pathreport_template.html
File metadata and controls
executable file
·168 lines (154 loc) · 3.99 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
<html>
<head>
<title></title>
<style>
*, html, body {
font-size: 0.99em;
}
.heading1 {
margin-left: 60px;
}
.heading2 {
margin-left: 60px;
}
.heading2 {
margin-left: 30px;
}
pre {
border: 1px solid #000;
padding: 5px;
}
.command {
color: #AAA;
}
.grep {
font-family: monospace;
}
.grep_filepath {
color: #00F;
}
.grep_line {
color: #5A5;
}
.grep_keyword {
color: #F00;
}
.hide {
color: #AAA;
}
.warning {
color: #F00;
}
.infos {
font-size: 10pt;
font-style: italic;
}
.unit {
margin-left: 150px;
border: 1px solid #000;
}
.findings-table {
width: 100%;
border-collapse: collapse;
font-size: 0.9em;
margin-top: 10px;
}
.findings-table th, .findings-table td {
border: 1px solid #ccc;
padding: 6px 8px;
vertical-align: top;
text-align: left;
}
.findings-table th {
background: #f0f0f0;
font-weight: bold;
}
.findings-table code {
font-family: monospace;
font-size: 0.85em;
word-break: break-all;
}
.sev-critical { color: #c00; font-weight: bold; }
.sev-high { color: #e55; font-weight: bold; }
.sev-medium { color: #e90; }
.sev-low { color: #555; }
.sev-info { color: #aaa; }
</style>
</head>
<body>
<ul id="menu"></ul>
<div class="heading heading1">
<h1>Basic Information</h1>
<div id="infos">
<div>Report Date: {{ date }}</div>
<div>Package: {{ package_name }}</div>
<div>Build: {{ build }}</div>
<div>Android Version: {{ android_version }}</div>
</div>
</div>
<hr />
<div class="heading heading1">
<h1>Permissions</h1>
<div id="infos">
<div>{{ permissions }}</div>
</div>
</div>
<hr />
<div class="heading heading1">
<h1>Dangerous Permissions</h1>
<div id="infos">
<div>{{ dangerous_permission }}</div>
</div>
</div>
<hr />
<div class="heading heading1">
<h1>Manifest Security Issues</h1>
<div id="infos">
<div>{{ manifest_security_html }}</div>
</div>
</div>
<hr />
<div class="heading heading1">
<h1>Code Security Findings</h1>
<div id="infos">
<div>{{ code_findings_html }}</div>
</div>
</div>
<hr />
<div class="heading heading1">
<h1>Intents</h1>
<div class="grep">{{ intent_grep }}</div>
</div>
<hr />
<div class="heading heading1">
<h1>Storage</h1>
<div class="heading heading2">
<h2>Internal storage</h2>
<div class="grep">{{ internal_storage_grep }}</div>
</div>
<div class="heading heading2">
<h2>External storage</h2>
<div class="grep">{{ external_storage_grep }}</div>
</div>
</div>
<hr />
<!-- Your JavaScript stays the same -->
<script type="text/javascript" src="jquery-3.4.1.slim.min.js"></script>
<script>
var cur = 1;
var str = '';
var menu = $('#menu');
$('body').find(':header').each(function(index){
lvl = $(this).prop('tagName').replace('H','');
if( lvl > cur ) {
str = str + '<ul>';
} else if( lvl < cur ) {
str = str + '</ul>';
}
cur = lvl;
str = str + '<li><a href="">' + $(this).text() + '</a></li>';
});
menu.append( str );
</script>
</body>
</html>