Expand description
Scripted taint-gate rules: load ~/.config/leviath/rules/*.rhai and build the
ScriptRuleChecker the runtime’s taint gate consults after the static
allowlist. The daemon owns the Rhai engine (leviath-runtime has no scripting
dependency), so the checker is installed as a world resource.
Functions§
- build_
gate_ script_ checker - Build a
ScriptRuleCheckerfrom every*.rhaifile inrules_dir. When the directory is absent/unreadable or holds no rule scripts, a no-op checker (that never allows anything) is returned, so the daemon can install it unconditionally. Each script receives acontextmap (tool/target/taint_level) and should evaluate totrueto allow the call; the first script that allows wins and its file stem is the rule name.