-
Notifications
You must be signed in to change notification settings - Fork 27
/
agents-ca.html
193 lines (182 loc) · 10.4 KB
/
agents-ca.html
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
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
<md-content flex layout="column" layout-align="start">
<!-- Breadcrumbs -->
<div layout="row" class="wz-height-35">
<!-- If you're not on the Welcome tab, show a functional breadcrumb -->
<div class='wz-breadcrumb-margin'>
<a class="wz-text-link cursor-pointer" ui-sref='agents'>Agents</a>
<span> / </span>
<span ng-if="!agent.error" ui-sref='agent-overview({id:agent.id})'
class="wz-text-link cursor-pointer">{{agent.name}}
({{agent.id}})</span>
<span ng-if="agent.error">Unknown agent</span>
<span> / </span>
<span>Configuration assessment</span>
</div>
<div ng-if="agent.status">
<span class="wz-agent-status-indicator small" ng-class="getAgentStatusClass(agent.status)"
aria-label="Agent status indicator">{{formatAgentStatus(agent.status)}}</span>
</div>
<div flex></div>
<!-- Report button -->
<div style="display:flex; padding-right: 10px;">
<span class='wz-margin-right-15 wz-margin-top-12' ng-hide='!loadingVizz'>Waiting for reporting information <i
class="fa fa-fw fa-spin fa-spinner" aria-hidden="true"></i></span>
<wz-discover
breadcrumbs="{section: 'Agents', subSection: 'Policity monitoring', agentName: agent.name, agentId: agent.id, ref: 'agents', agentRef: 'agent-overview'}">
</wz-discover>
</div>
<div style="margin-right:7px;" id='timePicker'></div>
</div>
<!-- Loading report-->
<div text-align='center' ng-if='loadingReporting'>{{reportStatus}}<br><i class="fa fa-fw fa-spin fa-spinner"
aria-hidden="true"></i></div>
<!-- Auditing and Policy Monitoring navbar -->
<md-nav-bar class="wz-nav-bar wz-margin-10 no-margin-left" md-selected-nav-item="'sca'">
<md-nav-item class="wz-nav-item" md-nav-click="stopPropagation()" ui-sref="ag-pm" name="pm">Policy monitoring
</md-nav-item>
<md-nav-item class="wz-nav-item" md-nav-click="stopPropagation()" name="sca">SCA</md-nav-item>
<md-nav-item ng-if="extensions.audit === 'true'" class="wz-nav-item" md-nav-click="stopPropagation()"
ui-sref="ag-audit" name="audit">System auditing</md-nav-item>
<md-nav-item ng-if="extensions.oscap === 'true'" class="wz-nav-item" md-nav-click="stopPropagation()"
ui-sref="ag-os" name="openscap">OpenSCAP</md-nav-item>
<md-nav-item ng-if="extensions.ciscat === 'true'" class="wz-nav-item" md-nav-click="stopPropagation()"
ui-sref="ag-ciscat" name="ciscat">CIS-CAT</md-nav-item>
</md-nav-bar>
<div>
<!-- Policies list -->
<div ng-show="!showPolicyChecks">
<div ng-show="configAssess.length">
<div class="md-padding layout-row" ng-if="agent && agent.os">
<div class="layout-column md-padding wz-width-25" ng-repeat="policy in configAssess">
<span class="wz-headline-title">{{policy.name}}</span>
<md-divider class="wz-margin-top-10"></md-divider>
<canvas id="{{policy.policy_id}}" class=" wz-margin-top-10 chart chart-doughnut"
ng-init="loadCharts(policy)" height="150">
</div>
</div>
</div>
<div layout="row" class="wz-margin-top-10 wz-margin-right-8 wz-margin-left-8"
ng-if="showPolicies && (!agent || !agent.os)">
<div flex class="euiCallOut euiCallOut--warning">
<div class="euiCallOutHeader">
<svg class="euiIcon euiIcon--medium euiCallOutHeader__icon" aria-hidden="true"
xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="16" height="16"
viewBox="0 0 16 16">
<defs>
<path id="help-a"
d="M13.6 12.186l-1.357-1.358c-.025-.025-.058-.034-.084-.056.53-.794.84-1.746.84-2.773a4.977 4.977 0 0 0-.84-2.772c.026-.02.059-.03.084-.056L13.6 3.813a6.96 6.96 0 0 1 0 8.373zM8 15A6.956 6.956 0 0 1 3.814 13.6l1.358-1.358c.025-.025.034-.057.055-.084C6.02 12.688 6.974 13 8 13a4.978 4.978 0 0 0 2.773-.84c.02.026.03.058.056.083l1.357 1.358A6.956 6.956 0 0 1 8 15zm-5.601-2.813a6.963 6.963 0 0 1 0-8.373l1.359 1.358c.024.025.057.035.084.056A4.97 4.97 0 0 0 3 8c0 1.027.31 1.98.842 2.773-.027.022-.06.031-.084.056l-1.36 1.358zm5.6-.187A4 4 0 1 1 8 4a4 4 0 0 1 0 8zM8 1c1.573 0 3.019.525 4.187 1.4l-1.357 1.358c-.025.025-.035.057-.056.084A4.979 4.979 0 0 0 8 3a4.979 4.979 0 0 0-2.773.842c-.021-.027-.03-.059-.055-.084L3.814 2.4A6.957 6.957 0 0 1 8 1zm0-1a8.001 8.001 0 1 0 .003 16.002A8.001 8.001 0 0 0 8 0z">
</path>
</defs>
<use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#help-a" fill-rule="evenodd"></use>
</svg>
<span class="euiCallOutHeader__title">This agent is never connected.</span>
</div>
</div>
</div>
<div ng-if="configAssess.length" layout="row" class="wz-padding-top-0" ng-if="agent && agent.os">
<md-card flex="" class="wz-md-card _md flex">
<md-card-content>
<span class="wz-headline-title"><i class="fa fa-fw fa-shield"></i> Configuration assessment</span>
<md-divider class="wz-margin-top-10"></md-divider>
<table class="table table-condensed table-layout-fixed table-hover table-vertical-align-middle">
<thead>
<th class="wz-nowrap">Policy</th>
<th class="wz-nowrap">Description</th>
<th class="wz-nowrap">Last scan</th>
<th class="wz-nowrap">Pass</th>
<th class="wz-nowrap">Fail</th>
<th class="wz-nowrap">Not applicable</th>
<th class="wz-nowrap">Score</th>
</thead>
<tbody>
<tr class="wz-word-wrap" ng-repeat="policy in configAssess track by $index">
<td ng-click="loadPolicyChecks(policy)" class="wz-text-link cursor-pointer">
{{policy.name}}</td>
<td>{{policy.description}}</td>
<td>{{policy.end_scan}}</td>
<td>{{policy.pass}}</td>
<td>{{policy.fail}}</td>
<td>{{policy.invalid}}</td>
<td>{{policy.score}}%</td>
</tr>
</tbody>
</table>
</md-card-content>
</md-card>
</div>
<div ng-if="!configAssess.length" layout="row" class="wz-padding-top-0" ng-if="agent && agent.os">
<md-card flex="60" class="wz-md-card center">
<md-card-content class="wazuh-column">
<span class="wz-headline-title">
<i class="fa fa-exclamation-triangle" aria-hidden="true"></i>
No scans available.
<md-divider class="wz-margin-top-10"></md-divider>
<button class="btn wz-button-empty wz-margin-top-15" ng-click="refreshScans()" aria-label="Refresh">
<wz-svg icon="refresh"></wz-svg>
Refresh
</button>
</span>
</md-card-content>
</md-card>
</div>
</div>
<!-- Policies checks table -->
<div ng-if="showPolicyChecks">
<div layout="row" class="wz-margin-top-10 wz-margin-right-8 wz-margin-left-8"
ng-if="showPolicies && (!agent || !agent.os)">
<div flex class="euiCallOut euiCallOut--warning">
<div class="euiCallOutHeader">
<svg class="euiIcon euiIcon--medium euiCallOutHeader__icon" aria-hidden="true"
xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="16" height="16"
viewBox="0 0 16 16">
<defs>
<path id="help-a"
d="M13.6 12.186l-1.357-1.358c-.025-.025-.058-.034-.084-.056.53-.794.84-1.746.84-2.773a4.977 4.977 0 0 0-.84-2.772c.026-.02.059-.03.084-.056L13.6 3.813a6.96 6.96 0 0 1 0 8.373zM8 15A6.956 6.956 0 0 1 3.814 13.6l1.358-1.358c.025-.025.034-.057.055-.084C6.02 12.688 6.974 13 8 13a4.978 4.978 0 0 0 2.773-.84c.02.026.03.058.056.083l1.357 1.358A6.956 6.956 0 0 1 8 15zm-5.601-2.813a6.963 6.963 0 0 1 0-8.373l1.359 1.358c.024.025.057.035.084.056A4.97 4.97 0 0 0 3 8c0 1.027.31 1.98.842 2.773-.027.022-.06.031-.084.056l-1.36 1.358zm5.6-.187A4 4 0 1 1 8 4a4 4 0 0 1 0 8zM8 1c1.573 0 3.019.525 4.187 1.4l-1.357 1.358c-.025.025-.035.057-.056.084A4.979 4.979 0 0 0 8 3a4.979 4.979 0 0 0-2.773.842c-.021-.027-.03-.059-.055-.084L3.814 2.4A6.957 6.957 0 0 1 8 1zm0-1a8.001 8.001 0 1 0 .003 16.002A8.001 8.001 0 0 0 8 0z">
</path>
</defs>
<use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#help-a" fill-rule="evenodd"></use>
</svg>
<span class="euiCallOutHeader__title">This agent is never connected.</span>
</div>
</div>
</div>
<div layout="row" class="wz-padding-top-0" ng-if="agent && agent.os">
<md-card flex="" class="wz-md-card _md flex">
<md-card-content>
<span class="sca-title">
<i class="fa fa-fw fa-arrow-left cursor-pointer" ng-click="backToConfAssess()">
<md-tooltip class="wz-tooltip" md-direction="top">
Back to Configuration assessment
</md-tooltip>
</i>
{{policy.name}}
<span class="sca-title-checks">
Pass: <b>{{policy.pass}}</b>
Failed: <b>{{policy.fail}}</b>
Not applicable: <b>{{policy.invalid}}</b>
Score: <b>{{policy.score}}%</b>
</span>
</span>
<md-divider class="wz-margin-top-10"></md-divider>
<span class="sca-hash">Policy checksum: {{policy.hash_file}}</span>
<div flex layout="row">
<div class="wz-width-100 wz-margin-bottom-25">
<label class="wz-icon-loupe">
<input id="search-input-rules" placeholder="Filter checks..." ng-model="customSearch" type="text" flex
class="kuiLocalSearchInput height-40" aria-invalid="false" wz-enter="search(customSearch)">
</label>
</div>
<button type="submit" aria-label="Search" class="btn height-40 wz-button-empty wz-margin-left-10"
ng-click="search(customSearch)">
<span>Search</span>
</button>
</div>
<wazuh-table flex path="wzTablePath" row-sizes="[13,11,9]" extra-limit="100"
keys="['id', 'title','file','result']" implicit-sort="'id'">
</wazuh-table>
</md-card-content>
</md-card>
</div>
</div>
</div>
</md-content>