pub struct MapResolver {
pub resolved: BTreeMap<String, String>,
pub pins: BTreeMap<String, String>,
}Expand description
In-memory resolver for tests and conformance fixtures.
Fields§
§resolved: BTreeMap<String, String>Program name → path it resolves to on the search path.
pins: BTreeMap<String, String>Program name → path recorded at install time.
Trait Implementations§
Source§impl Clone for MapResolver
impl Clone for MapResolver
Source§impl Debug for MapResolver
impl Debug for MapResolver
Source§impl Default for MapResolver
impl Default for MapResolver
Source§impl ProgramResolver for MapResolver
impl ProgramResolver for MapResolver
Source§fn resolve(&self, program: &str) -> Option<String>
fn resolve(&self, program: &str) -> Option<String>
Absolute path
program would run from, or None if it is not found.Source§fn pinned(&self, program: &str) -> Option<String>
fn pinned(&self, program: &str) -> Option<String>
Path recorded for
program when the kernel was installed, if any.Source§fn own_binaries(&self) -> Vec<String>
fn own_binaries(&self) -> Vec<String>
Where OpenMoat’s own binary and its alias are installed. A command
whose program word reaches one of these files, through a link under
another name or on the search path, is decided as
openmoat too, so
the rules that keep OpenMoat’s person-only commands from an agent see
it. By default the pins of openmoat and moat.Auto Trait Implementations§
impl Freeze for MapResolver
impl RefUnwindSafe for MapResolver
impl Send for MapResolver
impl Sync for MapResolver
impl Unpin for MapResolver
impl UnsafeUnpin for MapResolver
impl UnwindSafe for MapResolver
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more