pub enum Request {
ProcessExec {
id: Uuid,
command: Vec<String>,
env: HashMap<String, String>,
cwd: Option<PathBuf>,
stdin: Option<Bytes>,
timeout: Option<u64>,
},
FileGet {
id: Uuid,
path: PathBuf,
range: Option<(u64, u64)>,
},
FilePut {
id: Uuid,
path: PathBuf,
content: Bytes,
mode: Option<u32>,
create_dirs: bool,
},
DirList {
id: Uuid,
path: PathBuf,
include_hidden: bool,
recursive: bool,
},
WasmExec {
id: Uuid,
module: Bytes,
input: Bytes,
timeout: Option<u64>,
},
JsonCall {
id: Uuid,
method: String,
params: Bytes,
},
Ping {
id: Uuid,
timestamp: u64,
},
PtyExec {
id: Uuid,
command: Vec<String>,
env: HashMap<String, String>,
cwd: Option<PathBuf>,
privilege: Option<PrivilegeEscalation>,
timeout: Option<u64>,
},
}Expand description
Request message types
Variants§
ProcessExec
Process execution request
Fields
FileGet
File get operation
Fields
FilePut
File put operation
Fields
DirList
Directory listing
Fields
Include hidden files
WasmExec
WASM module execution
Fields
JsonCall
JSON RPC call
Ping
Ping request for health checking
PtyExec
PTY process execution with privilege escalation
Implementations§
Source§impl Request
impl Request
Sourcepub fn process_exec(
command: Vec<String>,
env: HashMap<String, String>,
cwd: Option<PathBuf>,
stdin: Option<Bytes>,
timeout: Option<u64>,
) -> Self
pub fn process_exec( command: Vec<String>, env: HashMap<String, String>, cwd: Option<PathBuf>, stdin: Option<Bytes>, timeout: Option<u64>, ) -> Self
Create a process execution request
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Request
impl<'de> Deserialize<'de> for Request
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl !Freeze for Request
impl RefUnwindSafe for Request
impl Send for Request
impl Sync for Request
impl Unpin for Request
impl UnwindSafe for Request
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