-
Notifications
You must be signed in to change notification settings - Fork 1.2k
/
backend.schema.json
1115 lines (1115 loc) · 29.6 KB
/
backend.schema.json
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
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://github.com/DataDog/datadog-agent/pkg/security/probe/event",
"$defs": {
"BPFEvent": {
"properties": {
"cmd": {
"type": "string",
"description": "BPF command"
},
"map": {
"$ref": "#/$defs/BPFMap",
"description": "BPF map"
},
"program": {
"$ref": "#/$defs/BPFProgram",
"description": "BPF program"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"cmd"
],
"description": "BPFEventSerializer serializes a BPF event to JSON"
},
"BPFMap": {
"properties": {
"name": {
"type": "string",
"description": "Name of the BPF map"
},
"map_type": {
"type": "string",
"description": "Type of the BPF map"
}
},
"additionalProperties": false,
"type": "object",
"description": "BPFMapSerializer serializes a BPF map to JSON"
},
"BPFProgram": {
"properties": {
"name": {
"type": "string",
"description": "Name of the BPF program"
},
"tag": {
"type": "string",
"description": "Hash (sha1) of the BPF program"
},
"program_type": {
"type": "string",
"description": "Type of the BPF program"
},
"attach_type": {
"type": "string",
"description": "Attach type of the BPF program"
},
"helpers": {
"items": {
"type": "string"
},
"type": "array",
"description": "List of helpers used by the BPF program"
}
},
"additionalProperties": false,
"type": "object",
"description": "BPFProgramSerializer serializes a BPF map to JSON"
},
"BindEvent": {
"properties": {
"addr": {
"$ref": "#/$defs/IPPortFamily",
"description": "Bound address (if any)"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"addr"
],
"description": "BindEventSerializer serializes a bind event to JSON"
},
"ContainerContext": {
"properties": {
"id": {
"type": "string",
"description": "Container ID"
}
},
"additionalProperties": false,
"type": "object",
"description": "ContainerContextSerializer serializes a container context to JSON"
},
"DDContext": {
"properties": {
"span_id": {
"type": "integer",
"description": "Span ID used for APM correlation"
},
"trace_id": {
"type": "integer",
"description": "Trace ID used for APM correlation"
}
},
"additionalProperties": false,
"type": "object",
"description": "DDContextSerializer serializes a span context to JSON"
},
"DNSEvent": {
"properties": {
"id": {
"type": "integer",
"description": "id is the unique identifier of the DNS request"
},
"question": {
"$ref": "#/$defs/DNSQuestion",
"description": "question is a DNS question for the DNS request"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"id"
],
"description": "DNSEventSerializer serializes a DNS event to JSON"
},
"DNSQuestion": {
"properties": {
"class": {
"type": "string",
"description": "class is the class looked up by the DNS question"
},
"type": {
"type": "string",
"description": "type is a two octet code which specifies the DNS question type"
},
"name": {
"type": "string",
"description": "name is the queried domain name"
},
"size": {
"type": "integer",
"description": "size is the total DNS request size in bytes"
},
"count": {
"type": "integer",
"description": "count is the total count of questions in the DNS request"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"class",
"type",
"name",
"size",
"count"
],
"description": "DNSQuestionSerializer serializes a DNS question to JSON"
},
"EventContext": {
"properties": {
"name": {
"type": "string",
"description": "Event name"
},
"category": {
"type": "string",
"description": "Event category"
},
"outcome": {
"type": "string",
"description": "Event outcome"
},
"async": {
"type": "boolean",
"description": "True if the event was asynchronous"
}
},
"additionalProperties": false,
"type": "object",
"description": "EventContextSerializer serializes an event context to JSON"
},
"ExitEvent": {
"properties": {
"cause": {
"type": "string",
"description": "Cause of the process termination (one of EXITED, SIGNALED, COREDUMPED)"
},
"code": {
"type": "integer",
"description": "Exit code of the process or number of the signal that caused the process to terminate"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"cause",
"code"
],
"description": "ExitEventSerializer serializes an exit event to JSON"
},
"File": {
"properties": {
"path": {
"type": "string",
"description": "File path"
},
"name": {
"type": "string",
"description": "File basename"
},
"path_resolution_error": {
"type": "string",
"description": "Error message from path resolution"
},
"inode": {
"type": "integer",
"description": "File inode number"
},
"mode": {
"type": "integer",
"description": "File mode"
},
"in_upper_layer": {
"type": "boolean",
"description": "Indicator of file OverlayFS layer"
},
"mount_id": {
"type": "integer",
"description": "File mount ID"
},
"filesystem": {
"type": "string",
"description": "File filesystem name"
},
"uid": {
"type": "integer",
"description": "File User ID"
},
"gid": {
"type": "integer",
"description": "File Group ID"
},
"user": {
"type": "string",
"description": "File user"
},
"group": {
"type": "string",
"description": "File group"
},
"attribute_name": {
"type": "string",
"description": "File extended attribute name"
},
"attribute_namespace": {
"type": "string",
"description": "File extended attribute namespace"
},
"flags": {
"items": {
"type": "string"
},
"type": "array",
"description": "File flags"
},
"access_time": {
"type": "string",
"format": "date-time",
"description": "File access time"
},
"modification_time": {
"type": "string",
"format": "date-time",
"description": "File modified time"
},
"change_time": {
"type": "string",
"format": "date-time",
"description": "File change time"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"uid",
"gid"
],
"description": "FileSerializer serializes a file to JSON"
},
"FileEvent": {
"properties": {
"path": {
"type": "string",
"description": "File path"
},
"name": {
"type": "string",
"description": "File basename"
},
"path_resolution_error": {
"type": "string",
"description": "Error message from path resolution"
},
"inode": {
"type": "integer",
"description": "File inode number"
},
"mode": {
"type": "integer",
"description": "File mode"
},
"in_upper_layer": {
"type": "boolean",
"description": "Indicator of file OverlayFS layer"
},
"mount_id": {
"type": "integer",
"description": "File mount ID"
},
"filesystem": {
"type": "string",
"description": "File filesystem name"
},
"uid": {
"type": "integer",
"description": "File User ID"
},
"gid": {
"type": "integer",
"description": "File Group ID"
},
"user": {
"type": "string",
"description": "File user"
},
"group": {
"type": "string",
"description": "File group"
},
"attribute_name": {
"type": "string",
"description": "File extended attribute name"
},
"attribute_namespace": {
"type": "string",
"description": "File extended attribute namespace"
},
"flags": {
"items": {
"type": "string"
},
"type": "array",
"description": "File flags"
},
"access_time": {
"type": "string",
"format": "date-time",
"description": "File access time"
},
"modification_time": {
"type": "string",
"format": "date-time",
"description": "File modified time"
},
"change_time": {
"type": "string",
"format": "date-time",
"description": "File change time"
},
"destination": {
"$ref": "#/$defs/File",
"description": "Target file information"
},
"new_mount_id": {
"type": "integer",
"description": "New Mount ID"
},
"group_id": {
"type": "integer",
"description": "Group ID"
},
"device": {
"type": "integer",
"description": "Device associated with the file"
},
"fstype": {
"type": "string",
"description": "Filesystem type"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"uid",
"gid"
],
"description": "FileEventSerializer serializes a file event to JSON"
},
"IPPort": {
"properties": {
"ip": {
"type": "string",
"description": "IP address"
},
"port": {
"type": "integer",
"description": "Port number"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"ip",
"port"
],
"description": "IPPortSerializer is used to serialize an IP and Port context to JSON"
},
"IPPortFamily": {
"properties": {
"family": {
"type": "string",
"description": "Address family"
},
"ip": {
"type": "string",
"description": "IP address"
},
"port": {
"type": "integer",
"description": "Port number"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"family",
"ip",
"port"
],
"description": "IPPortFamilySerializer is used to serialize an IP, port, and address family context to JSON"
},
"MMapEvent": {
"properties": {
"address": {
"type": "string",
"description": "memory segment address"
},
"offset": {
"type": "integer",
"description": "file offset"
},
"length": {
"type": "integer",
"description": "memory segment length"
},
"protection": {
"type": "string",
"description": "memory segment protection"
},
"flags": {
"type": "string",
"description": "memory segment flags"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"address",
"offset",
"length",
"protection",
"flags"
],
"description": "MMapEventSerializer serializes a mmap event to JSON"
},
"MProtectEvent": {
"properties": {
"vm_start": {
"type": "string",
"description": "memory segment start address"
},
"vm_end": {
"type": "string",
"description": "memory segment end address"
},
"vm_protection": {
"type": "string",
"description": "initial memory segment protection"
},
"req_protection": {
"type": "string",
"description": "new memory segment protection"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"vm_start",
"vm_end",
"vm_protection",
"req_protection"
],
"description": "MProtectEventSerializer serializes a mmap event to JSON"
},
"ModuleEvent": {
"properties": {
"name": {
"type": "string",
"description": "module name"
},
"loaded_from_memory": {
"type": "boolean",
"description": "indicates if a module was loaded from memory, as opposed to a file"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"name"
],
"description": "ModuleEventSerializer serializes a module event to JSON"
},
"NetworkContext": {
"properties": {
"device": {
"$ref": "#/$defs/NetworkDevice",
"description": "device is the network device on which the event was captured"
},
"l3_protocol": {
"type": "string",
"description": "l3_protocol is the layer 3 protocol name"
},
"l4_protocol": {
"type": "string",
"description": "l4_protocol is the layer 4 protocol name"
},
"source": {
"$ref": "#/$defs/IPPort",
"description": "source is the emitter of the network event"
},
"destination": {
"$ref": "#/$defs/IPPort",
"description": "destination is the receiver of the network event"
},
"size": {
"type": "integer",
"description": "size is the size in bytes of the network event"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"l3_protocol",
"l4_protocol",
"source",
"destination",
"size"
],
"description": "NetworkContextSerializer serializes the network context to JSON"
},
"NetworkDevice": {
"properties": {
"netns": {
"type": "integer",
"description": "netns is the interface ifindex"
},
"ifindex": {
"type": "integer",
"description": "ifindex is the network interface ifindex"
},
"ifname": {
"type": "string",
"description": "ifname is the network interface name"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"netns",
"ifindex",
"ifname"
],
"description": "NetworkDeviceSerializer serializes the network device context to JSON"
},
"PTraceEvent": {
"properties": {
"request": {
"type": "string",
"description": "ptrace request"
},
"address": {
"type": "string",
"description": "address at which the ptrace request was executed"
},
"tracee": {
"$ref": "#/$defs/ProcessContext",
"description": "process context of the tracee"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"request",
"address"
],
"description": "PTraceEventSerializer serializes a mmap event to JSON"
},
"Process": {
"properties": {
"pid": {
"type": "integer",
"description": "Process ID"
},
"ppid": {
"type": "integer",
"description": "Parent Process ID"
},
"tid": {
"type": "integer",
"description": "Thread ID"
},
"uid": {
"type": "integer",
"description": "User ID"
},
"gid": {
"type": "integer",
"description": "Group ID"
},
"user": {
"type": "string",
"description": "User name"
},
"group": {
"type": "string",
"description": "Group name"
},
"path_resolution_error": {
"type": "string",
"description": "Description of an error in the path resolution"
},
"comm": {
"type": "string",
"description": "Command name"
},
"tty": {
"type": "string",
"description": "TTY associated with the process"
},
"fork_time": {
"type": "string",
"format": "date-time",
"description": "Fork time of the process"
},
"exec_time": {
"type": "string",
"format": "date-time",
"description": "Exec time of the process"
},
"exit_time": {
"type": "string",
"format": "date-time",
"description": "Exit time of the process"
},
"credentials": {
"$ref": "#/$defs/ProcessCredentials",
"description": "Credentials associated with the process"
},
"executable": {
"$ref": "#/$defs/File",
"description": "File information of the executable"
},
"interpreter": {
"$ref": "#/$defs/File",
"description": "File information of the interpreter"
},
"container": {
"$ref": "#/$defs/ContainerContext",
"description": "Container context"
},
"argv0": {
"type": "string",
"description": "First command line argument"
},
"args": {
"items": {
"type": "string"
},
"type": "array",
"description": "Command line arguments"
},
"args_truncated": {
"type": "boolean",
"description": "Indicator of arguments truncation"
},
"envs": {
"items": {
"type": "string"
},
"type": "array",
"description": "Environment variables of the process"
},
"envs_truncated": {
"type": "boolean",
"description": "Indicator of environments variable truncation"
},
"is_thread": {
"type": "boolean",
"description": "Indicates whether the process is considered a thread (that is, a child process that hasn't executed another program)"
},
"is_kworker": {
"type": "boolean",
"description": "Indicates whether the process is a kworker"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"uid",
"gid"
],
"description": "ProcessSerializer serializes a process to JSON"
},
"ProcessContext": {
"properties": {
"pid": {
"type": "integer",
"description": "Process ID"
},
"ppid": {
"type": "integer",
"description": "Parent Process ID"
},
"tid": {
"type": "integer",
"description": "Thread ID"
},
"uid": {
"type": "integer",
"description": "User ID"
},
"gid": {
"type": "integer",
"description": "Group ID"
},
"user": {
"type": "string",
"description": "User name"
},
"group": {
"type": "string",
"description": "Group name"
},
"path_resolution_error": {
"type": "string",
"description": "Description of an error in the path resolution"
},
"comm": {
"type": "string",
"description": "Command name"
},
"tty": {
"type": "string",
"description": "TTY associated with the process"
},
"fork_time": {
"type": "string",
"format": "date-time",
"description": "Fork time of the process"
},
"exec_time": {
"type": "string",
"format": "date-time",
"description": "Exec time of the process"
},
"exit_time": {
"type": "string",
"format": "date-time",
"description": "Exit time of the process"
},
"credentials": {
"$ref": "#/$defs/ProcessCredentials",
"description": "Credentials associated with the process"
},
"executable": {
"$ref": "#/$defs/File",
"description": "File information of the executable"
},
"interpreter": {
"$ref": "#/$defs/File",
"description": "File information of the interpreter"
},
"container": {
"$ref": "#/$defs/ContainerContext",
"description": "Container context"
},
"argv0": {
"type": "string",
"description": "First command line argument"
},
"args": {
"items": {
"type": "string"
},
"type": "array",
"description": "Command line arguments"
},
"args_truncated": {
"type": "boolean",
"description": "Indicator of arguments truncation"
},
"envs": {
"items": {
"type": "string"
},
"type": "array",
"description": "Environment variables of the process"
},
"envs_truncated": {
"type": "boolean",
"description": "Indicator of environments variable truncation"
},
"is_thread": {
"type": "boolean",
"description": "Indicates whether the process is considered a thread (that is, a child process that hasn't executed another program)"
},
"is_kworker": {
"type": "boolean",
"description": "Indicates whether the process is a kworker"
},
"parent": {
"$ref": "#/$defs/Process",
"description": "Parent process"
},
"ancestors": {
"items": {
"$ref": "#/$defs/Process"
},
"type": "array",
"description": "Ancestor processes"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"uid",
"gid"
],
"description": "ProcessContextSerializer serializes a process context to JSON"
},
"ProcessCredentials": {
"properties": {
"uid": {
"type": "integer",
"description": "User ID"
},
"user": {
"type": "string",
"description": "User name"
},
"gid": {
"type": "integer",
"description": "Group ID"
},
"group": {
"type": "string",
"description": "Group name"
},
"euid": {
"type": "integer",
"description": "Effective User ID"
},
"euser": {
"type": "string",
"description": "Effective User name"
},
"egid": {
"type": "integer",
"description": "Effective Group ID"
},
"egroup": {
"type": "string",
"description": "Effective Group name"
},
"fsuid": {
"type": "integer",
"description": "Filesystem User ID"
},
"fsuser": {
"type": "string",
"description": "Filesystem User name"
},
"fsgid": {
"type": "integer",
"description": "Filesystem Group ID"
},
"fsgroup": {
"type": "string",
"description": "Filesystem Group name"
},
"cap_effective": {
"items": {
"type": "string"
},
"type": "array",
"description": "Effective Capability set"
},
"cap_permitted": {
"items": {
"type": "string"
},
"type": "array",
"description": "Permitted Capability set"
},
"destination": {
"description": "Credentials after the operation"
}
},
"additionalProperties": false,
"type": "object",
"required": [
"uid",
"gid",
"euid",
"egid",
"fsuid",
"fsgid",
"cap_effective",
"cap_permitted"
],
"description": "ProcessCredentialsSerializer serializes the process credentials to JSON"
},
"SELinuxBoolChange": {
"properties": {
"name": {
"type": "string",
"description": "SELinux boolean name"
},
"state": {
"type": "string",
"description": "SELinux boolean state ('on' or 'off')"
}
},
"additionalProperties": false,
"type": "object",
"description": "SELinuxBoolChangeSerializer serializes a SELinux boolean change to JSON"
},
"SELinuxBoolCommit": {
"properties": {
"state": {
"type": "boolean",
"description": "SELinux boolean commit operation"
}
},
"additionalProperties": false,
"type": "object",
"description": "SELinuxBoolCommitSerializer serializes a SELinux boolean commit to JSON"
},
"SELinuxEnforceStatus": {
"properties": {
"status": {
"type": "string",
"description": "SELinux enforcement status (one of 'enforcing', 'permissive' or 'disabled')"
}
},
"additionalProperties": false,
"type": "object",
"description": "SELinuxEnforceStatusSerializer serializes a SELinux enforcement status change to JSON"
},
"SELinuxEvent": {
"properties": {
"bool": {
"$ref": "#/$defs/SELinuxBoolChange",
"description": "SELinux boolean operation"
},
"enforce": {
"$ref": "#/$defs/SELinuxEnforceStatus",
"description": "SELinux enforcement change"
},
"bool_commit": {
"$ref": "#/$defs/SELinuxBoolCommit",
"description": "SELinux boolean commit"
}
},
"additionalProperties": false,
"type": "object",
"description": "SELinuxEventSerializer serializes a SELinux context to JSON"
},
"SignalEvent": {
"properties": {
"type": {
"type": "string",
"description": "signal type"
},
"pid": {