mirror of
https://github.com/cirruslabs/softnet.git
synced 2026-10-18 22:50:16 +02:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
22c92688e5 | ||
|
|
e2403f0ea9 | ||
|
|
717e6b0f89 | ||
|
|
71465f8bff |
@@ -20,12 +20,12 @@ And assumes that:
|
|||||||
|
|
||||||
## Installing
|
## Installing
|
||||||
|
|
||||||
For proper functioning Softnet binary requires two things:
|
For proper functioning, Softnet binary requires two things:
|
||||||
|
|
||||||
* a [SUID-bit](https://en.wikipedia.org/wiki/Setuid#SUID) is set on the binary or [passwordless sudo](https://serverfault.com/questions/160581/how-to-setup-passwordless-sudo-on-linux) is enabled, which effectively gives the binary `root` privileges
|
* a [SUID-bit](https://en.wikipedia.org/wiki/Setuid#SUID) to be set on the binary or a [passwordless sudo](https://serverfault.com/questions/160581/how-to-setup-passwordless-sudo-on-linux) to be configured, which effectively gives the binary `root` privileges
|
||||||
* this is needed in order to create [`vmnet.framework`](https://developer.apple.com/documentation/vmnet) interface and perform DHCP-related tweaks
|
* these privileges are needed to create [`vmnet.framework`](https://developer.apple.com/documentation/vmnet) interface and perform DHCP-related system tweaks
|
||||||
* the privileges will be dropped automatically to that of the calling user (or those represented by the `--user` and `--group` command-line arguments) once all of the initialization is completed
|
* the privileges will be dropped automatically to that of the calling user (or those represented by the `--user` and `--group` command-line arguments) once all of the initialization is completed
|
||||||
* the binary is available in `PATH`
|
* the binary to be available in `PATH`
|
||||||
* so that the Tart will be able to find it
|
* so that the Tart will be able to find it
|
||||||
|
|
||||||
## Running
|
## Running
|
||||||
|
|||||||
+1
-1
@@ -107,7 +107,7 @@ impl Host {
|
|||||||
.map_err(|err| Error::VmnetFailed { source: err })?;
|
.map_err(|err| Error::VmnetFailed { source: err })?;
|
||||||
|
|
||||||
// Now let the callback finish
|
// Now let the callback finish
|
||||||
self.callback_can_continue_tx.send(()).unwrap();
|
let _ = self.callback_can_continue_tx.send(());
|
||||||
|
|
||||||
self.interface
|
self.interface
|
||||||
.finalize()
|
.finalize()
|
||||||
|
|||||||
+3
-1
@@ -12,7 +12,9 @@ impl Proxy {
|
|||||||
|
|
||||||
// Snoop bootpd(8) replies from the host to
|
// Snoop bootpd(8) replies from the host to
|
||||||
// figure out the IP assigned to the VM
|
// figure out the IP assigned to the VM
|
||||||
self.snoop(frame);
|
if frame.dst_addr() == self.vm_mac_address {
|
||||||
|
self.snoop(frame);
|
||||||
|
}
|
||||||
|
|
||||||
self.vm
|
self.vm
|
||||||
.write(frame.as_ref())
|
.write(frame.as_ref())
|
||||||
|
|||||||
+1
-1
@@ -27,7 +27,7 @@ struct Args {
|
|||||||
#[clap(
|
#[clap(
|
||||||
long,
|
long,
|
||||||
help = "set bootpd(8) lease time to this value (in seconds) before starting the VM",
|
help = "set bootpd(8) lease time to this value (in seconds) before starting the VM",
|
||||||
default_value_t = 60
|
default_value_t = 600
|
||||||
)]
|
)]
|
||||||
bootpd_lease_time: u32,
|
bootpd_lease_time: u32,
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user