Browse code

Merge pull request #41500 from thaJeztah/seccomp_separate

seccomp: remove dependency on oci package

Sebastiaan van Stijn authored on 2020/09/30 05:10:57
Showing 6 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,1593 @@
0
+{
1
+  "defaultAction": "SCMP_ACT_ERRNO",
2
+  "architectures": [
3
+    "SCMP_ARCH_X86_64",
4
+    "SCMP_ARCH_X86",
5
+    "SCMP_ARCH_X32"
6
+  ],
7
+  "syscalls": [
8
+    {
9
+      "name": "accept",
10
+      "action": "SCMP_ACT_ALLOW",
11
+      "args": []
12
+    },
13
+    {
14
+      "name": "accept4",
15
+      "action": "SCMP_ACT_ALLOW",
16
+      "args": []
17
+    },
18
+    {
19
+      "name": "access",
20
+      "action": "SCMP_ACT_ALLOW",
21
+      "args": []
22
+    },
23
+    {
24
+      "name": "alarm",
25
+      "action": "SCMP_ACT_ALLOW",
26
+      "args": []
27
+    },
28
+    {
29
+      "name": "bind",
30
+      "action": "SCMP_ACT_ALLOW",
31
+      "args": []
32
+    },
33
+    {
34
+      "name": "brk",
35
+      "action": "SCMP_ACT_ALLOW",
36
+      "args": []
37
+    },
38
+    {
39
+      "name": "capget",
40
+      "action": "SCMP_ACT_ALLOW",
41
+      "args": []
42
+    },
43
+    {
44
+      "name": "capset",
45
+      "action": "SCMP_ACT_ALLOW",
46
+      "args": []
47
+    },
48
+    {
49
+      "name": "chdir",
50
+      "action": "SCMP_ACT_ALLOW",
51
+      "args": []
52
+    },
53
+    {
54
+      "name": "chmod",
55
+      "action": "SCMP_ACT_ALLOW",
56
+      "args": []
57
+    },
58
+    {
59
+      "name": "chown",
60
+      "action": "SCMP_ACT_ALLOW",
61
+      "args": []
62
+    },
63
+    {
64
+      "name": "chown32",
65
+      "action": "SCMP_ACT_ALLOW",
66
+      "args": []
67
+    },
68
+    {
69
+      "name": "clock_getres",
70
+      "action": "SCMP_ACT_ALLOW",
71
+      "args": []
72
+    },
73
+    {
74
+      "name": "clock_gettime",
75
+      "action": "SCMP_ACT_ALLOW",
76
+      "args": []
77
+    },
78
+    {
79
+      "name": "clock_nanosleep",
80
+      "action": "SCMP_ACT_ALLOW",
81
+      "args": []
82
+    },
83
+    {
84
+      "name": "close",
85
+      "action": "SCMP_ACT_ALLOW",
86
+      "args": []
87
+    },
88
+    {
89
+      "name": "connect",
90
+      "action": "SCMP_ACT_ALLOW",
91
+      "args": []
92
+    },
93
+    {
94
+      "name": "copy_file_range",
95
+      "action": "SCMP_ACT_ALLOW",
96
+      "args": []
97
+    },
98
+    {
99
+      "name": "creat",
100
+      "action": "SCMP_ACT_ALLOW",
101
+      "args": []
102
+    },
103
+    {
104
+      "name": "dup",
105
+      "action": "SCMP_ACT_ALLOW",
106
+      "args": []
107
+    },
108
+    {
109
+      "name": "dup2",
110
+      "action": "SCMP_ACT_ALLOW",
111
+      "args": []
112
+    },
113
+    {
114
+      "name": "dup3",
115
+      "action": "SCMP_ACT_ALLOW",
116
+      "args": []
117
+    },
118
+    {
119
+      "name": "epoll_create",
120
+      "action": "SCMP_ACT_ALLOW",
121
+      "args": []
122
+    },
123
+    {
124
+      "name": "epoll_create1",
125
+      "action": "SCMP_ACT_ALLOW",
126
+      "args": []
127
+    },
128
+    {
129
+      "name": "epoll_ctl",
130
+      "action": "SCMP_ACT_ALLOW",
131
+      "args": []
132
+    },
133
+    {
134
+      "name": "epoll_ctl_old",
135
+      "action": "SCMP_ACT_ALLOW",
136
+      "args": []
137
+    },
138
+    {
139
+      "name": "epoll_pwait",
140
+      "action": "SCMP_ACT_ALLOW",
141
+      "args": []
142
+    },
143
+    {
144
+      "name": "epoll_wait",
145
+      "action": "SCMP_ACT_ALLOW",
146
+      "args": []
147
+    },
148
+    {
149
+      "name": "epoll_wait_old",
150
+      "action": "SCMP_ACT_ALLOW",
151
+      "args": []
152
+    },
153
+    {
154
+      "name": "eventfd",
155
+      "action": "SCMP_ACT_ALLOW",
156
+      "args": []
157
+    },
158
+    {
159
+      "name": "eventfd2",
160
+      "action": "SCMP_ACT_ALLOW",
161
+      "args": []
162
+    },
163
+    {
164
+      "name": "execve",
165
+      "action": "SCMP_ACT_ALLOW",
166
+      "args": []
167
+    },
168
+    {
169
+      "name": "execveat",
170
+      "action": "SCMP_ACT_ALLOW",
171
+      "args": []
172
+    },
173
+    {
174
+      "name": "exit",
175
+      "action": "SCMP_ACT_ALLOW",
176
+      "args": []
177
+    },
178
+    {
179
+      "name": "exit_group",
180
+      "action": "SCMP_ACT_ALLOW",
181
+      "args": []
182
+    },
183
+    {
184
+      "name": "faccessat",
185
+      "action": "SCMP_ACT_ALLOW",
186
+      "args": []
187
+    },
188
+    {
189
+      "name": "fadvise64",
190
+      "action": "SCMP_ACT_ALLOW",
191
+      "args": []
192
+    },
193
+    {
194
+      "name": "fadvise64_64",
195
+      "action": "SCMP_ACT_ALLOW",
196
+      "args": []
197
+    },
198
+    {
199
+      "name": "fallocate",
200
+      "action": "SCMP_ACT_ALLOW",
201
+      "args": []
202
+    },
203
+    {
204
+      "name": "fanotify_mark",
205
+      "action": "SCMP_ACT_ALLOW",
206
+      "args": []
207
+    },
208
+    {
209
+      "name": "fchdir",
210
+      "action": "SCMP_ACT_ALLOW",
211
+      "args": []
212
+    },
213
+    {
214
+      "name": "fchmod",
215
+      "action": "SCMP_ACT_ALLOW",
216
+      "args": []
217
+    },
218
+    {
219
+      "name": "fchmodat",
220
+      "action": "SCMP_ACT_ALLOW",
221
+      "args": []
222
+    },
223
+    {
224
+      "name": "fchown",
225
+      "action": "SCMP_ACT_ALLOW",
226
+      "args": []
227
+    },
228
+    {
229
+      "name": "fchown32",
230
+      "action": "SCMP_ACT_ALLOW",
231
+      "args": []
232
+    },
233
+    {
234
+      "name": "fchownat",
235
+      "action": "SCMP_ACT_ALLOW",
236
+      "args": []
237
+    },
238
+    {
239
+      "name": "fcntl",
240
+      "action": "SCMP_ACT_ALLOW",
241
+      "args": []
242
+    },
243
+    {
244
+      "name": "fcntl64",
245
+      "action": "SCMP_ACT_ALLOW",
246
+      "args": []
247
+    },
248
+    {
249
+      "name": "fdatasync",
250
+      "action": "SCMP_ACT_ALLOW",
251
+      "args": []
252
+    },
253
+    {
254
+      "name": "fgetxattr",
255
+      "action": "SCMP_ACT_ALLOW",
256
+      "args": []
257
+    },
258
+    {
259
+      "name": "flistxattr",
260
+      "action": "SCMP_ACT_ALLOW",
261
+      "args": []
262
+    },
263
+    {
264
+      "name": "flock",
265
+      "action": "SCMP_ACT_ALLOW",
266
+      "args": []
267
+    },
268
+    {
269
+      "name": "fork",
270
+      "action": "SCMP_ACT_ALLOW",
271
+      "args": []
272
+    },
273
+    {
274
+      "name": "fremovexattr",
275
+      "action": "SCMP_ACT_ALLOW",
276
+      "args": []
277
+    },
278
+    {
279
+      "name": "fsetxattr",
280
+      "action": "SCMP_ACT_ALLOW",
281
+      "args": []
282
+    },
283
+    {
284
+      "name": "fstat",
285
+      "action": "SCMP_ACT_ALLOW",
286
+      "args": []
287
+    },
288
+    {
289
+      "name": "fstat64",
290
+      "action": "SCMP_ACT_ALLOW",
291
+      "args": []
292
+    },
293
+    {
294
+      "name": "fstatat64",
295
+      "action": "SCMP_ACT_ALLOW",
296
+      "args": []
297
+    },
298
+    {
299
+      "name": "fstatfs",
300
+      "action": "SCMP_ACT_ALLOW",
301
+      "args": []
302
+    },
303
+    {
304
+      "name": "fstatfs64",
305
+      "action": "SCMP_ACT_ALLOW",
306
+      "args": []
307
+    },
308
+    {
309
+      "name": "fsync",
310
+      "action": "SCMP_ACT_ALLOW",
311
+      "args": []
312
+    },
313
+    {
314
+      "name": "ftruncate",
315
+      "action": "SCMP_ACT_ALLOW",
316
+      "args": []
317
+    },
318
+    {
319
+      "name": "ftruncate64",
320
+      "action": "SCMP_ACT_ALLOW",
321
+      "args": []
322
+    },
323
+    {
324
+      "name": "futex",
325
+      "action": "SCMP_ACT_ALLOW",
326
+      "args": []
327
+    },
328
+    {
329
+      "name": "futimesat",
330
+      "action": "SCMP_ACT_ALLOW",
331
+      "args": []
332
+    },
333
+    {
334
+      "name": "getcpu",
335
+      "action": "SCMP_ACT_ALLOW",
336
+      "args": []
337
+    },
338
+    {
339
+      "name": "getcwd",
340
+      "action": "SCMP_ACT_ALLOW",
341
+      "args": []
342
+    },
343
+    {
344
+      "name": "getdents",
345
+      "action": "SCMP_ACT_ALLOW",
346
+      "args": []
347
+    },
348
+    {
349
+      "name": "getdents64",
350
+      "action": "SCMP_ACT_ALLOW",
351
+      "args": []
352
+    },
353
+    {
354
+      "name": "getegid",
355
+      "action": "SCMP_ACT_ALLOW",
356
+      "args": []
357
+    },
358
+    {
359
+      "name": "getegid32",
360
+      "action": "SCMP_ACT_ALLOW",
361
+      "args": []
362
+    },
363
+    {
364
+      "name": "geteuid",
365
+      "action": "SCMP_ACT_ALLOW",
366
+      "args": []
367
+    },
368
+    {
369
+      "name": "geteuid32",
370
+      "action": "SCMP_ACT_ALLOW",
371
+      "args": []
372
+    },
373
+    {
374
+      "name": "getgid",
375
+      "action": "SCMP_ACT_ALLOW",
376
+      "args": []
377
+    },
378
+    {
379
+      "name": "getgid32",
380
+      "action": "SCMP_ACT_ALLOW",
381
+      "args": []
382
+    },
383
+    {
384
+      "name": "getgroups",
385
+      "action": "SCMP_ACT_ALLOW",
386
+      "args": []
387
+    },
388
+    {
389
+      "name": "getgroups32",
390
+      "action": "SCMP_ACT_ALLOW",
391
+      "args": []
392
+    },
393
+    {
394
+      "name": "getitimer",
395
+      "action": "SCMP_ACT_ALLOW",
396
+      "args": []
397
+    },
398
+    {
399
+      "name": "getpeername",
400
+      "action": "SCMP_ACT_ALLOW",
401
+      "args": []
402
+    },
403
+    {
404
+      "name": "getpgid",
405
+      "action": "SCMP_ACT_ALLOW",
406
+      "args": []
407
+    },
408
+    {
409
+      "name": "getpgrp",
410
+      "action": "SCMP_ACT_ALLOW",
411
+      "args": []
412
+    },
413
+    {
414
+      "name": "getpid",
415
+      "action": "SCMP_ACT_ALLOW",
416
+      "args": []
417
+    },
418
+    {
419
+      "name": "getppid",
420
+      "action": "SCMP_ACT_ALLOW",
421
+      "args": []
422
+    },
423
+    {
424
+      "name": "getpriority",
425
+      "action": "SCMP_ACT_ALLOW",
426
+      "args": []
427
+    },
428
+    {
429
+      "name": "getrandom",
430
+      "action": "SCMP_ACT_ALLOW",
431
+      "args": []
432
+    },
433
+    {
434
+      "name": "getresgid",
435
+      "action": "SCMP_ACT_ALLOW",
436
+      "args": []
437
+    },
438
+    {
439
+      "name": "getresgid32",
440
+      "action": "SCMP_ACT_ALLOW",
441
+      "args": []
442
+    },
443
+    {
444
+      "name": "getresuid",
445
+      "action": "SCMP_ACT_ALLOW",
446
+      "args": []
447
+    },
448
+    {
449
+      "name": "getresuid32",
450
+      "action": "SCMP_ACT_ALLOW",
451
+      "args": []
452
+    },
453
+    {
454
+      "name": "getrlimit",
455
+      "action": "SCMP_ACT_ALLOW",
456
+      "args": []
457
+    },
458
+    {
459
+      "name": "get_robust_list",
460
+      "action": "SCMP_ACT_ALLOW",
461
+      "args": []
462
+    },
463
+    {
464
+      "name": "getrusage",
465
+      "action": "SCMP_ACT_ALLOW",
466
+      "args": []
467
+    },
468
+    {
469
+      "name": "getsid",
470
+      "action": "SCMP_ACT_ALLOW",
471
+      "args": []
472
+    },
473
+    {
474
+      "name": "getsockname",
475
+      "action": "SCMP_ACT_ALLOW",
476
+      "args": []
477
+    },
478
+    {
479
+      "name": "getsockopt",
480
+      "action": "SCMP_ACT_ALLOW",
481
+      "args": []
482
+    },
483
+    {
484
+      "name": "get_thread_area",
485
+      "action": "SCMP_ACT_ALLOW",
486
+      "args": []
487
+    },
488
+    {
489
+      "name": "gettid",
490
+      "action": "SCMP_ACT_ALLOW",
491
+      "args": []
492
+    },
493
+    {
494
+      "name": "gettimeofday",
495
+      "action": "SCMP_ACT_ALLOW",
496
+      "args": []
497
+    },
498
+    {
499
+      "name": "getuid",
500
+      "action": "SCMP_ACT_ALLOW",
501
+      "args": []
502
+    },
503
+    {
504
+      "name": "getuid32",
505
+      "action": "SCMP_ACT_ALLOW",
506
+      "args": []
507
+    },
508
+    {
509
+      "name": "getxattr",
510
+      "action": "SCMP_ACT_ALLOW",
511
+      "args": []
512
+    },
513
+    {
514
+      "name": "inotify_add_watch",
515
+      "action": "SCMP_ACT_ALLOW",
516
+      "args": []
517
+    },
518
+    {
519
+      "name": "inotify_init",
520
+      "action": "SCMP_ACT_ALLOW",
521
+      "args": []
522
+    },
523
+    {
524
+      "name": "inotify_init1",
525
+      "action": "SCMP_ACT_ALLOW",
526
+      "args": []
527
+    },
528
+    {
529
+      "name": "inotify_rm_watch",
530
+      "action": "SCMP_ACT_ALLOW",
531
+      "args": []
532
+    },
533
+    {
534
+      "name": "io_cancel",
535
+      "action": "SCMP_ACT_ALLOW",
536
+      "args": []
537
+    },
538
+    {
539
+      "name": "ioctl",
540
+      "action": "SCMP_ACT_ALLOW",
541
+      "args": []
542
+    },
543
+    {
544
+      "name": "io_destroy",
545
+      "action": "SCMP_ACT_ALLOW",
546
+      "args": []
547
+    },
548
+    {
549
+      "name": "io_getevents",
550
+      "action": "SCMP_ACT_ALLOW",
551
+      "args": []
552
+    },
553
+    {
554
+      "name": "ioprio_get",
555
+      "action": "SCMP_ACT_ALLOW",
556
+      "args": []
557
+    },
558
+    {
559
+      "name": "ioprio_set",
560
+      "action": "SCMP_ACT_ALLOW",
561
+      "args": []
562
+    },
563
+    {
564
+      "name": "io_setup",
565
+      "action": "SCMP_ACT_ALLOW",
566
+      "args": []
567
+    },
568
+    {
569
+      "name": "io_submit",
570
+      "action": "SCMP_ACT_ALLOW",
571
+      "args": []
572
+    },
573
+    {
574
+      "name": "ipc",
575
+      "action": "SCMP_ACT_ALLOW",
576
+      "args": []
577
+    },
578
+    {
579
+      "name": "kill",
580
+      "action": "SCMP_ACT_ALLOW",
581
+      "args": []
582
+    },
583
+    {
584
+      "name": "lchown",
585
+      "action": "SCMP_ACT_ALLOW",
586
+      "args": []
587
+    },
588
+    {
589
+      "name": "lchown32",
590
+      "action": "SCMP_ACT_ALLOW",
591
+      "args": []
592
+    },
593
+    {
594
+      "name": "lgetxattr",
595
+      "action": "SCMP_ACT_ALLOW",
596
+      "args": []
597
+    },
598
+    {
599
+      "name": "link",
600
+      "action": "SCMP_ACT_ALLOW",
601
+      "args": []
602
+    },
603
+    {
604
+      "name": "linkat",
605
+      "action": "SCMP_ACT_ALLOW",
606
+      "args": []
607
+    },
608
+    {
609
+      "name": "listen",
610
+      "action": "SCMP_ACT_ALLOW",
611
+      "args": []
612
+    },
613
+    {
614
+      "name": "listxattr",
615
+      "action": "SCMP_ACT_ALLOW",
616
+      "args": []
617
+    },
618
+    {
619
+      "name": "llistxattr",
620
+      "action": "SCMP_ACT_ALLOW",
621
+      "args": []
622
+    },
623
+    {
624
+      "name": "_llseek",
625
+      "action": "SCMP_ACT_ALLOW",
626
+      "args": []
627
+    },
628
+    {
629
+      "name": "lremovexattr",
630
+      "action": "SCMP_ACT_ALLOW",
631
+      "args": []
632
+    },
633
+    {
634
+      "name": "lseek",
635
+      "action": "SCMP_ACT_ALLOW",
636
+      "args": []
637
+    },
638
+    {
639
+      "name": "lsetxattr",
640
+      "action": "SCMP_ACT_ALLOW",
641
+      "args": []
642
+    },
643
+    {
644
+      "name": "lstat",
645
+      "action": "SCMP_ACT_ALLOW",
646
+      "args": []
647
+    },
648
+    {
649
+      "name": "lstat64",
650
+      "action": "SCMP_ACT_ALLOW",
651
+      "args": []
652
+    },
653
+    {
654
+      "name": "madvise",
655
+      "action": "SCMP_ACT_ALLOW",
656
+      "args": []
657
+    },
658
+    {
659
+      "name": "memfd_create",
660
+      "action": "SCMP_ACT_ALLOW",
661
+      "args": []
662
+    },
663
+    {
664
+      "name": "mincore",
665
+      "action": "SCMP_ACT_ALLOW",
666
+      "args": []
667
+    },
668
+    {
669
+      "name": "mkdir",
670
+      "action": "SCMP_ACT_ALLOW",
671
+      "args": []
672
+    },
673
+    {
674
+      "name": "mkdirat",
675
+      "action": "SCMP_ACT_ALLOW",
676
+      "args": []
677
+    },
678
+    {
679
+      "name": "mknod",
680
+      "action": "SCMP_ACT_ALLOW",
681
+      "args": []
682
+    },
683
+    {
684
+      "name": "mknodat",
685
+      "action": "SCMP_ACT_ALLOW",
686
+      "args": []
687
+    },
688
+    {
689
+      "name": "mlock",
690
+      "action": "SCMP_ACT_ALLOW",
691
+      "args": []
692
+    },
693
+    {
694
+      "name": "mlock2",
695
+      "action": "SCMP_ACT_ALLOW",
696
+      "args": []
697
+    },
698
+    {
699
+      "name": "mlockall",
700
+      "action": "SCMP_ACT_ALLOW",
701
+      "args": []
702
+    },
703
+    {
704
+      "name": "mmap",
705
+      "action": "SCMP_ACT_ALLOW",
706
+      "args": []
707
+    },
708
+    {
709
+      "name": "mmap2",
710
+      "action": "SCMP_ACT_ALLOW",
711
+      "args": []
712
+    },
713
+    {
714
+      "name": "mprotect",
715
+      "action": "SCMP_ACT_ALLOW",
716
+      "args": []
717
+    },
718
+    {
719
+      "name": "mq_getsetattr",
720
+      "action": "SCMP_ACT_ALLOW",
721
+      "args": []
722
+    },
723
+    {
724
+      "name": "mq_notify",
725
+      "action": "SCMP_ACT_ALLOW",
726
+      "args": []
727
+    },
728
+    {
729
+      "name": "mq_open",
730
+      "action": "SCMP_ACT_ALLOW",
731
+      "args": []
732
+    },
733
+    {
734
+      "name": "mq_timedreceive",
735
+      "action": "SCMP_ACT_ALLOW",
736
+      "args": []
737
+    },
738
+    {
739
+      "name": "mq_timedsend",
740
+      "action": "SCMP_ACT_ALLOW",
741
+      "args": []
742
+    },
743
+    {
744
+      "name": "mq_unlink",
745
+      "action": "SCMP_ACT_ALLOW",
746
+      "args": []
747
+    },
748
+    {
749
+      "name": "mremap",
750
+      "action": "SCMP_ACT_ALLOW",
751
+      "args": []
752
+    },
753
+    {
754
+      "name": "msgctl",
755
+      "action": "SCMP_ACT_ALLOW",
756
+      "args": []
757
+    },
758
+    {
759
+      "name": "msgget",
760
+      "action": "SCMP_ACT_ALLOW",
761
+      "args": []
762
+    },
763
+    {
764
+      "name": "msgrcv",
765
+      "action": "SCMP_ACT_ALLOW",
766
+      "args": []
767
+    },
768
+    {
769
+      "name": "msgsnd",
770
+      "action": "SCMP_ACT_ALLOW",
771
+      "args": []
772
+    },
773
+    {
774
+      "name": "msync",
775
+      "action": "SCMP_ACT_ALLOW",
776
+      "args": []
777
+    },
778
+    {
779
+      "name": "munlock",
780
+      "action": "SCMP_ACT_ALLOW",
781
+      "args": []
782
+    },
783
+    {
784
+      "name": "munlockall",
785
+      "action": "SCMP_ACT_ALLOW",
786
+      "args": []
787
+    },
788
+    {
789
+      "name": "munmap",
790
+      "action": "SCMP_ACT_ALLOW",
791
+      "args": []
792
+    },
793
+    {
794
+      "name": "nanosleep",
795
+      "action": "SCMP_ACT_ALLOW",
796
+      "args": []
797
+    },
798
+    {
799
+      "name": "newfstatat",
800
+      "action": "SCMP_ACT_ALLOW",
801
+      "args": []
802
+    },
803
+    {
804
+      "name": "_newselect",
805
+      "action": "SCMP_ACT_ALLOW",
806
+      "args": []
807
+    },
808
+    {
809
+      "name": "open",
810
+      "action": "SCMP_ACT_ALLOW",
811
+      "args": []
812
+    },
813
+    {
814
+      "name": "openat",
815
+      "action": "SCMP_ACT_ALLOW",
816
+      "args": []
817
+    },
818
+    {
819
+      "name": "pause",
820
+      "action": "SCMP_ACT_ALLOW",
821
+      "args": []
822
+    },
823
+    {
824
+      "name": "personality",
825
+      "action": "SCMP_ACT_ALLOW",
826
+      "args": [
827
+        {
828
+          "index": 0,
829
+          "value": 0,
830
+          "valueTwo": 0,
831
+          "op": "SCMP_CMP_EQ"
832
+        }
833
+      ]
834
+    },
835
+    {
836
+      "name": "personality",
837
+      "action": "SCMP_ACT_ALLOW",
838
+      "args": [
839
+        {
840
+          "index": 0,
841
+          "value": 8,
842
+          "valueTwo": 0,
843
+          "op": "SCMP_CMP_EQ"
844
+        }
845
+      ]
846
+    },
847
+    {
848
+      "name": "personality",
849
+      "action": "SCMP_ACT_ALLOW",
850
+      "args": [
851
+        {
852
+          "index": 0,
853
+          "value": 4294967295,
854
+          "valueTwo": 0,
855
+          "op": "SCMP_CMP_EQ"
856
+        }
857
+      ]
858
+    },
859
+    {
860
+      "name": "pipe",
861
+      "action": "SCMP_ACT_ALLOW",
862
+      "args": []
863
+    },
864
+    {
865
+      "name": "pipe2",
866
+      "action": "SCMP_ACT_ALLOW",
867
+      "args": []
868
+    },
869
+    {
870
+      "name": "poll",
871
+      "action": "SCMP_ACT_ALLOW",
872
+      "args": []
873
+    },
874
+    {
875
+      "name": "ppoll",
876
+      "action": "SCMP_ACT_ALLOW",
877
+      "args": []
878
+    },
879
+    {
880
+      "name": "prctl",
881
+      "action": "SCMP_ACT_ALLOW",
882
+      "args": []
883
+    },
884
+    {
885
+      "name": "pread64",
886
+      "action": "SCMP_ACT_ALLOW",
887
+      "args": []
888
+    },
889
+    {
890
+      "name": "preadv",
891
+      "action": "SCMP_ACT_ALLOW",
892
+      "args": []
893
+    },
894
+    {
895
+      "name": "prlimit64",
896
+      "action": "SCMP_ACT_ALLOW",
897
+      "args": []
898
+    },
899
+    {
900
+      "name": "pselect6",
901
+      "action": "SCMP_ACT_ALLOW",
902
+      "args": []
903
+    },
904
+    {
905
+      "name": "pwrite64",
906
+      "action": "SCMP_ACT_ALLOW",
907
+      "args": []
908
+    },
909
+    {
910
+      "name": "pwritev",
911
+      "action": "SCMP_ACT_ALLOW",
912
+      "args": []
913
+    },
914
+    {
915
+      "name": "read",
916
+      "action": "SCMP_ACT_ALLOW",
917
+      "args": []
918
+    },
919
+    {
920
+      "name": "readahead",
921
+      "action": "SCMP_ACT_ALLOW",
922
+      "args": []
923
+    },
924
+    {
925
+      "name": "readlink",
926
+      "action": "SCMP_ACT_ALLOW",
927
+      "args": []
928
+    },
929
+    {
930
+      "name": "readlinkat",
931
+      "action": "SCMP_ACT_ALLOW",
932
+      "args": []
933
+    },
934
+    {
935
+      "name": "readv",
936
+      "action": "SCMP_ACT_ALLOW",
937
+      "args": []
938
+    },
939
+    {
940
+      "name": "recv",
941
+      "action": "SCMP_ACT_ALLOW",
942
+      "args": []
943
+    },
944
+    {
945
+      "name": "recvfrom",
946
+      "action": "SCMP_ACT_ALLOW",
947
+      "args": []
948
+    },
949
+    {
950
+      "name": "recvmmsg",
951
+      "action": "SCMP_ACT_ALLOW",
952
+      "args": []
953
+    },
954
+    {
955
+      "name": "recvmsg",
956
+      "action": "SCMP_ACT_ALLOW",
957
+      "args": []
958
+    },
959
+    {
960
+      "name": "remap_file_pages",
961
+      "action": "SCMP_ACT_ALLOW",
962
+      "args": []
963
+    },
964
+    {
965
+      "name": "removexattr",
966
+      "action": "SCMP_ACT_ALLOW",
967
+      "args": []
968
+    },
969
+    {
970
+      "name": "rename",
971
+      "action": "SCMP_ACT_ALLOW",
972
+      "args": []
973
+    },
974
+    {
975
+      "name": "renameat",
976
+      "action": "SCMP_ACT_ALLOW",
977
+      "args": []
978
+    },
979
+    {
980
+      "name": "renameat2",
981
+      "action": "SCMP_ACT_ALLOW",
982
+      "args": []
983
+    },
984
+    {
985
+      "name": "restart_syscall",
986
+      "action": "SCMP_ACT_ALLOW",
987
+      "args": []
988
+    },
989
+    {
990
+      "name": "rmdir",
991
+      "action": "SCMP_ACT_ALLOW",
992
+      "args": []
993
+    },
994
+    {
995
+      "name": "rt_sigaction",
996
+      "action": "SCMP_ACT_ALLOW",
997
+      "args": []
998
+    },
999
+    {
1000
+      "name": "rt_sigpending",
1001
+      "action": "SCMP_ACT_ALLOW",
1002
+      "args": []
1003
+    },
1004
+    {
1005
+      "name": "rt_sigprocmask",
1006
+      "action": "SCMP_ACT_ALLOW",
1007
+      "args": []
1008
+    },
1009
+    {
1010
+      "name": "rt_sigqueueinfo",
1011
+      "action": "SCMP_ACT_ALLOW",
1012
+      "args": []
1013
+    },
1014
+    {
1015
+      "name": "rt_sigreturn",
1016
+      "action": "SCMP_ACT_ALLOW",
1017
+      "args": []
1018
+    },
1019
+    {
1020
+      "name": "rt_sigsuspend",
1021
+      "action": "SCMP_ACT_ALLOW",
1022
+      "args": []
1023
+    },
1024
+    {
1025
+      "name": "rt_sigtimedwait",
1026
+      "action": "SCMP_ACT_ALLOW",
1027
+      "args": []
1028
+    },
1029
+    {
1030
+      "name": "rt_tgsigqueueinfo",
1031
+      "action": "SCMP_ACT_ALLOW",
1032
+      "args": []
1033
+    },
1034
+    {
1035
+      "name": "sched_getaffinity",
1036
+      "action": "SCMP_ACT_ALLOW",
1037
+      "args": []
1038
+    },
1039
+    {
1040
+      "name": "sched_getattr",
1041
+      "action": "SCMP_ACT_ALLOW",
1042
+      "args": []
1043
+    },
1044
+    {
1045
+      "name": "sched_getparam",
1046
+      "action": "SCMP_ACT_ALLOW",
1047
+      "args": []
1048
+    },
1049
+    {
1050
+      "name": "sched_get_priority_max",
1051
+      "action": "SCMP_ACT_ALLOW",
1052
+      "args": []
1053
+    },
1054
+    {
1055
+      "name": "sched_get_priority_min",
1056
+      "action": "SCMP_ACT_ALLOW",
1057
+      "args": []
1058
+    },
1059
+    {
1060
+      "name": "sched_getscheduler",
1061
+      "action": "SCMP_ACT_ALLOW",
1062
+      "args": []
1063
+    },
1064
+    {
1065
+      "name": "sched_rr_get_interval",
1066
+      "action": "SCMP_ACT_ALLOW",
1067
+      "args": []
1068
+    },
1069
+    {
1070
+      "name": "sched_setaffinity",
1071
+      "action": "SCMP_ACT_ALLOW",
1072
+      "args": []
1073
+    },
1074
+    {
1075
+      "name": "sched_setattr",
1076
+      "action": "SCMP_ACT_ALLOW",
1077
+      "args": []
1078
+    },
1079
+    {
1080
+      "name": "sched_setparam",
1081
+      "action": "SCMP_ACT_ALLOW",
1082
+      "args": []
1083
+    },
1084
+    {
1085
+      "name": "sched_setscheduler",
1086
+      "action": "SCMP_ACT_ALLOW",
1087
+      "args": []
1088
+    },
1089
+    {
1090
+      "name": "sched_yield",
1091
+      "action": "SCMP_ACT_ALLOW",
1092
+      "args": []
1093
+    },
1094
+    {
1095
+      "name": "seccomp",
1096
+      "action": "SCMP_ACT_ALLOW",
1097
+      "args": []
1098
+    },
1099
+    {
1100
+      "name": "select",
1101
+      "action": "SCMP_ACT_ALLOW",
1102
+      "args": []
1103
+    },
1104
+    {
1105
+      "name": "semctl",
1106
+      "action": "SCMP_ACT_ALLOW",
1107
+      "args": []
1108
+    },
1109
+    {
1110
+      "name": "semget",
1111
+      "action": "SCMP_ACT_ALLOW",
1112
+      "args": []
1113
+    },
1114
+    {
1115
+      "name": "semop",
1116
+      "action": "SCMP_ACT_ALLOW",
1117
+      "args": []
1118
+    },
1119
+    {
1120
+      "name": "semtimedop",
1121
+      "action": "SCMP_ACT_ALLOW",
1122
+      "args": []
1123
+    },
1124
+    {
1125
+      "name": "send",
1126
+      "action": "SCMP_ACT_ALLOW",
1127
+      "args": []
1128
+    },
1129
+    {
1130
+      "name": "sendfile",
1131
+      "action": "SCMP_ACT_ALLOW",
1132
+      "args": []
1133
+    },
1134
+    {
1135
+      "name": "sendfile64",
1136
+      "action": "SCMP_ACT_ALLOW",
1137
+      "args": []
1138
+    },
1139
+    {
1140
+      "name": "sendmmsg",
1141
+      "action": "SCMP_ACT_ALLOW",
1142
+      "args": []
1143
+    },
1144
+    {
1145
+      "name": "sendmsg",
1146
+      "action": "SCMP_ACT_ALLOW",
1147
+      "args": []
1148
+    },
1149
+    {
1150
+      "name": "sendto",
1151
+      "action": "SCMP_ACT_ALLOW",
1152
+      "args": []
1153
+    },
1154
+    {
1155
+      "name": "setfsgid",
1156
+      "action": "SCMP_ACT_ALLOW",
1157
+      "args": []
1158
+    },
1159
+    {
1160
+      "name": "setfsgid32",
1161
+      "action": "SCMP_ACT_ALLOW",
1162
+      "args": []
1163
+    },
1164
+    {
1165
+      "name": "setfsuid",
1166
+      "action": "SCMP_ACT_ALLOW",
1167
+      "args": []
1168
+    },
1169
+    {
1170
+      "name": "setfsuid32",
1171
+      "action": "SCMP_ACT_ALLOW",
1172
+      "args": []
1173
+    },
1174
+    {
1175
+      "name": "setgid",
1176
+      "action": "SCMP_ACT_ALLOW",
1177
+      "args": []
1178
+    },
1179
+    {
1180
+      "name": "setgid32",
1181
+      "action": "SCMP_ACT_ALLOW",
1182
+      "args": []
1183
+    },
1184
+    {
1185
+      "name": "setgroups",
1186
+      "action": "SCMP_ACT_ALLOW",
1187
+      "args": []
1188
+    },
1189
+    {
1190
+      "name": "setgroups32",
1191
+      "action": "SCMP_ACT_ALLOW",
1192
+      "args": []
1193
+    },
1194
+    {
1195
+      "name": "setitimer",
1196
+      "action": "SCMP_ACT_ALLOW",
1197
+      "args": []
1198
+    },
1199
+    {
1200
+      "name": "setpgid",
1201
+      "action": "SCMP_ACT_ALLOW",
1202
+      "args": []
1203
+    },
1204
+    {
1205
+      "name": "setpriority",
1206
+      "action": "SCMP_ACT_ALLOW",
1207
+      "args": []
1208
+    },
1209
+    {
1210
+      "name": "setregid",
1211
+      "action": "SCMP_ACT_ALLOW",
1212
+      "args": []
1213
+    },
1214
+    {
1215
+      "name": "setregid32",
1216
+      "action": "SCMP_ACT_ALLOW",
1217
+      "args": []
1218
+    },
1219
+    {
1220
+      "name": "setresgid",
1221
+      "action": "SCMP_ACT_ALLOW",
1222
+      "args": []
1223
+    },
1224
+    {
1225
+      "name": "setresgid32",
1226
+      "action": "SCMP_ACT_ALLOW",
1227
+      "args": []
1228
+    },
1229
+    {
1230
+      "name": "setresuid",
1231
+      "action": "SCMP_ACT_ALLOW",
1232
+      "args": []
1233
+    },
1234
+    {
1235
+      "name": "setresuid32",
1236
+      "action": "SCMP_ACT_ALLOW",
1237
+      "args": []
1238
+    },
1239
+    {
1240
+      "name": "setreuid",
1241
+      "action": "SCMP_ACT_ALLOW",
1242
+      "args": []
1243
+    },
1244
+    {
1245
+      "name": "setreuid32",
1246
+      "action": "SCMP_ACT_ALLOW",
1247
+      "args": []
1248
+    },
1249
+    {
1250
+      "name": "setrlimit",
1251
+      "action": "SCMP_ACT_ALLOW",
1252
+      "args": []
1253
+    },
1254
+    {
1255
+      "name": "set_robust_list",
1256
+      "action": "SCMP_ACT_ALLOW",
1257
+      "args": []
1258
+    },
1259
+    {
1260
+      "name": "setsid",
1261
+      "action": "SCMP_ACT_ALLOW",
1262
+      "args": []
1263
+    },
1264
+    {
1265
+      "name": "setsockopt",
1266
+      "action": "SCMP_ACT_ALLOW",
1267
+      "args": []
1268
+    },
1269
+    {
1270
+      "name": "set_thread_area",
1271
+      "action": "SCMP_ACT_ALLOW",
1272
+      "args": []
1273
+    },
1274
+    {
1275
+      "name": "set_tid_address",
1276
+      "action": "SCMP_ACT_ALLOW",
1277
+      "args": []
1278
+    },
1279
+    {
1280
+      "name": "setuid",
1281
+      "action": "SCMP_ACT_ALLOW",
1282
+      "args": []
1283
+    },
1284
+    {
1285
+      "name": "setuid32",
1286
+      "action": "SCMP_ACT_ALLOW",
1287
+      "args": []
1288
+    },
1289
+    {
1290
+      "name": "setxattr",
1291
+      "action": "SCMP_ACT_ALLOW",
1292
+      "args": []
1293
+    },
1294
+    {
1295
+      "name": "shmat",
1296
+      "action": "SCMP_ACT_ALLOW",
1297
+      "args": []
1298
+    },
1299
+    {
1300
+      "name": "shmctl",
1301
+      "action": "SCMP_ACT_ALLOW",
1302
+      "args": []
1303
+    },
1304
+    {
1305
+      "name": "shmdt",
1306
+      "action": "SCMP_ACT_ALLOW",
1307
+      "args": []
1308
+    },
1309
+    {
1310
+      "name": "shmget",
1311
+      "action": "SCMP_ACT_ALLOW",
1312
+      "args": []
1313
+    },
1314
+    {
1315
+      "name": "shutdown",
1316
+      "action": "SCMP_ACT_ALLOW",
1317
+      "args": []
1318
+    },
1319
+    {
1320
+      "name": "sigaltstack",
1321
+      "action": "SCMP_ACT_ALLOW",
1322
+      "args": []
1323
+    },
1324
+    {
1325
+      "name": "signalfd",
1326
+      "action": "SCMP_ACT_ALLOW",
1327
+      "args": []
1328
+    },
1329
+    {
1330
+      "name": "signalfd4",
1331
+      "action": "SCMP_ACT_ALLOW",
1332
+      "args": []
1333
+    },
1334
+    {
1335
+      "name": "sigreturn",
1336
+      "action": "SCMP_ACT_ALLOW",
1337
+      "args": []
1338
+    },
1339
+    {
1340
+      "name": "socket",
1341
+      "action": "SCMP_ACT_ALLOW",
1342
+      "args": []
1343
+    },
1344
+    {
1345
+      "name": "socketcall",
1346
+      "action": "SCMP_ACT_ALLOW",
1347
+      "args": []
1348
+    },
1349
+    {
1350
+      "name": "socketpair",
1351
+      "action": "SCMP_ACT_ALLOW",
1352
+      "args": []
1353
+    },
1354
+    {
1355
+      "name": "splice",
1356
+      "action": "SCMP_ACT_ALLOW",
1357
+      "args": []
1358
+    },
1359
+    {
1360
+      "name": "stat",
1361
+      "action": "SCMP_ACT_ALLOW",
1362
+      "args": []
1363
+    },
1364
+    {
1365
+      "name": "stat64",
1366
+      "action": "SCMP_ACT_ALLOW",
1367
+      "args": []
1368
+    },
1369
+    {
1370
+      "name": "statfs",
1371
+      "action": "SCMP_ACT_ALLOW",
1372
+      "args": []
1373
+    },
1374
+    {
1375
+      "name": "statfs64",
1376
+      "action": "SCMP_ACT_ALLOW",
1377
+      "args": []
1378
+    },
1379
+    {
1380
+      "name": "symlink",
1381
+      "action": "SCMP_ACT_ALLOW",
1382
+      "args": []
1383
+    },
1384
+    {
1385
+      "name": "symlinkat",
1386
+      "action": "SCMP_ACT_ALLOW",
1387
+      "args": []
1388
+    },
1389
+    {
1390
+      "name": "sync",
1391
+      "action": "SCMP_ACT_ALLOW",
1392
+      "args": []
1393
+    },
1394
+    {
1395
+      "name": "sync_file_range",
1396
+      "action": "SCMP_ACT_ALLOW",
1397
+      "args": []
1398
+    },
1399
+    {
1400
+      "name": "syncfs",
1401
+      "action": "SCMP_ACT_ALLOW",
1402
+      "args": []
1403
+    },
1404
+    {
1405
+      "name": "sysinfo",
1406
+      "action": "SCMP_ACT_ALLOW",
1407
+      "args": []
1408
+    },
1409
+    {
1410
+      "name": "syslog",
1411
+      "action": "SCMP_ACT_ALLOW",
1412
+      "args": []
1413
+    },
1414
+    {
1415
+      "name": "tee",
1416
+      "action": "SCMP_ACT_ALLOW",
1417
+      "args": []
1418
+    },
1419
+    {
1420
+      "name": "tgkill",
1421
+      "action": "SCMP_ACT_ALLOW",
1422
+      "args": []
1423
+    },
1424
+    {
1425
+      "name": "time",
1426
+      "action": "SCMP_ACT_ALLOW",
1427
+      "args": []
1428
+    },
1429
+    {
1430
+      "name": "timer_create",
1431
+      "action": "SCMP_ACT_ALLOW",
1432
+      "args": []
1433
+    },
1434
+    {
1435
+      "name": "timer_delete",
1436
+      "action": "SCMP_ACT_ALLOW",
1437
+      "args": []
1438
+    },
1439
+    {
1440
+      "name": "timerfd_create",
1441
+      "action": "SCMP_ACT_ALLOW",
1442
+      "args": []
1443
+    },
1444
+    {
1445
+      "name": "timerfd_gettime",
1446
+      "action": "SCMP_ACT_ALLOW",
1447
+      "args": []
1448
+    },
1449
+    {
1450
+      "name": "timerfd_settime",
1451
+      "action": "SCMP_ACT_ALLOW",
1452
+      "args": []
1453
+    },
1454
+    {
1455
+      "name": "timer_getoverrun",
1456
+      "action": "SCMP_ACT_ALLOW",
1457
+      "args": []
1458
+    },
1459
+    {
1460
+      "name": "timer_gettime",
1461
+      "action": "SCMP_ACT_ALLOW",
1462
+      "args": []
1463
+    },
1464
+    {
1465
+      "name": "timer_settime",
1466
+      "action": "SCMP_ACT_ALLOW",
1467
+      "args": []
1468
+    },
1469
+    {
1470
+      "name": "times",
1471
+      "action": "SCMP_ACT_ALLOW",
1472
+      "args": []
1473
+    },
1474
+    {
1475
+      "name": "tkill",
1476
+      "action": "SCMP_ACT_ALLOW",
1477
+      "args": []
1478
+    },
1479
+    {
1480
+      "name": "truncate",
1481
+      "action": "SCMP_ACT_ALLOW",
1482
+      "args": []
1483
+    },
1484
+    {
1485
+      "name": "truncate64",
1486
+      "action": "SCMP_ACT_ALLOW",
1487
+      "args": []
1488
+    },
1489
+    {
1490
+      "name": "ugetrlimit",
1491
+      "action": "SCMP_ACT_ALLOW",
1492
+      "args": []
1493
+    },
1494
+    {
1495
+      "name": "umask",
1496
+      "action": "SCMP_ACT_ALLOW",
1497
+      "args": []
1498
+    },
1499
+    {
1500
+      "name": "uname",
1501
+      "action": "SCMP_ACT_ALLOW",
1502
+      "args": []
1503
+    },
1504
+    {
1505
+      "name": "unlink",
1506
+      "action": "SCMP_ACT_ALLOW",
1507
+      "args": []
1508
+    },
1509
+    {
1510
+      "name": "unlinkat",
1511
+      "action": "SCMP_ACT_ALLOW",
1512
+      "args": []
1513
+    },
1514
+    {
1515
+      "name": "utime",
1516
+      "action": "SCMP_ACT_ALLOW",
1517
+      "args": []
1518
+    },
1519
+    {
1520
+      "name": "utimensat",
1521
+      "action": "SCMP_ACT_ALLOW",
1522
+      "args": []
1523
+    },
1524
+    {
1525
+      "name": "utimes",
1526
+      "action": "SCMP_ACT_ALLOW",
1527
+      "args": []
1528
+    },
1529
+    {
1530
+      "name": "vfork",
1531
+      "action": "SCMP_ACT_ALLOW",
1532
+      "args": []
1533
+    },
1534
+    {
1535
+      "name": "vmsplice",
1536
+      "action": "SCMP_ACT_ALLOW",
1537
+      "args": []
1538
+    },
1539
+    {
1540
+      "name": "wait4",
1541
+      "action": "SCMP_ACT_ALLOW",
1542
+      "args": []
1543
+    },
1544
+    {
1545
+      "name": "waitid",
1546
+      "action": "SCMP_ACT_ALLOW",
1547
+      "args": []
1548
+    },
1549
+    {
1550
+      "name": "waitpid",
1551
+      "action": "SCMP_ACT_ALLOW",
1552
+      "args": []
1553
+    },
1554
+    {
1555
+      "name": "write",
1556
+      "action": "SCMP_ACT_ALLOW",
1557
+      "args": []
1558
+    },
1559
+    {
1560
+      "name": "writev",
1561
+      "action": "SCMP_ACT_ALLOW",
1562
+      "args": []
1563
+    },
1564
+    {
1565
+      "name": "arch_prctl",
1566
+      "action": "SCMP_ACT_ALLOW",
1567
+      "args": []
1568
+    },
1569
+    {
1570
+      "name": "modify_ldt",
1571
+      "action": "SCMP_ACT_ALLOW",
1572
+      "args": []
1573
+    },
1574
+    {
1575
+      "name": "chroot",
1576
+      "action": "SCMP_ACT_ALLOW",
1577
+      "args": []
1578
+    },
1579
+    {
1580
+      "name": "clone",
1581
+      "action": "SCMP_ACT_ALLOW",
1582
+      "args": [
1583
+        {
1584
+          "index": 0,
1585
+          "value": 2080505856,
1586
+          "valueTwo": 0,
1587
+          "op": "SCMP_CMP_MASKED_EQ"
1588
+        }
1589
+      ]
1590
+    }
1591
+  ]
1592
+}
0 1593
\ No newline at end of file
1 1594
new file mode 100755
... ...
@@ -0,0 +1,813 @@
0
+{
1
+	"defaultAction": "SCMP_ACT_ERRNO",
2
+	"archMap": [
3
+		{
4
+			"architecture": "SCMP_ARCH_X86_64",
5
+			"subArchitectures": [
6
+				"SCMP_ARCH_X86",
7
+				"SCMP_ARCH_X32"
8
+			]
9
+		},
10
+		{
11
+			"architecture": "SCMP_ARCH_AARCH64",
12
+			"subArchitectures": [
13
+				"SCMP_ARCH_ARM"
14
+			]
15
+		},
16
+		{
17
+			"architecture": "SCMP_ARCH_MIPS64",
18
+			"subArchitectures": [
19
+				"SCMP_ARCH_MIPS",
20
+				"SCMP_ARCH_MIPS64N32"
21
+			]
22
+		},
23
+		{
24
+			"architecture": "SCMP_ARCH_MIPS64N32",
25
+			"subArchitectures": [
26
+				"SCMP_ARCH_MIPS",
27
+				"SCMP_ARCH_MIPS64"
28
+			]
29
+		},
30
+		{
31
+			"architecture": "SCMP_ARCH_MIPSEL64",
32
+			"subArchitectures": [
33
+				"SCMP_ARCH_MIPSEL",
34
+				"SCMP_ARCH_MIPSEL64N32"
35
+			]
36
+		},
37
+		{
38
+			"architecture": "SCMP_ARCH_MIPSEL64N32",
39
+			"subArchitectures": [
40
+				"SCMP_ARCH_MIPSEL",
41
+				"SCMP_ARCH_MIPSEL64"
42
+			]
43
+		},
44
+		{
45
+			"architecture": "SCMP_ARCH_S390X",
46
+			"subArchitectures": [
47
+				"SCMP_ARCH_S390"
48
+			]
49
+		}
50
+	],
51
+	"syscalls": [
52
+		{
53
+			"names": [
54
+				"accept",
55
+				"accept4",
56
+				"access",
57
+				"adjtimex",
58
+				"alarm",
59
+				"bind",
60
+				"brk",
61
+				"capget",
62
+				"capset",
63
+				"chdir",
64
+				"chmod",
65
+				"chown",
66
+				"chown32",
67
+				"clock_getres",
68
+				"clock_getres_time64",
69
+				"clock_gettime",
70
+				"clock_gettime64",
71
+				"clock_nanosleep",
72
+				"clock_nanosleep_time64",
73
+				"close",
74
+				"connect",
75
+				"copy_file_range",
76
+				"creat",
77
+				"dup",
78
+				"dup2",
79
+				"dup3",
80
+				"epoll_create",
81
+				"epoll_create1",
82
+				"epoll_ctl",
83
+				"epoll_ctl_old",
84
+				"epoll_pwait",
85
+				"epoll_wait",
86
+				"epoll_wait_old",
87
+				"eventfd",
88
+				"eventfd2",
89
+				"execve",
90
+				"execveat",
91
+				"exit",
92
+				"exit_group",
93
+				"faccessat",
94
+				"fadvise64",
95
+				"fadvise64_64",
96
+				"fallocate",
97
+				"fanotify_mark",
98
+				"fchdir",
99
+				"fchmod",
100
+				"fchmodat",
101
+				"fchown",
102
+				"fchown32",
103
+				"fchownat",
104
+				"fcntl",
105
+				"fcntl64",
106
+				"fdatasync",
107
+				"fgetxattr",
108
+				"flistxattr",
109
+				"flock",
110
+				"fork",
111
+				"fremovexattr",
112
+				"fsetxattr",
113
+				"fstat",
114
+				"fstat64",
115
+				"fstatat64",
116
+				"fstatfs",
117
+				"fstatfs64",
118
+				"fsync",
119
+				"ftruncate",
120
+				"ftruncate64",
121
+				"futex",
122
+				"futex_time64",
123
+				"futimesat",
124
+				"getcpu",
125
+				"getcwd",
126
+				"getdents",
127
+				"getdents64",
128
+				"getegid",
129
+				"getegid32",
130
+				"geteuid",
131
+				"geteuid32",
132
+				"getgid",
133
+				"getgid32",
134
+				"getgroups",
135
+				"getgroups32",
136
+				"getitimer",
137
+				"getpeername",
138
+				"getpgid",
139
+				"getpgrp",
140
+				"getpid",
141
+				"getppid",
142
+				"getpriority",
143
+				"getrandom",
144
+				"getresgid",
145
+				"getresgid32",
146
+				"getresuid",
147
+				"getresuid32",
148
+				"getrlimit",
149
+				"get_robust_list",
150
+				"getrusage",
151
+				"getsid",
152
+				"getsockname",
153
+				"getsockopt",
154
+				"get_thread_area",
155
+				"gettid",
156
+				"gettimeofday",
157
+				"getuid",
158
+				"getuid32",
159
+				"getxattr",
160
+				"inotify_add_watch",
161
+				"inotify_init",
162
+				"inotify_init1",
163
+				"inotify_rm_watch",
164
+				"io_cancel",
165
+				"ioctl",
166
+				"io_destroy",
167
+				"io_getevents",
168
+				"io_pgetevents",
169
+				"io_pgetevents_time64",
170
+				"ioprio_get",
171
+				"ioprio_set",
172
+				"io_setup",
173
+				"io_submit",
174
+				"ipc",
175
+				"kill",
176
+				"lchown",
177
+				"lchown32",
178
+				"lgetxattr",
179
+				"link",
180
+				"linkat",
181
+				"listen",
182
+				"listxattr",
183
+				"llistxattr",
184
+				"_llseek",
185
+				"lremovexattr",
186
+				"lseek",
187
+				"lsetxattr",
188
+				"lstat",
189
+				"lstat64",
190
+				"madvise",
191
+				"memfd_create",
192
+				"mincore",
193
+				"mkdir",
194
+				"mkdirat",
195
+				"mknod",
196
+				"mknodat",
197
+				"mlock",
198
+				"mlock2",
199
+				"mlockall",
200
+				"mmap",
201
+				"mmap2",
202
+				"mprotect",
203
+				"mq_getsetattr",
204
+				"mq_notify",
205
+				"mq_open",
206
+				"mq_timedreceive",
207
+				"mq_timedreceive_time64",
208
+				"mq_timedsend",
209
+				"mq_timedsend_time64",
210
+				"mq_unlink",
211
+				"mremap",
212
+				"msgctl",
213
+				"msgget",
214
+				"msgrcv",
215
+				"msgsnd",
216
+				"msync",
217
+				"munlock",
218
+				"munlockall",
219
+				"munmap",
220
+				"nanosleep",
221
+				"newfstatat",
222
+				"_newselect",
223
+				"open",
224
+				"openat",
225
+				"pause",
226
+				"pipe",
227
+				"pipe2",
228
+				"poll",
229
+				"ppoll",
230
+				"ppoll_time64",
231
+				"prctl",
232
+				"pread64",
233
+				"preadv",
234
+				"preadv2",
235
+				"prlimit64",
236
+				"pselect6",
237
+				"pselect6_time64",
238
+				"pwrite64",
239
+				"pwritev",
240
+				"pwritev2",
241
+				"read",
242
+				"readahead",
243
+				"readlink",
244
+				"readlinkat",
245
+				"readv",
246
+				"recv",
247
+				"recvfrom",
248
+				"recvmmsg",
249
+				"recvmmsg_time64",
250
+				"recvmsg",
251
+				"remap_file_pages",
252
+				"removexattr",
253
+				"rename",
254
+				"renameat",
255
+				"renameat2",
256
+				"restart_syscall",
257
+				"rmdir",
258
+				"rt_sigaction",
259
+				"rt_sigpending",
260
+				"rt_sigprocmask",
261
+				"rt_sigqueueinfo",
262
+				"rt_sigreturn",
263
+				"rt_sigsuspend",
264
+				"rt_sigtimedwait",
265
+				"rt_sigtimedwait_time64",
266
+				"rt_tgsigqueueinfo",
267
+				"sched_getaffinity",
268
+				"sched_getattr",
269
+				"sched_getparam",
270
+				"sched_get_priority_max",
271
+				"sched_get_priority_min",
272
+				"sched_getscheduler",
273
+				"sched_rr_get_interval",
274
+				"sched_rr_get_interval_time64",
275
+				"sched_setaffinity",
276
+				"sched_setattr",
277
+				"sched_setparam",
278
+				"sched_setscheduler",
279
+				"sched_yield",
280
+				"seccomp",
281
+				"select",
282
+				"semctl",
283
+				"semget",
284
+				"semop",
285
+				"semtimedop",
286
+				"semtimedop_time64",
287
+				"send",
288
+				"sendfile",
289
+				"sendfile64",
290
+				"sendmmsg",
291
+				"sendmsg",
292
+				"sendto",
293
+				"setfsgid",
294
+				"setfsgid32",
295
+				"setfsuid",
296
+				"setfsuid32",
297
+				"setgid",
298
+				"setgid32",
299
+				"setgroups",
300
+				"setgroups32",
301
+				"setitimer",
302
+				"setpgid",
303
+				"setpriority",
304
+				"setregid",
305
+				"setregid32",
306
+				"setresgid",
307
+				"setresgid32",
308
+				"setresuid",
309
+				"setresuid32",
310
+				"setreuid",
311
+				"setreuid32",
312
+				"setrlimit",
313
+				"set_robust_list",
314
+				"setsid",
315
+				"setsockopt",
316
+				"set_thread_area",
317
+				"set_tid_address",
318
+				"setuid",
319
+				"setuid32",
320
+				"setxattr",
321
+				"shmat",
322
+				"shmctl",
323
+				"shmdt",
324
+				"shmget",
325
+				"shutdown",
326
+				"sigaltstack",
327
+				"signalfd",
328
+				"signalfd4",
329
+				"sigprocmask",
330
+				"sigreturn",
331
+				"socket",
332
+				"socketcall",
333
+				"socketpair",
334
+				"splice",
335
+				"stat",
336
+				"stat64",
337
+				"statfs",
338
+				"statfs64",
339
+				"statx",
340
+				"symlink",
341
+				"symlinkat",
342
+				"sync",
343
+				"sync_file_range",
344
+				"syncfs",
345
+				"sysinfo",
346
+				"tee",
347
+				"tgkill",
348
+				"time",
349
+				"timer_create",
350
+				"timer_delete",
351
+				"timer_getoverrun",
352
+				"timer_gettime",
353
+				"timer_gettime64",
354
+				"timer_settime",
355
+				"timer_settime64",
356
+				"timerfd_create",
357
+				"timerfd_gettime",
358
+				"timerfd_gettime64",
359
+				"timerfd_settime",
360
+				"timerfd_settime64",
361
+				"times",
362
+				"tkill",
363
+				"truncate",
364
+				"truncate64",
365
+				"ugetrlimit",
366
+				"umask",
367
+				"uname",
368
+				"unlink",
369
+				"unlinkat",
370
+				"utime",
371
+				"utimensat",
372
+				"utimensat_time64",
373
+				"utimes",
374
+				"vfork",
375
+				"vmsplice",
376
+				"wait4",
377
+				"waitid",
378
+				"waitpid",
379
+				"write",
380
+				"writev"
381
+			],
382
+			"action": "SCMP_ACT_ALLOW",
383
+			"args": [],
384
+			"comment": "",
385
+			"includes": {},
386
+			"excludes": {}
387
+		},
388
+		{
389
+			"names": [
390
+				"ptrace"
391
+			],
392
+			"action": "SCMP_ACT_ALLOW",
393
+			"args": null,
394
+			"comment": "",
395
+			"includes": {
396
+				"minKernel": "4.8"
397
+			},
398
+			"excludes": {}
399
+		},
400
+		{
401
+			"names": [
402
+				"personality"
403
+			],
404
+			"action": "SCMP_ACT_ALLOW",
405
+			"args": [
406
+				{
407
+					"index": 0,
408
+					"value": 0,
409
+					"valueTwo": 0,
410
+					"op": "SCMP_CMP_EQ"
411
+				}
412
+			],
413
+			"comment": "",
414
+			"includes": {},
415
+			"excludes": {}
416
+		},
417
+		{
418
+			"names": [
419
+				"personality"
420
+			],
421
+			"action": "SCMP_ACT_ALLOW",
422
+			"args": [
423
+				{
424
+					"index": 0,
425
+					"value": 8,
426
+					"valueTwo": 0,
427
+					"op": "SCMP_CMP_EQ"
428
+				}
429
+			],
430
+			"comment": "",
431
+			"includes": {},
432
+			"excludes": {}
433
+		},
434
+		{
435
+			"names": [
436
+				"personality"
437
+			],
438
+			"action": "SCMP_ACT_ALLOW",
439
+			"args": [
440
+				{
441
+					"index": 0,
442
+					"value": 131072,
443
+					"valueTwo": 0,
444
+					"op": "SCMP_CMP_EQ"
445
+				}
446
+			],
447
+			"comment": "",
448
+			"includes": {},
449
+			"excludes": {}
450
+		},
451
+		{
452
+			"names": [
453
+				"personality"
454
+			],
455
+			"action": "SCMP_ACT_ALLOW",
456
+			"args": [
457
+				{
458
+					"index": 0,
459
+					"value": 131080,
460
+					"valueTwo": 0,
461
+					"op": "SCMP_CMP_EQ"
462
+				}
463
+			],
464
+			"comment": "",
465
+			"includes": {},
466
+			"excludes": {}
467
+		},
468
+		{
469
+			"names": [
470
+				"personality"
471
+			],
472
+			"action": "SCMP_ACT_ALLOW",
473
+			"args": [
474
+				{
475
+					"index": 0,
476
+					"value": 4294967295,
477
+					"valueTwo": 0,
478
+					"op": "SCMP_CMP_EQ"
479
+				}
480
+			],
481
+			"comment": "",
482
+			"includes": {},
483
+			"excludes": {}
484
+		},
485
+		{
486
+			"names": [
487
+				"sync_file_range2"
488
+			],
489
+			"action": "SCMP_ACT_ALLOW",
490
+			"args": [],
491
+			"comment": "",
492
+			"includes": {
493
+				"arches": [
494
+					"ppc64le"
495
+				]
496
+			},
497
+			"excludes": {}
498
+		},
499
+		{
500
+			"names": [
501
+				"arm_fadvise64_64",
502
+				"arm_sync_file_range",
503
+				"sync_file_range2",
504
+				"breakpoint",
505
+				"cacheflush",
506
+				"set_tls"
507
+			],
508
+			"action": "SCMP_ACT_ALLOW",
509
+			"args": [],
510
+			"comment": "",
511
+			"includes": {
512
+				"arches": [
513
+					"arm",
514
+					"arm64"
515
+				]
516
+			},
517
+			"excludes": {}
518
+		},
519
+		{
520
+			"names": [
521
+				"arch_prctl"
522
+			],
523
+			"action": "SCMP_ACT_ALLOW",
524
+			"args": [],
525
+			"comment": "",
526
+			"includes": {
527
+				"arches": [
528
+					"amd64",
529
+					"x32"
530
+				]
531
+			},
532
+			"excludes": {}
533
+		},
534
+		{
535
+			"names": [
536
+				"modify_ldt"
537
+			],
538
+			"action": "SCMP_ACT_ALLOW",
539
+			"args": [],
540
+			"comment": "",
541
+			"includes": {
542
+				"arches": [
543
+					"amd64",
544
+					"x32",
545
+					"x86"
546
+				]
547
+			},
548
+			"excludes": {}
549
+		},
550
+		{
551
+			"names": [
552
+				"s390_pci_mmio_read",
553
+				"s390_pci_mmio_write",
554
+				"s390_runtime_instr"
555
+			],
556
+			"action": "SCMP_ACT_ALLOW",
557
+			"args": [],
558
+			"comment": "",
559
+			"includes": {
560
+				"arches": [
561
+					"s390",
562
+					"s390x"
563
+				]
564
+			},
565
+			"excludes": {}
566
+		},
567
+		{
568
+			"names": [
569
+				"open_by_handle_at"
570
+			],
571
+			"action": "SCMP_ACT_ALLOW",
572
+			"args": [],
573
+			"comment": "",
574
+			"includes": {
575
+				"caps": [
576
+					"CAP_DAC_READ_SEARCH"
577
+				]
578
+			},
579
+			"excludes": {}
580
+		},
581
+		{
582
+			"names": [
583
+				"bpf",
584
+				"clone",
585
+				"fanotify_init",
586
+				"lookup_dcookie",
587
+				"mount",
588
+				"name_to_handle_at",
589
+				"perf_event_open",
590
+				"quotactl",
591
+				"setdomainname",
592
+				"sethostname",
593
+				"setns",
594
+				"syslog",
595
+				"umount",
596
+				"umount2",
597
+				"unshare"
598
+			],
599
+			"action": "SCMP_ACT_ALLOW",
600
+			"args": [],
601
+			"comment": "",
602
+			"includes": {
603
+				"caps": [
604
+					"CAP_SYS_ADMIN"
605
+				]
606
+			},
607
+			"excludes": {}
608
+		},
609
+		{
610
+			"names": [
611
+				"clone"
612
+			],
613
+			"action": "SCMP_ACT_ALLOW",
614
+			"args": [
615
+				{
616
+					"index": 0,
617
+					"value": 2080505856,
618
+					"valueTwo": 0,
619
+					"op": "SCMP_CMP_MASKED_EQ"
620
+				}
621
+			],
622
+			"comment": "",
623
+			"includes": {},
624
+			"excludes": {
625
+				"caps": [
626
+					"CAP_SYS_ADMIN"
627
+				],
628
+				"arches": [
629
+					"s390",
630
+					"s390x"
631
+				]
632
+			}
633
+		},
634
+		{
635
+			"names": [
636
+				"clone"
637
+			],
638
+			"action": "SCMP_ACT_ALLOW",
639
+			"args": [
640
+				{
641
+					"index": 1,
642
+					"value": 2080505856,
643
+					"valueTwo": 0,
644
+					"op": "SCMP_CMP_MASKED_EQ"
645
+				}
646
+			],
647
+			"comment": "s390 parameter ordering for clone is different",
648
+			"includes": {
649
+				"arches": [
650
+					"s390",
651
+					"s390x"
652
+				]
653
+			},
654
+			"excludes": {
655
+				"caps": [
656
+					"CAP_SYS_ADMIN"
657
+				]
658
+			}
659
+		},
660
+		{
661
+			"names": [
662
+				"reboot"
663
+			],
664
+			"action": "SCMP_ACT_ALLOW",
665
+			"args": [],
666
+			"comment": "",
667
+			"includes": {
668
+				"caps": [
669
+					"CAP_SYS_BOOT"
670
+				]
671
+			},
672
+			"excludes": {}
673
+		},
674
+		{
675
+			"names": [
676
+				"chroot"
677
+			],
678
+			"action": "SCMP_ACT_ALLOW",
679
+			"args": [],
680
+			"comment": "",
681
+			"includes": {
682
+				"caps": [
683
+					"CAP_SYS_CHROOT"
684
+				]
685
+			},
686
+			"excludes": {}
687
+		},
688
+		{
689
+			"names": [
690
+				"delete_module",
691
+				"init_module",
692
+				"finit_module",
693
+				"query_module"
694
+			],
695
+			"action": "SCMP_ACT_ALLOW",
696
+			"args": [],
697
+			"comment": "",
698
+			"includes": {
699
+				"caps": [
700
+					"CAP_SYS_MODULE"
701
+				]
702
+			},
703
+			"excludes": {}
704
+		},
705
+		{
706
+			"names": [
707
+				"acct"
708
+			],
709
+			"action": "SCMP_ACT_ALLOW",
710
+			"args": [],
711
+			"comment": "",
712
+			"includes": {
713
+				"caps": [
714
+					"CAP_SYS_PACCT"
715
+				]
716
+			},
717
+			"excludes": {}
718
+		},
719
+		{
720
+			"names": [
721
+				"kcmp",
722
+				"process_vm_readv",
723
+				"process_vm_writev",
724
+				"ptrace"
725
+			],
726
+			"action": "SCMP_ACT_ALLOW",
727
+			"args": [],
728
+			"comment": "",
729
+			"includes": {
730
+				"caps": [
731
+					"CAP_SYS_PTRACE"
732
+				]
733
+			},
734
+			"excludes": {}
735
+		},
736
+		{
737
+			"names": [
738
+				"iopl",
739
+				"ioperm"
740
+			],
741
+			"action": "SCMP_ACT_ALLOW",
742
+			"args": [],
743
+			"comment": "",
744
+			"includes": {
745
+				"caps": [
746
+					"CAP_SYS_RAWIO"
747
+				]
748
+			},
749
+			"excludes": {}
750
+		},
751
+		{
752
+			"names": [
753
+				"settimeofday",
754
+				"stime",
755
+				"clock_settime"
756
+			],
757
+			"action": "SCMP_ACT_ALLOW",
758
+			"args": [],
759
+			"comment": "",
760
+			"includes": {
761
+				"caps": [
762
+					"CAP_SYS_TIME"
763
+				]
764
+			},
765
+			"excludes": {}
766
+		},
767
+		{
768
+			"names": [
769
+				"vhangup"
770
+			],
771
+			"action": "SCMP_ACT_ALLOW",
772
+			"args": [],
773
+			"comment": "",
774
+			"includes": {
775
+				"caps": [
776
+					"CAP_SYS_TTY_CONFIG"
777
+				]
778
+			},
779
+			"excludes": {}
780
+		},
781
+		{
782
+			"names": [
783
+				"get_mempolicy",
784
+				"mbind",
785
+				"set_mempolicy"
786
+			],
787
+			"action": "SCMP_ACT_ALLOW",
788
+			"args": [],
789
+			"comment": "",
790
+			"includes": {
791
+				"caps": [
792
+					"CAP_SYS_NICE"
793
+				]
794
+			},
795
+			"excludes": {}
796
+		},
797
+		{
798
+			"names": [
799
+				"syslog"
800
+			],
801
+			"action": "SCMP_ACT_ALLOW",
802
+			"args": [],
803
+			"comment": "",
804
+			"includes": {
805
+				"caps": [
806
+					"CAP_SYSLOG"
807
+				]
808
+			},
809
+			"excludes": {}
810
+		}
811
+	]
812
+}
0 813
\ No newline at end of file
1 814
new file mode 100755
... ...
@@ -0,0 +1,27 @@
0
+{
1
+    "defaultAction": "SCMP_ACT_ERRNO",
2
+    "syscalls": [
3
+        {
4
+            "name": "clone",
5
+            "action": "SCMP_ACT_ALLOW",
6
+            "args": [
7
+                {
8
+                    "index": 0,
9
+                    "value": 2080505856,
10
+                    "valueTwo": 0,
11
+                    "op": "SCMP_CMP_MASKED_EQ"
12
+                }
13
+            ]
14
+        },
15
+        {
16
+            "name": "open",
17
+            "action": "SCMP_ACT_ALLOW",
18
+            "args": []
19
+        },
20
+        {
21
+            "name": "close",
22
+            "action": "SCMP_ACT_ALLOW",
23
+            "args": []
24
+        }
25
+    ]
26
+}
0 27
new file mode 100644
... ...
@@ -0,0 +1,39 @@
0
+// +build linux
1
+
2
+package oci
3
+
4
+import (
5
+	"encoding/json"
6
+	"io/ioutil"
7
+	"testing"
8
+
9
+	"github.com/docker/docker/profiles/seccomp"
10
+)
11
+
12
+func TestSeccompLoadProfile(t *testing.T) {
13
+	profiles := []string{"default.json", "default-old-format.json", "example.json"}
14
+
15
+	for _, p := range profiles {
16
+		t.Run(p, func(t *testing.T) {
17
+			f, err := ioutil.ReadFile("fixtures/" + p)
18
+			if err != nil {
19
+				t.Fatal(err)
20
+			}
21
+			rs := DefaultLinuxSpec()
22
+			if _, err := seccomp.LoadProfile(string(f), &rs); err != nil {
23
+				t.Fatal(err)
24
+			}
25
+		})
26
+	}
27
+}
28
+
29
+func TestSeccompLoadDefaultProfile(t *testing.T) {
30
+	b, err := json.Marshal(seccomp.DefaultProfile())
31
+	if err != nil {
32
+		t.Fatal(err)
33
+	}
34
+	rs := DefaultLinuxSpec()
35
+	if _, err := seccomp.LoadProfile(string(b), &rs); err != nil {
36
+		t.Fatal(err)
37
+	}
38
+}
0 39
new file mode 100644
... ...
@@ -0,0 +1,23 @@
0
+{
1
+  "defaultAction": "SCMP_ACT_ERRNO",
2
+  "syscalls": [
3
+    {
4
+      "names": ["chmod"],
5
+      "action": "SCMP_ACT_ALLOW"
6
+    },
7
+    {
8
+      "names": ["syslog"],
9
+      "action": "SCMP_ACT_ALLOW",
10
+      "includes": {
11
+        "caps": ["CAP_SYSLOG"]
12
+      }
13
+    },
14
+    {
15
+      "names": ["ptrace"],
16
+      "action": "SCMP_ACT_ALLOW",
17
+      "excludes": {
18
+        "caps": ["CAP_SYS_ADMIN"]
19
+      }
20
+    }
21
+  ]
22
+}
... ...
@@ -6,7 +6,7 @@ import (
6 6
 	"io/ioutil"
7 7
 	"testing"
8 8
 
9
-	"github.com/docker/docker/oci"
9
+	"github.com/opencontainers/runtime-spec/specs-go"
10 10
 )
