Adjust.CapAdjust.capset.r3: def of bend-osdev-caps@0.1.0.0 Import: import bend-osdev-caps@0.1.0.0/adjust.bend as Adjust Lines 33-40 of bend-osdev-caps@0.1.0.0/adjust.bend: https://jend.leeeet.dev/read.txt?path=bend-osdev-caps@0.1.0.0/adjust.bend&start_line=33&end_line=40 import Base import bend-osdev-caps@0.1.0.0/caps.bend as C # the new inheritable set must be within the old inheritable and bounding sets def CapAdjust.capset.r3(ok: Bool, +c: C.CapCred, e: C.CapSet(), p: C.CapSet(), +i: C.CapSet()) -> Result<&2, &2, C.CapsError, C.CapCred>: match ok: case False{}: Fail{C.CapsInheritableNotBounded{}} case True{}: +s = C.CapCred.sets(c) CapAdjust.capset.r4(C.CapSet.has(C.CapState.effective(s), C.Cap.setpcap()), C.CapSet.subset(i, C.CapSet.union(C.CapState.inheritable(s), C.CapState.permitted(s))), c, e, p, i) Uses (14): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Result https://jend.leeeet.dev/definition.txt?path=bend-osdev-caps@0.1.0.0/adjust.bend&name=CapAdjust.capset.r4 https://jend.leeeet.dev/definition.txt?path=bend-osdev-caps@0.1.0.0/caps.bend&name=Cap.setpcap https://jend.leeeet.dev/definition.txt?path=bend-osdev-caps@0.1.0.0/caps.bend&name=CapCred https://jend.leeeet.dev/definition.txt?path=bend-osdev-caps@0.1.0.0/caps.bend&name=CapCred.sets https://jend.leeeet.dev/definition.txt?path=bend-osdev-caps@0.1.0.0/caps.bend&name=CapSet https://jend.leeeet.dev/definition.txt?path=bend-osdev-caps@0.1.0.0/caps.bend&name=CapSet.has https://jend.leeeet.dev/definition.txt?path=bend-osdev-caps@0.1.0.0/caps.bend&name=CapSet.subset https://jend.leeeet.dev/definition.txt?path=bend-osdev-caps@0.1.0.0/caps.bend&name=CapSet.union https://jend.leeeet.dev/definition.txt?path=bend-osdev-caps@0.1.0.0/caps.bend&name=CapState.effective https://jend.leeeet.dev/definition.txt?path=bend-osdev-caps@0.1.0.0/caps.bend&name=CapState.inheritable https://jend.leeeet.dev/definition.txt?path=bend-osdev-caps@0.1.0.0/caps.bend&name=CapState.permitted https://jend.leeeet.dev/definition.txt?path=bend-osdev-caps@0.1.0.0/caps.bend&name=CapsError