fix: more cleaning up for FreeBSD
This commit is contained in:
@@ -10,6 +10,7 @@ pub fn print_capabilities(capabilities: &Capabilities, ip: &IpAddr) {
|
||||
"\tOperating system: \t{}",
|
||||
match &capabilities.operating_system {
|
||||
OperatingSystem::Linux => "Linux",
|
||||
OperatingSystem::FreeBSD => "FreeBSD",
|
||||
OperatingSystem::Windows => "Windows",
|
||||
}
|
||||
);
|
||||
@@ -57,7 +58,7 @@ pub fn print_capabilities(capabilities: &Capabilities, ip: &IpAddr) {
|
||||
}
|
||||
);
|
||||
}
|
||||
OperatingSystem::Windows => {
|
||||
OperatingSystem::Windows | OperatingSystem::FreeBSD => {
|
||||
println!(
|
||||
"\tAdmin user: \t\t{}",
|
||||
match capabilities.root {
|
||||
|
||||
@@ -26,6 +26,7 @@ impl std::str::FromStr for TargetOs {
|
||||
fn from_str(input: &str) -> Result<Self, Self::Err> {
|
||||
match input {
|
||||
"linux" => Ok(Self::Linux),
|
||||
"freebsd" => Ok(Self::FreeBSD),
|
||||
"windows" => Ok(Self::Windows),
|
||||
"windows-service" => Ok(Self::WindowsService),
|
||||
_ => Err("could not parse target operating system"),
|
||||
|
||||
Reference in New Issue
Block a user