Filename | /root/tor-browser-build/projects/common/runc-config.json |
Statements | Executed 417 statements in 4.07ms |
Calls | P | F | Exclusive Time |
Inclusive Time |
Subroutine |
---|---|---|---|---|---|
15 | 1 | 1 | 2.72ms | 1.01s | __ANON__[:263] | Template::Document::
Line | State ments |
Time on line |
Calls | Time in subs |
Code |
---|---|---|---|---|---|
1 | # spent 1.01s (2.72ms+1.01) within Template::Document::__ANON__[/root/tor-browser-build/projects/common/runc-config.json:263] which was called 15 times, avg 67.5ms/call:
# 15 times (2.72ms+1.01s) by Template::Document::process at line 163 of Template/Document.pm, avg 67.5ms/call | ||||
2 | 15 | 460µs | 30 | 1.86s | if (! $stash->get(['c', [ 'var_p/runc_spec100' ]])) { # spent 932ms making 15 calls to Template::Stash::XS::get, avg 62.2ms/call
# spent 932ms making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:640], avg 62.1ms/call |
3 | $output .= "-rc1"; | ||||
4 | } | ||||
5 | |||||
6 | 15 | 166µs | $output .= "\",\n \"platform\": {\n \"os\": \"linux\",\n \"arch\": \"amd64\"\n },\n \"process\": {\n \"terminal\": "; | ||
7 | 15 | 9µs | #line 8 "/root/tor-browser-build/projects/common/runc-config.json" | ||
8 | 30 | 299µs | 45 | 1.12ms | if ($stash->get(['c', [ 'interactive' ]])) { # spent 741µs making 15 calls to Template::Stash::XS::get, avg 49µs/call
# spent 346µs making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:640], avg 23µs/call
# spent 34µs making 15 calls to Template::Stash::undefined, avg 2µs/call |
9 | $output .= "true"; | ||||
10 | } | ||||
11 | else { | ||||
12 | 15 | 11µs | $output .= "false"; | ||
13 | } | ||||
14 | |||||
15 | 15 | 15µs | $output .= ",\n \"user\": {\n \"uid\": 0,\n \"gid\": 0\n },\n \"args\": [\n \"/rbm/run\"\n ],\n \"env\": [\n \"PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin\",\n \"TERM=xterm\"\n ],\n \"cwd\": \"/\",\n"; | ||
16 | #line 121 "/root/tor-browser-build/projects/common/runc-config.json" | ||||
17 | if ($stash->get(['c', [ 'var_p/runc_spec100' ]])) { | ||||
18 | $output .= " \"capabilities\": {\n \"bounding\": [\n \"CAP_AUDIT_WRITE\",\n \"CAP_KILL\",\n \"CAP_NET_BIND_SERVICE\",\n \"CAP_SETGID\",\n \"CAP_SETUID\",\n \"CAP_MKNOD\",\n \"CAP_SYS_CHROOT\",\n"; | ||||
19 | #line 33 "/root/tor-browser-build/projects/common/runc-config.json" | ||||
20 | if ($stash->get(['c', [ 'var/container/CAP_SYS_ADMIN' ]])) { | ||||
21 | $output .= " \"CAP_SYS_ADMIN\",\n"; | ||||
22 | } | ||||
23 | |||||
24 | $output .= " \"CAP_FSETID\",\n \"CAP_FOWNER\",\n \"CAP_DAC_OVERRIDE\",\n \"CAP_CHOWN\"\n ],\n \"effective\": [\n \"CAP_AUDIT_WRITE\",\n \"CAP_KILL\",\n \"CAP_NET_BIND_SERVICE\",\n \"CAP_SETGID\",\n \"CAP_SETUID\",\n \"CAP_MKNOD\",\n \"CAP_SYS_CHROOT\",\n"; | ||||
25 | #line 49 "/root/tor-browser-build/projects/common/runc-config.json" | ||||
26 | if ($stash->get(['c', [ 'var/container/CAP_SYS_ADMIN' ]])) { | ||||
27 | $output .= " \"CAP_SYS_ADMIN\",\n"; | ||||
28 | } | ||||
29 | |||||
30 | $output .= " \"CAP_FSETID\",\n \"CAP_FOWNER\",\n \"CAP_DAC_OVERRIDE\",\n \"CAP_CHOWN\"\n ],\n \"inheritable\": [\n \"CAP_AUDIT_WRITE\",\n \"CAP_KILL\",\n \"CAP_NET_BIND_SERVICE\",\n \"CAP_SETGID\",\n \"CAP_SETUID\",\n \"CAP_MKNOD\",\n \"CAP_SYS_CHROOT\",\n"; | ||||
31 | #line 65 "/root/tor-browser-build/projects/common/runc-config.json" | ||||
32 | if ($stash->get(['c', [ 'var/container/CAP_SYS_ADMIN' ]])) { | ||||
33 | 15 | 254µs | 45 | 41.7ms | $output .= " \"CAP_SYS_ADMIN\",\n"; # spent 21.0ms making 15 calls to Template::Stash::XS::get, avg 1.40ms/call
# spent 20.7ms making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:640], avg 1.38ms/call
# spent 36µs making 15 calls to Template::Stash::undefined, avg 2µs/call |
34 | } | ||||
35 | |||||
36 | $output .= " \"CAP_FSETID\",\n \"CAP_FOWNER\",\n \"CAP_DAC_OVERRIDE\",\n \"CAP_CHOWN\"\n ],\n \"permitted\": [\n \"CAP_AUDIT_WRITE\",\n \"CAP_KILL\",\n \"CAP_NET_BIND_SERVICE\",\n \"CAP_SETGID\",\n \"CAP_SETUID\",\n \"CAP_MKNOD\",\n \"CAP_SYS_CHROOT\",\n"; | ||||
37 | 15 | 31µs | #line 81 "/root/tor-browser-build/projects/common/runc-config.json" | ||
38 | if ($stash->get(['c', [ 'var/container/CAP_SYS_ADMIN' ]])) { | ||||
39 | $output .= " \"CAP_SYS_ADMIN\",\n"; | ||||
40 | } | ||||
41 | |||||
42 | $output .= " \"CAP_FSETID\",\n \"CAP_FOWNER\",\n \"CAP_DAC_OVERRIDE\",\n \"CAP_CHOWN\"\n ],\n \"ambient\": [\n \"CAP_AUDIT_WRITE\",\n \"CAP_KILL\",\n \"CAP_NET_BIND_SERVICE\",\n \"CAP_SETGID\",\n \"CAP_SETUID\",\n \"CAP_MKNOD\",\n \"CAP_SYS_CHROOT\",\n"; | ||||
43 | #line 97 "/root/tor-browser-build/projects/common/runc-config.json" | ||||
44 | if ($stash->get(['c', [ 'var/container/CAP_SYS_ADMIN' ]])) { | ||||
45 | $output .= " \"CAP_SYS_ADMIN\",\n"; | ||||
46 | } | ||||
47 | |||||
48 | $output .= " \"CAP_FSETID\",\n \"CAP_FOWNER\",\n \"CAP_DAC_OVERRIDE\",\n \"CAP_CHOWN\"\n ]\n },\n"; | ||||
49 | 15 | 234µs | 45 | 792µs | } # spent 563µs making 15 calls to Template::Stash::XS::get, avg 38µs/call
# spent 210µs making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:640], avg 14µs/call
# spent 20µs making 15 calls to Template::Stash::undefined, avg 1µs/call |
50 | else { | ||||
51 | $output .= " \"capabilities\": [\n \"CAP_AUDIT_WRITE\",\n \"CAP_KILL\",\n \"CAP_NET_BIND_SERVICE\",\n \"CAP_SETGID\",\n \"CAP_SETUID\",\n \"CAP_MKNOD\",\n \"CAP_SYS_CHROOT\",\n"; | ||||
52 | #line 115 "/root/tor-browser-build/projects/common/runc-config.json" | ||||
53 | 15 | 16µs | if ($stash->get(['c', [ 'var/container/CAP_SYS_ADMIN' ]])) { | ||
54 | $output .= " \"CAP_SYS_ADMIN\",\n"; | ||||
55 | } | ||||
56 | |||||
57 | $output .= " \"CAP_FSETID\",\n \"CAP_FOWNER\",\n \"CAP_DAC_OVERRIDE\",\n \"CAP_CHOWN\"\n ],\n"; | ||||
58 | } | ||||
59 | |||||
60 | $output .= " \"noNewPrivileges\": true\n },\n \"root\": {\n \"path\": \"rootfs\",\n \"readonly\": false\n },\n \"hostname\": \"runc\",\n \"mounts\": [\n {\n \"destination\": \"/proc\",\n \"type\": \"proc\",\n \"source\": \"proc\"\n },\n {\n \"type\": \"bind\",\n \"source\": \"/etc/resolv.conf\",\n \"destination\": \"/etc/resolv.conf\",\n \"options\": [\n \"rbind\",\n \"ro\"\n ]\n },\n {\n \"destination\": \"/dev\",\n \"type\": \"tmpfs\",\n \"source\": \"tmpfs\",\n \"options\": [\n \"nosuid\",\n \"strictatime\",\n \"mode=755\",\n \"size=65536k\"\n ]\n },\n {\n \"destination\": \"/dev/pts\",\n \"type\": \"devpts\",\n \"source\": \"devpts\",\n \"options\": [\n \"nosuid\",\n \"noexec\",\n \"newinstance\",\n \"ptmxmode=0666\",\n \"mode=0620\",\n \"gid=5\"\n ]\n },\n {\n \"destination\": \"/dev/shm\",\n \"type\": \"tmpfs\",\n \"source\": \"shm\",\n \"options\": [\n \"nosuid\",\n \"noexec\",\n \"nodev\",\n \"mode=1777\",\n \"size=65536k\"\n ]\n },\n {\n \"destination\": \"/dev/mqueue\",\n \"type\": \"mqueue\",\n \"source\": \"mqueue\",\n \"options\": [\n \"nosuid\",\n \"noexec\",\n \"nodev\"\n ]\n },\n {\n \"destination\": \"/sys\",\n \"type\": \"sysfs\",\n \"source\": \"sysfs\",\n \"options\": [\n \"nosuid\",\n \"noexec\",\n \"nodev\",\n \"ro\"\n ]\n },\n {\n \"destination\": \"/sys/fs/cgroup\",\n \"type\": \"cgroup\",\n \"source\": \"cgroup\",\n \"options\": [\n \"nosuid\",\n \"noexec\",\n \"nodev\",\n \"relatime\",\n \"ro\"\n ]\n }\n ],\n \"hooks\": {},\n \"linux\": {\n \"resources\": {\n \"devices\": [\n {\n \"allow\": false,\n \"access\": \"rwm\"\n }\n ]\n },\n \"namespaces\": [\n {\n \"type\": \"pid\"\n },\n {\n \"type\": \"ipc\"\n },\n {\n \"type\": \"uts\"\n },\n"; | ||||
61 | #line 239 "/root/tor-browser-build/projects/common/runc-config.json" | ||||
62 | if ($stash->get(['c', [ 'var/container/disable_network/' . $stash->get(['c', [ 'exec_name' ]]) ]])) { | ||||
63 | $output .= " {\n \"type\": \"network\",\n \"path\": \"/var/run/netns/rbm-"; | ||||
64 | #line 237 "/root/tor-browser-build/projects/common/runc-config.json" | ||||
65 | 15 | 215µs | 45 | 519µs | $output .= $stash->get(['sha256', [ $stash->get(['c', [ 'build_id', { 'error_if_undef' => 1 } ]]) ]]); # spent 363µs making 15 calls to Template::Stash::XS::get, avg 24µs/call
# spent 138µs making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:640], avg 9µs/call
# spent 18µs making 15 calls to Template::Stash::undefined, avg 1µs/call |
66 | $output .= "\"\n },\n"; | ||||
67 | } | ||||
68 | |||||
69 | 15 | 82µs | $output .= " {\n \"type\": \"mount\"\n }\n ],\n \"maskedPaths\": [\n \"/proc/kcore\",\n \"/proc/latency_stats\",\n \"/proc/timer_stats\",\n"; | ||
70 | #line 251 "/root/tor-browser-build/projects/common/runc-config.json" | ||||
71 | if ($stash->get(['c', [ 'var_p/runc_spec100' ]])) { | ||||
72 | $output .= " \"/proc/timer_list\",\n \"/sys/firmware\",\n"; | ||||
73 | } | ||||
74 | |||||
75 | $output .= " \"/proc/sched_debug\"\n ],\n \"readonlyPaths\": [\n \"/proc/asound\",\n \"/proc/bus\",\n \"/proc/fs\",\n \"/proc/irq\",\n \"/proc/sys\",\n \"/proc/sysrq-trigger\"\n ]\n },\n \"solaris\": {\n \"cappedCPU\": {},\n \"cappedMemory\": {}\n }\n}\n"; | ||||
76 | } }; | ||||
77 | if ($@) { | ||||
78 | $_tt_error = $context->catch($@, \$output); | ||||
79 | die $_tt_error unless $_tt_error->type eq 'return'; | ||||
80 | } | ||||
81 | 15 | 237µs | 45 | 564µs | # spent 380µs making 15 calls to Template::Stash::XS::get, avg 25µs/call
# spent 166µs making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:640], avg 11µs/call
# spent 17µs making 15 calls to Template::Stash::undefined, avg 1µs/call |
82 | return $output; | ||||
83 | } | ||||
84 | |||||
85 | 15 | 15µs | |||
- - | |||||
97 | 15 | 187µs | 45 | 518µs | # spent 369µs making 15 calls to Template::Stash::XS::get, avg 25µs/call
# spent 132µs making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:640], avg 9µs/call
# spent 17µs making 15 calls to Template::Stash::undefined, avg 1µs/call |
- - | |||||
101 | 15 | 26µs | |||
- - | |||||
121 | 15 | 227µs | 30 | 459µs | # spent 302µs making 15 calls to Template::Stash::XS::get, avg 20µs/call
# spent 157µs making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:640], avg 10µs/call |
122 | 30 | 38µs | |||
- - | |||||
237 | 4 | 107µs | 16 | 858µs | # spent 468µs making 8 calls to Template::Stash::XS::get, avg 59µs/call
# spent 326µs making 4 calls to RBM::__ANON__[rbm/lib/RBM.pm:655], avg 81µs/call
# spent 64µs making 4 calls to RBM::__ANON__[rbm/lib/RBM.pm:640], avg 16µs/call |
238 | 4 | 2µs | |||
239 | 15 | 469µs | 74 | 104ms | # spent 52.2ms making 30 calls to Template::Stash::XS::get, avg 1.74ms/call
# spent 51.5ms making 30 calls to RBM::__ANON__[rbm/lib/RBM.pm:640], avg 1.72ms/call
# spent 200µs making 14 calls to Template::Stash::undefined, avg 14µs/call |
240 | 4 | 16µs | |||
241 | 15 | 88µs | |||
- - | |||||
251 | 15 | 222µs | 30 | 579µs | # spent 360µs making 15 calls to Template::Stash::XS::get, avg 24µs/call
# spent 219µs making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:640], avg 15µs/call |
- - | |||||
255 | 15 | 16µs | |||
- - | |||||
257 | 15 | 9µs | |||
- - | |||||
262 | 15 | 467µs | |||
- - | |||||
264 | 15 | 151µs |