Filename | /root/tor-browser-build/projects/common/runc-config.json |
Statements | Executed 417 statements in 3.57ms |
Calls | P | F | Exclusive Time |
Inclusive Time |
Subroutine |
---|---|---|---|---|---|
15 | 1 | 1 | 2.32ms | 1.03s | __ANON__[:263] | Template::Document::
Line | State ments |
Time on line |
Calls | Time in subs |
Code |
---|---|---|---|---|---|
1 | # spent 1.03s (2.32ms+1.03) within Template::Document::__ANON__[/root/tor-browser-build/projects/common/runc-config.json:263] which was called 15 times, avg 68.8ms/call:
# 15 times (2.32ms+1.03s) by Template::Document::process at line 163 of Template/Document.pm, avg 68.8ms/call | ||||
2 | 15 | 477µs | 30 | 1.90s | if (! $stash->get(['c', [ 'var_p/runc_spec100' ]])) { # spent 949ms making 15 calls to Template::Stash::XS::get, avg 63.3ms/call
# spent 949ms making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:652], avg 63.3ms/call |
3 | $output .= "-rc1"; | ||||
4 | } | ||||
5 | |||||
6 | 15 | 32µs | $output .= "\",\n \"platform\": {\n \"os\": \"linux\",\n \"arch\": \"amd64\"\n },\n \"process\": {\n \"terminal\": "; | ||
7 | 15 | 10µs | #line 8 "/root/tor-browser-build/projects/common/runc-config.json" | ||
8 | 30 | 274µs | 45 | 1.09ms | if ($stash->get(['c', [ 'interactive' ]])) { # spent 697µs making 15 calls to Template::Stash::XS::get, avg 46µs/call
# spent 369µs making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:652], avg 25µs/call
# spent 28µs making 15 calls to Template::Stash::undefined, avg 2µs/call |
9 | $output .= "true"; | ||||
10 | } | ||||
11 | else { | ||||
12 | 15 | 16µs | $output .= "false"; | ||
13 | } | ||||
14 | |||||
15 | 15 | 16µ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 | 252µs | 45 | 42.2ms | $output .= " \"CAP_SYS_ADMIN\",\n"; # spent 21.2ms making 15 calls to Template::Stash::XS::get, avg 1.41ms/call
# spent 20.9ms making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:652], avg 1.40ms/call
# spent 28µ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 | 32µ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 | 322µs | 45 | 694µs | } # spent 470µs making 15 calls to Template::Stash::XS::get, avg 31µs/call
# spent 204µs making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:652], avg 14µs/call
# spent 19µ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 | 14µ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 | 207µs | 45 | 548µs | $output .= $stash->get(['sha256', [ $stash->get(['c', [ 'build_id', { 'error_if_undef' => 1 } ]]) ]]); # spent 387µs making 15 calls to Template::Stash::XS::get, avg 26µs/call
# spent 142µs making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:652], 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 | 72µ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 | 242µs | 45 | 499µs | # spent 347µs making 15 calls to Template::Stash::XS::get, avg 23µs/call
# spent 134µs making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:652], avg 9µs/call
# spent 17µs making 15 calls to Template::Stash::undefined, avg 1µs/call |
82 | return $output; | ||||
83 | } | ||||
84 | |||||
85 | 15 | 18µs | |||
- - | |||||
97 | 15 | 177µs | 45 | 458µs | # spent 307µs making 15 calls to Template::Stash::XS::get, avg 20µs/call
# spent 133µs making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:652], avg 9µs/call
# spent 17µs making 15 calls to Template::Stash::undefined, avg 1µs/call |
- - | |||||
101 | 15 | 19µs | |||
- - | |||||
121 | 15 | 201µs | 30 | 546µs | # spent 342µs making 15 calls to Template::Stash::XS::get, avg 23µs/call
# spent 203µs making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:652], avg 14µs/call |
122 | 30 | 38µs | |||
- - | |||||
237 | 4 | 109µs | 16 | 1.05ms | # spent 563µs making 8 calls to Template::Stash::XS::get, avg 70µs/call
# spent 422µs making 4 calls to RBM::__ANON__[rbm/lib/RBM.pm:667], avg 105µs/call
# spent 66µs making 4 calls to RBM::__ANON__[rbm/lib/RBM.pm:652], avg 17µs/call |
238 | 4 | 1µs | |||
239 | 15 | 448µs | 74 | 111ms | # spent 55.9ms making 30 calls to Template::Stash::XS::get, avg 1.86ms/call
# spent 55.3ms making 30 calls to RBM::__ANON__[rbm/lib/RBM.pm:652], avg 1.84ms/call
# spent 33µs making 14 calls to Template::Stash::undefined, avg 2µs/call |
240 | 4 | 10µs | |||
241 | 15 | 79µs | |||
- - | |||||
251 | 15 | 195µs | 30 | 591µs | # spent 384µs making 15 calls to Template::Stash::XS::get, avg 26µs/call
# spent 208µs making 15 calls to RBM::__ANON__[rbm/lib/RBM.pm:652], avg 14µs/call |
- - | |||||
255 | 15 | 16µs | |||
- - | |||||
257 | 15 | 10µs | |||
- - | |||||
262 | 15 | 175µs | |||
- - | |||||
264 | 15 | 109µs |