pub struct Trampoline {
pub enter: Option<(Arc<View>, Vec<u8>)>,
pub chdir: Option<Vec<u8>>,
pub env: Option<Vec<Vec<u8>>>,
pub new_session: bool,
pub die_with_parent: bool,
pub seccomp_programs: Vec<Vec<u8>>,
pub info_fds: Vec<i32>,
pub json_status_fds: Vec<i32>,
pub warnings: Vec<Vec<u8>>,
pub exit: Option<(i32, Vec<u8>, bool)>,
}Expand description
What the trampoline does inside the tracee before exec’ing the plan.
Fields§
§enter: Option<(Arc<View>, Vec<u8>)>The view the process enters at the real exec, with its working directory there as a guest path.
chdir: Option<Vec<u8>>Host directory to chdir to first (with ptrace, where the kernel’s
cwd is the real one).
env: Option<Vec<Vec<u8>>>Environment to exec with, replacing the inherited one.
new_session: boolsetsid before the exec.
die_with_parent: boolDie with SIGKILL when the parent dies.
seccomp_programs: Vec<Vec<u8>>Classic BPF programs (raw sock_filter bytes) to install before the exec.
info_fds: Vec<i32>Descriptors that receive {"child-pid": N} and are closed.
json_status_fds: Vec<i32>Descriptors that receive {"child-pid": N} then {"exit-code": N}:
the trampoline forks, and its parent stays to report.
warnings: Vec<Vec<u8>>Lines printed on stderr before anything else.
exit: Option<(i32, Vec<u8>, bool)>Print this and exit with the code instead of exec’ing: on stdout when the flag is set, else stderr.
Trait Implementations§
Source§impl Clone for Trampoline
impl Clone for Trampoline
Source§fn clone(&self) -> Trampoline
fn clone(&self) -> Trampoline
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more