11 11
 
12 12
 func TestLoadProfile(t *testing.T) {
... ...
@@ -14,7 +14,7 @@ func TestLoadProfile(t *testing.T) {
14 14
 	if err != nil {
15 15
 		t.Fatal(err)
16 16
 	}
17
-	rs := oci.DefaultSpec()
17
+	rs := createSpec()
18 18
 	if _, err := LoadProfile(string(f), &rs); err != nil {
19 19
 		t.Fatal(err)
20 20
 	}
... ...
@@ -27,7 +27,7 @@ func TestLoadLegacyProfile(t *testing.T) {
27 27
 	if err != nil {
28 28
 		t.Fatal(err)
29 29
 	}
30
-	rs := oci.DefaultSpec()
30
+	rs := createSpec()
31 31
 	if _, err := LoadProfile(string(f), &rs); err != nil {
32 32
 		t.Fatal(err)
33 33
 	}
... ...
@@ -38,8 +38,56 @@ func TestLoadDefaultProfile(t *testing.T) {
38 38
 	if err != nil {
39 39
 		t.Fatal(err)
40 40
 	}
41
-	rs := oci.DefaultSpec()
41
+	rs := createSpec()
42 42
 	if _, err := LoadProfile(string(f), &rs); err != nil {
43 43
 		t.Fatal(err)
44 44
 	}
45 45
 }
46
+
47
+func TestLoadConditional(t *testing.T) {
48
+	f, err := ioutil.ReadFile("fixtures/conditional_include.json")
49
+	if err != nil {
50
+		t.Fatal(err)
51
+	}
52
+	tests := []struct {
53
+		doc      string
54
+		cap      string
55
+		expected []string
56
+	}{
57
+		{doc: "no caps", expected: []string{"chmod", "ptrace"}},
58
+		{doc: "with syslog", cap: "CAP_SYSLOG", expected: []string{"chmod", "syslog", "ptrace"}},
59
+		{doc: "no ptrace", cap: "CAP_SYS_ADMIN", expected: []string{"chmod"}},
60
+	}
61
+
62
+	for _, tc := range tests {
63
+		tc := tc
64
+		t.Run(tc.doc, func(t *testing.T) {
65
+			rs := createSpec(tc.cap)
66
+			p, err := LoadProfile(string(f), &rs)
67
+			if err != nil {
68
+				t.Fatal(err)
69
+			}
70
+			if len(p.Syscalls) != len(tc.expected) {
71
+				t.Fatalf("expected %d syscalls in profile, have %d", len(tc.expected), len(p.Syscalls))
72
+			}
73
+			for i, v := range p.Syscalls {
74
+				if v.Names[0] != tc.expected[i] {
75
+					t.Fatalf("expected %s syscall, have %s", tc.expected[i], v.Names[0])
76
+				}
77
+			}
78
+		})
79
+	}
80
+}
81
+
82
+// createSpec() creates a minimum spec for testing
83
+func createSpec(caps ...string) specs.Spec {
84
+	rs := specs.Spec{
85
+		Process: &specs.Process{
86
+			Capabilities: &specs.LinuxCapabilities{},
87
+		},
88
+	}
89
+	if caps != nil {
90
+		rs.Process.Capabilities.Bounding = append(rs.Process.Capabilities.Bounding, caps...)
91
+	}
92
+	return rs
93
+}