def ex.bound

bend-osdev-caps@0.1.0.0 · PROOF.bend:755

import bend-osdev-caps@0.1.0.0/PROOF.bend as PROOF
import Base
import bend-osdev-caps@0.1.0.0/caps.bend as C
import bend-osdev-caps@0.1.0.0/exec.bend as E

755def ex.bound(+fl: E.CapExecFlags, +s: C.CapState) -> {C.CapSet.subset(C.CapState.permitted(E.CapExec.sets(fl, s)), C.CapSet.union(C.CapState.bounding(s), C.CapSet.union(C.CapState.inheritable(s), C.CapState.ambient(s)))) == True{} : Bool}:
756  match fl s:
757    case E.CapExecFlags{True{}, feff, +fp, +fi} C.CapState{+p, +i, +e, +b, +a}:
758      set.bound_z(i, fi, fp, b, a)
759    case E.CapExecFlags{False{}, feff, +fp, +fi} C.CapState{+p, +i, +e, +b, +a}:
760      set.bound_a(i, fi, fp, b, a)

Uses (12)

Used by (1)