blob: c7f57cc1a2d4f5d6d14a1c433fd5afacebfd719c (
plain)
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
|
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Rspamd Web Interface</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="">
<meta name="author" content="">
<link rel="icon" type="image/png" sizes="32x32" href="favicon-32x32.png?v=3">
<link rel="icon" type="image/png" sizes="16x16" href="favicon-16x16.png?v=3">
<link rel="apple-touch-icon" sizes="180x180" href="apple-touch-icon.png?v=3">
<link rel="mask-icon" href="safari-pinned-tab.svg?v=3" color="#5bbad5">
<link rel="shortcut icon" href="favicon.ico?v=3">
<meta name="msapplication-TileColor" content="#2b5797">
<link href="./css/bootstrap.min.css" rel="stylesheet">
<link rel="stylesheet" type="text/css" href="./css/font-glyphicons.css">
<link rel="stylesheet" type="text/css" href="./css/footable.standalone.min.css"/>
<link rel="stylesheet" type="text/css" href="./css/FooTable.Glyphicons.css"/>
<link rel="stylesheet" type="text/css" href="./css/svg-with-js.min.css">
<link rel="stylesheet" type="text/css" href="./css/d3evolution.css">
<link rel="stylesheet" type="text/css" href="./css/d3pie.css">
<link rel="stylesheet" type="text/css" href="./css/nprogress.css"/>
<link rel="stylesheet" type="text/css" href="./css/prism.css"/>
<link href="./css/rspamd.css" rel="stylesheet">
</head>
<body>
<nav class="navbar navbar-light bg-light navbar-expand-xl d-none" id="navBar">
<div class="navbar-header navbar-brand p-0">
<img src="./img/rspamd_logo_navbar.png" alt="Rspamd">
</div>
<div class="collapse navbar-collapse order-3 order-xl-2">
<form class="form-inline my-2 mr-auto">
<select id="selSrv" class="form-control"></select>
</form>
</div>
<div class="collapse navbar-collapse order-4 order-xl-3 justify-content-center">
<ul class="nav navbar-nav nav-pills nav-tabs-sticky" role="tablist">
<li role="presentation" class="nav-item"><a id="status_nav" aria-controls="status" role="tab" href="#status" data-toggle="tab" class="nav-link">Status</a></li>
<li role="presentation" class="nav-item"><a id="throughput_nav" aria-controls="throughput" role="tab" href="#throughput" data-toggle="tab" class="nav-link">Throughput</a></li>
<li role="presentation" class="nav-item"><a id="configuration_nav" aria-controls="configuration" role="tab" href="#configuration" data-toggle="tab" class="nav-link">Configuration</a></li>
<li role="presentation" class="nav-item"><a id="symbols_nav" aria-controls="symbols" role="tab" href="#symbols" data-toggle="tab" class="nav-link">Symbols</a></li>
<li role="presentation" class="nav-item"><a id="scan_nav" aria-controls="scan" role="tab" href="#scan" data-toggle="tab" class="nav-link">Scan<span class="ro-hide" style="display: none;">/Learn</span></a></li>
<li role="presentation" class="nav-item"><a id="selectors_nav" aria-controls="selectors" role="tab" href="#selectors" data-toggle="tab" class="nav-link ro-hide" style="display: none;">Test selectors</a></li>
<li role="presentation" class="nav-item"><a id="history_nav" aria-controls="history" role="tab" href="#history" data-toggle="tab" class="nav-link">History</a></li>
</ul>
</div>
<div class="d-flex flex-row order-2 order-xl-4">
<form class="form-inline ml-auto">
<div class="btn-group">
<button class="btn btn-outline-secondary" id="refresh" style="display: none;"><i class="fas fa-sync-alt"></i> Refresh</button>
<button class="btn btn-outline-secondary dropdown-toggle dropdown-toggle-split" data-toggle="dropdown" id="autoRefresh" title="Auto-refresh time interval">
<span id="countdown">--:--</span>
</button>
<div class="dropdown-menu">
<a class="dropdown-item preset" href="#" data-value=null>Disable</a>
<div class="dropdown-divider preset" role="separator"></div>
<a class="dropdown-item preset active" href="#" data-value="10000">10 seconds</a>
<a class="dropdown-item preset" href="#" data-value="30000">30 seconds</a>
<div class="dropdown-divider preset" role="separator"></div>
<a class="dropdown-item preset" href="#" data-value="60000">1 minute</a>
<a class="dropdown-item preset" href="#" data-value="600000">10 minutes</a>
<a class="dropdown-item preset" href="#" data-value="1800000">30 minutes</a>
<div class="dropdown-divider preset" role="separator"></div>
<a class="dropdown-item preset" href="#" data-value="3600000">1 hour</a>
<a class="dropdown-item history active" href="#" data-value=null>Disable</a>
<div class="dropdown-divider history" role="separator"></div>
<a class="dropdown-item history" href="#" data-value="10000">10 seconds</a>
<a class="dropdown-item history" href="#" data-value="30000">30 seconds</a>
<div class="dropdown-divider history" role="separator"></div>
<a class="dropdown-item history" href="#" data-value="60000">1 minute</a>
<a class="dropdown-item history" href="#" data-value="600000">10 minutes</a>
<a class="dropdown-item history" href="#" data-value="1800000">30 minutes</a>
<div class="dropdown-divider history" role="separator"></div>
<a class="dropdown-item history" href="#" data-value="3600000">1 hour</a>
<a class="dropdown-item dynamic" href="#" data-value=null>Disable</a>
<div class="dropdown-divider dynamic" role="separator"></div>
<a class="dropdown-item dynamic active" href="#" id="dynamic-item" data-value="3600000">1 hour</a>
</div>
</div>
<button class="btn btn-outline-secondary ml-2" id="disconnect" title="Disconnect"><i class="fas fa-power-off"></i></button>
<button class="btn btn-outline-secondary ml-2" id="settings" title="WebUI settings"><i class="fas fa-cog"></i></button>
<div class="d-none">
<div id="settings-popover">
<div class="card">
<div class="card-body">
<h6 class="card-title font-weight-bolder">Date and time locale</h6>
<label class="ml-2">
<input type="radio" class="mr-2" name="locale" value="browser" checked>
Use browser settings
</label>
<div class="input-group input-group-sm">
<div class="input-group-prepend">
<div class="input-group-text">
<label class="my-auto">
<input type="radio" class="mr-2" name="locale" value="custom">
Custom
</label>
</div>
</div>
<input type="text" id="locale" placeholder="Enter locale" class="form-control" />
</div>
<p class="mt-2 mb-0">Date: <span id="date-example"></span></p>
</div>
</div>
<div class="card mt-1">
<div class="card-body">
<h6 class="card-title font-weight-bolder">HTTP requests timeout, ms</h6>
<div class="input-group input-group-sm was-validated">
<input type="number" id="ajax-timeout" class="form-control" min="0" step="any" />
<div class="input-group-append">
<button id="ajax-timeout-restore" class="btn btn-secondary">Restore default</button>
</div>
</div>
</div>
</div>
</div>
</div>
</form>
<button class="navbar-toggler ml-2" type="button" data-toggle="collapse" data-target=".navbar-collapse">
<span class="navbar-toggler-icon"></span>
</button>
</div>
</nav>
<div class="notification-area">
<noscript>
<div class="alert alert-error"><strong>Please enable JavaScript</strong></div>
</noscript>
</div>
<div id="preloader" class="container-fluid">
<div id="loading" class="position-absolute align-items-center my-3 text-primary blinking d-none">
<div class="spinner-border align-middle" role="status" aria-hidden="true"></div>
<strong class="ml-3">Loading...</strong>
</div>
<script>document.getElementById("loading").classList.remove("d-none");</script>
<div class="row position-absolute w-100 h-100 align-items-center text-center">
<img class="img-fluid mh-100 mx-auto" src="./img/rspamd_logo_navbar.png" alt="Rspamd" />
</div>
</div>
<div id="mainUI" class="d-none">
<div class="container-fluid">
<div class="tab-content">
<div class="tab-pane active" id="status">
<div class="row">
<div id="statWidgets" class="col-lg-12 stat-boxes font-weight-bold text-secondary" style="display: none;">
</div>
</div>
<div class="row">
<div class="col-lg-6">
<div class="card bg-light shadow my-3">
<div class="card-header text-secondary py-2">
<span class="icon mr-3"><i class="fas fa-server"></i></span>
<span class="h6 font-weight-bolder my-2">Servers</span>
</div>
<div class="card-body p-0 table-responsive">
<table class="table status-table table-sm table-hover table-bordered text-nowrap mb-0" id="clusterTable">
<thead class="text-secondary">
<tr>
<th></th>
<th>Server name</th>
<th>Host</th>
<th class="w-1">Status</th>
<th class="w-1">Scan time</th>
<th class="w-1">Uptime</th>
<th class="w-1">Version</th>
<th>Configuration ID</th>
</tr>
</thead>
<tbody>
</tbody>
</table>
</div>
</div>
<div class="card bg-light shadow my-3">
<div class="card-header text-secondary py-2">
<span class="icon mr-3"><i class="fas fa-dice"></i></span>
<span class="h6 font-weight-bolder my-2">Bayesian statistics</span>
</div>
<div class="card-body p-0 table-responsive">
<table class="table status-table table-sm table-bordered text-nowrap mb-0" id="bayesTable">
<thead class="text-secondary">
<tr>
<th>Server name</th>
<th>Symbol</th>
<th>Type</th>
<th>Learns</th>
<th>Users</th>
</tr>
</thead>
<tbody>
</tbody>
</table>
</div>
</div>
<div class="card bg-light shadow my-3">
<div class="card-header text-secondary py-2">
<span class="icon mr-3"><i class="fas fa-hashtag"></i></span>
<span class="h6 font-weight-bolder my-2">Fuzzy hashes</span>
</div>
<div class="card-body p-0 table-responsive">
<table class="table status-table table-sm table-bordered text-nowrap mb-0" id="fuzzyTable">
<thead class="text-secondary">
<tr>
<th>Server name</th>
<th>Storage</th>
<th>Hashes</th>
</tr>
</thead>
<tbody>
</tbody>
</table>
</div>
</div>
</div>
<div class="col-lg-6">
<div class="card bg-light shadow my-3">
<div class="card-header text-secondary py-2">
<span class="icon mr-3"><i class="fas fa-chart-pie"></i></span>
<span class="h6 font-weight-bolder my-2">Statistics</span>
</div>
<div class="card-body">
<div class="row">
<div class="bg-white mx-auto" id="chart"></div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="tab-pane" id="throughput">
<div class="card bg-light shadow my-3">
<div class="card-header text-secondary py-2">
<span class="icon mr-3"><i class="fas fa-chart-area"></i></span>
<span class="h6 font-weight-bolder my-2">Throughput</span>
</div>
<div class="card-body text-center">
<div class="d-inline-block bg-white">
<div class="row">
<div id="graph" class="mx-auto"></div>
</div>
<div id="summary-row" class="row">
<div class="col-fixed" id="rrd-pie"></div>
<div class="col-fluid">
<table id="rrd-table" class="table table-striped table-hover"></table>
<div id="rrd-table_toggle"></div>
<div id="rrd-total">Total messages: <span id="rrd-total-value"></span></div>
</div>
</div>
</div>
</div>
<div class="card-footer pt-0 text-center">
<form id="graph_controls" action="#">
Dataset:
<select id="selData" class="form-control">
<option value="day" selected>By day</option>
<option value="week">By week</option>
<option value="month">By month</option>
<option value="year">By year</option>
</select>
Y-scale:
<select id="selYScale" class="form-control">
<option value="lin" selected>Lin</option>
<option value="log">Log</option>
</select>
Convert to:
<select id="selConvert" class="form-control">
<option value="" selected>--</option>
<option value="percentage">percentage</option>
</select>
Chart type:
<select id="selType" class="form-control">
<option value="line" selected>Line</option>
<option value="area">Stacked area</option>
</select>
<a title="“Curves” section of “d3-shape” library documentation" href="https://github.com/d3/d3-shape#curves" target="_blank">Interpolation mode</a>:
<select id="selInterpolate" class="form-control">
<option value="curveLinear" selected>linear</option>
<option value="curveStep">step</option>
<option value="curveStepBefore">stepBefore</option>
<option value="curveStepAfter">stepAfter</option>
<option value="curveBasis">basis</option>
<option value="curveBasisOpen">basisOpen</option>
<option value="curveBundle">bundle</option>
<option value="curveCardinal">cardinal</option>
<option value="curveCardinalOpen">cardinalOpen</option>
<option value="curveMonotoneX">monotoneX</option>
</select>
</form>
</div>
</div>
</div>
<div class="tab-pane" id="configuration">
<div class="card bg-light shadow my-3">
<div class="card-header text-secondary py-2">
<span class="icon mr-3"><i class="fas fa-tasks"></i></span>
<span class="h6 font-weight-bolder my-2">Actions</span>
</div>
<div class="card-body pb-2">
<form id="actionsForm">
<fieldset id="actionsFormField" class="ro-disable"></fieldset>
</form>
</div>
<div class="card-footer ro-hide">
<div class="btn-group">
<button class="btn btn-primary" type="button" id="saveActionsBtn">Save actions</button>
<button class="btn btn-warning" type="button" id="saveActionsClusterBtn">Save cluster</button>
</div>
</div>
</div>
<div class="card bg-light shadow my-3">
<div class="card-header text-secondary py-2">
<span class="icon mr-3"><i class="fas fa-list"></i></span>
<span class="h6 font-weight-bolder my-2">Lists</span>
</div>
<div class="card-body p-0">
<table class="table table-sm table-hover mb-0" id="listMaps">
</table>
</div>
</div>
</div>
<div class="tab-pane" id="symbols">
<div class="card bg-light shadow my-3">
<div class="card-header text-secondary py-1 d-flex">
<span class="icon mr-3"><i class="fas fa-tasks"></i></span>
<span class="h6 font-weight-bolder my-2 ml-0">Symbols and rules</span>
<div class="align-self-center ml-auto mr-1">
<button class="btn btn-info btn-sm" id="updateSymbols">
<i class="fas fa-redo-alt"></i> Update
</button>
</div>
</div>
<div class="card-body p-0">
<table class="table table-hover" id="symbolsTable"></table>
</div>
</div>
</div>
<div class="tab-pane" id="scan">
<div class="card bg-light shadow my-3">
<div class="card-header text-secondary py-2">
<span class="icon mr-3"><i class="fas fa-envelope"></i></span>
<span class="h6 font-weight-bolder my-2">Scan suspected message</span>
</div>
<div class="card-body">
<div class="row">
<form class="col-lg-12" id="scanForm">
<div class="form-group mb-0">
<label for="scanMsgSource">Message source:</label>
<textarea class="form-control" id="scanMsgSource" rows="10" placeholder="Paste raw message source"></textarea>
</div>
<div class="collapse row mr-0 mt-3" id="scanOptions">
<div class="col-lg-6">
<div class="form-group row text-nowrap" title="Emulate IP address from which this message was received">
<label for="scan-opt-ip" class="col-form-label col-sm-2">IP:</label>
<input name="scan-opt-ip" id="scan-opt-ip" class="form-control col-sm-10" type="text"/>
</div>
<div class="form-group row text-nowrap" title="Emulate username of the authenticated SMTP client">
<label for="scan-opt-user" class="col-form-label col-sm-2">User:</label>
<input name="scan-opt-user" id="scan-opt-user" class="form-control col-sm-10" type="text"/>
</div>
<div class="form-group row text-nowrap" title="Emulate SMTP 'MAIL FROM' command data">
<label for="scan-opt-from" class="col-form-label col-sm-2">From:</label>
<input name="scan-opt-from" id="scan-opt-from" class="form-control col-sm-10" type="text"/>
</div>
</div>
<div class="col-lg-6">
<div class="form-group row text-nowrap" title="Emulate SMTP 'RCPT TO' command data">
<label for="scan-opt-rcpt" class="col-form-label col-sm-2">Rcpt:</label>
<input name="scan-opt-rcpt" id="scan-opt-rcpt" class="form-control col-sm-10" type="text"/>
</div>
<div class="form-group row text-nowrap" title="Imitate SMTP 'HELO' passing from the MTA">
<label for="scan-opt-helo" class="col-form-label col-sm-2">Helo:</label>
<input name="scan-opt-helo" id="scan-opt-helo" class="form-control col-sm-10" type="text"/>
</div>
<div class="form-group row text-nowrap" title="Imitate resolved hostname passing from the MTA">
<label for="scan-opt-hostname" class="col-form-label col-sm-2">Hostname:</label>
<input name="scan-opt-hostname" id="scan-opt-hostname" class="form-control col-sm-10" type="text"/>
</div>
<div class="form-check row text-nowrap pl-0" title="Pass all filters">
<label for="scan-opt-pass-all" class="form-check-label col-sm-2">Pass: all</label>
<input name="scan-opt-pass-all" id="scan-opt-pass-all" class="form-check-input-reverse" type="checkbox"/>
</div>
</div>
</div>
</form>
</div>
</div>
<div class="card-footer">
<button type="submit" class="btn btn-primary" data-upload="scan"><i class="fas fa-search"></i> Scan message</button>
<div class="form-inline float-right">
<button class="btn btn-secondary d-inline-block" id="scanOptionsToggle" data-toggle="collapse" data-target="#scanOptions"><i class="fas fa-bars"></i> Options</button>
<button class="btn btn-secondary ml-2" id="scanClean"><i class="fas fa-trash-alt"></i> Clean form</button>
</div>
</div>
</div>
<div class="card ro-hide" style="display: none;">
<div class="card-header text-secondary py-1 d-flex">
<span class="icon mr-3"><i class="fas fa-graduation-cap"></i></span>
<span class="h6 font-weight-bolder my-2">Learn Rspamd</span>
<div id="learnServers" class="form-inline card-header-form input-group-sm align-self-center ml-auto mr-1">
<label for="selLearnServers">Learn servers:</label>
<select id="selLearnServers" class="form-control ml-1">
<option value="random" selected>random</option>
<option value="all">all</option>
</select>
</div>
</div>
<div class="card-body">
<div class="row">
<div class="col-lg-6">
<div class="card bg-light shadow card-body card p-2">
<p>Learn Bayesian classifier:</p>
<form class="form-inline">
<div class="form-group">
<div class="btn-group">
<button class="btn btn-success" type="button" data-upload="ham" disabled><i class="fas fa-thumbs-up"></i> Upload HAM</button>
<button class="btn btn-danger" type="button" data-upload="spam" disabled><i class="fas fa-thumbs-down"></i> Upload SPAM</button>
</div>
</div>
</form>
</div>
</div>
<div class="col-lg-6">
<div class="card bg-light shadow card-body card p-2">
<p>Learn Fuzzy storage:</p>
<form class="form-inline">
<div class="form-group">
<label for="fuzzyFlagText">Flag:</label>
<input name="fuzzyFlagText" id="fuzzyFlagText" class="form-control ml-1" type="number" value="1"/>
</div>
<div class="form-group ml-2">
<label for="fuzzyWeightText">Weight:</label>
<input name="fuzzyWeightText" id="fuzzyWeightText" class="form-control ml-1" type="number" value="1"/>
</div>
<button class="btn btn-warning ml-2" data-upload="fuzzy" disabled><i class="fas fa-upload"></i> Upload FUZZY</button>
</form>
</div>
</div>
</div>
</div>
</div>
<div class="card bg-light shadow my-3">
<div class="card-header text-secondary py-1 d-flex">
<span class="icon mr-3"><i class="fas fa-eye"></i></span>
<span class="h6 font-weight-bolder my-2 ml-0">Scan results history</span>
<div id="scanResult" class="form-inline card-header-form input-group-sm align-self-center ml-auto mr-1">
<label for="selSymOrder_scan">Symbols order:</label>
<select id="selSymOrder_scan" class="form-control ml-1">
<option value="magnitude" selected>Score magnitude</option>
<option value="score">Score value</option>
<option value="name">Name</option>
</select>
<label for="scan_page_size" class="ml-2">Rows per page:</label>
<input id="scan_page_size" class="form-control ml-1" value="25" min="1" type="number">
<button class="btn btn-secondary btn-sm ml-2" id="cleanScanHistory">
<i class="fas fa-trash-alt"></i> Clean history
</button>
</div>
</div>
<div class="card-body p-0">
<div id="scanLog">
<table class="table mb-0" id="historyTable_scan"></table>
</div>
</div>
</div>
</div>
<div class="tab-pane" id="selectors">
<div class="card bg-light shadow my-3">
<div class="card-header text-secondary py-2">
<span class="icon mr-3"><i class="fas fa-envelope"></i></span>
<span class="h6 font-weight-bolder my-2">Test Rspamd selectors</span>
</div>
<div class="card-body py-0">
<div class="row h-100" id="row-main">
<div class="col-lg-3 sidebar h-100" id="sidebar-left">
<div class="p-0 table-responsive mh-100 bg-white">
<table class="table table-sm small table-striped table-hover table-bordered mb-0" id="selectorsTable-extractors">
<thead><tr><th>Name</th><th>Description</th></tr></thead>
<tbody/>
</table>
</div>
</div>
<div class="col-lg-6 col-12 h-100" id="content">
<div class="row navbar-light h-100">
<ul class="nav navbar-nav nav-tabs sidebar-nav border-bottom-0">
<li class="active text-nowrap nav-item" id="sidebar-tab-left">
<a class="nav-link border-bottom-0 px-2 py-0" href=""><div id="sidebar-tab-text-left">↕ List of extractors</div></a>
</li>
</ul>
<div class="col-lg col-12 mh-100 overflow-auto">
<div class="row h-100">
<form class="col-12 d-flex flex-column">
<div class="row pt-3">
<div class="col">
<div class="form-group">
<label for="selectorsMsgArea">Message source:</label>
<textarea class="form-control" id="selectorsMsgArea" rows="9" placeholder="Paste raw message source"></textarea>
</div>
<button class="btn btn-secondary float-right" id="selectorsMsgClean"><i class="fas fa-trash-alt"></i> Clean form</button>
</div>
</div>
<div class="row pt-3">
<div class="col">
<div class="form-group">
<label for="selectorsSelArea">Selector(s):</label>
<textarea class="form-control" id="selectorsSelArea" rows="1" placeholder="extractor.transform(arg);extractor.transform(arg);..."></textarea>
</div>
<button type="submit" class="btn btn-primary" id="selectorsChkMsgBtn"><i class="fas fa-search"></i> Check message</button>
<button class="btn btn-secondary float-right" id="selectorsClean"><i class="fas fa-trash-alt"></i> Clean form</button>
</div>
</div>
<div class="row pt-3 flex-grow-1">
<div class="col d-flex flex-column">
<div class="form-group h-100 d-flex flex-column">
<label for="selectorsResArea">Result:</label>
<textarea class="form-control flex-grow-1" id="selectorsResArea" readonly></textarea>
</div>
</div>
</div>
</form>
</div>
</div>
<ul class="nav navbar-nav nav-tabs sidebar-nav border-bottom-0">
<li class="active text-nowrap nav-item" id="sidebar-tab-right">
<a class="nav-link border-bottom-0 px-2 py-0" href="">↕ List of transforms</a>
</li>
</ul>
</div>
</div>
<div class="col-lg-3 sidebar h-100" id="sidebar-right">
<div class="p-0 table-responsive mh-100 bg-white">
<table class="table table-sm small table-striped table-hover table-bordered mb-0" id="selectorsTable-transforms">
<thead><tr><th>Name</th><th>Description</th></tr></thead>
<tbody/>
</table>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="tab-pane" id="history">
<div class="card bg-light shadow my-3">
<div class="card-header text-secondary py-1 d-flex">
<span class="icon mr-3"><i class="fas fa-eye"></i></span>
<span class="h6 font-weight-bolder my-2 ml-0">History</span>
<div class="form-inline card-header-form input-group-sm align-self-center ml-auto mr-1">
<label for="selSymOrder_history">Symbols order:</label>
<select id="selSymOrder_history" class="form-control ml-1">
<option value="magnitude" selected>Score magnitude</option>
<option value="score">Score value</option>
<option value="name">Name</option>
</select>
<label for="history_page_size" class="ml-2">Rows per page:</label>
<input id="history_page_size" class="form-control ml-1" value="25" min="1" type="number">
<button class="btn btn-danger btn-sm ml-2 ro-hide" id="resetHistory">
<i class="fas fa-times-circle"></i> Reset
</button>
<button class="btn btn-info btn-sm ml-2" id="updateHistory">
<i class="fas fa-redo-alt"></i> Update
</button>
</div>
</div>
<div class="card-body p-0">
<div id="historyLog">
<table class="table" id="historyTable_history"></table>
</div>
</div>
</div>
<div class="card bg-light shadow my-3 ro-hide" id="errors-history">
<div class="card-header text-secondary py-1 d-flex">
<span class="icon mr-3"><i class="fas fa-exclamation-triangle"></i></span>
<span class="h6 font-weight-bolder my-2 ml-0">Errors</span>
<div class="align-self-center ml-auto mr-1">
<button class="btn btn-info btn-sm" id="updateErrors">
<i class="fas fa-redo-alt"></i> Update
</button>
</div>
</div>
<div class="card-body p-0">
<table class="table table-hover mb-0" id="errorsLog"></table>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- Common modal -->
<div id="modalDialog" class="modal fade text-center" data-backdrop="static" tabindex="-1" role="dialog">
<div class="modal-dialog modal-xl d-inline-block mw-100 my-auto text-left">
<div class="modal-content shadow">
<div class="modal-header text-secondary py-2">
<i class="fas my-auto"></i><h6 class="modal-title font-weight-bolder mx-3" id="modalTitle"></h6>
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
</div>
<div class="modal-body" id="modalBody"></div>
<div class="modal-footer">
<div class="btn-group" id="modalSaveGroup">
<button class="btn btn-primary" id="modalSave">Save changes</button>
<button class="btn btn-warning" id="modalSaveAll">Save on cluster</button>
</div>
<button class="btn btn-secondary" data-dismiss="modal" aria-hidden="true" id="modalClose">Close</button>
</div>
</div>
</div>
</div>
<!-- login modal -->
<div id="connectDialog" class="modal fade" data-backdrop="static" data-keyboard="false" role="dialog">
<div class="modal-dialog modal-sm modal-dialog-centered">
<div class="modal-content shadow">
<div class="modal-header text-secondary py-2">
<i class="fas fa-key my-auto"></i><h6 class="modal-title font-weight-bolder">Login to Rspamd</h6>
</div>
<div class="modal-body" id="connectBody">
<form id="connectForm">
<div class="form-group">
<div class="input-group">
<!-- In recent browser versions username is required to save credentials in a password manager.
Browser detects passwords by form.elements[n].type == "password" and then detects
the username field by searching backwards through form elements for the text field
immediately before the password fields. -->
<input value="Rspamd controller password" style="display: none;"/>
<input class="form-control"
type="password"
id="connectPassword"
placeholder="Password"
data-cip-id="connectPassword">
<div class="input-group-append">
<button type="submit" id="connectButton" class="btn btn-primary">Connect</button>
</div>
</div>
</div>
</form>
</div>
</div>
</div>
</div>
<script data-main="./js/main.js" src="./js/lib/require.min.js"></script>
</body>
</html>
|