mirror of
https://github.com/yuezk/GlobalProtect-openconnect.git
synced 2026-11-19 14:36:15 -05:00
feat: build and publish Windows NSH packages with verified updates
This commit is contained in:
113 files changed
+7264
-801
No files matched your search
@@ -15,5 +15,7 @@ serde.workspace = true
|
||||
serde_json.workspace = true
|
||||
serde_urlencoded.workspace = true
|
||||
uuid = { workspace = true, features = ["v5"] }
|
||||
uzers.workspace = true
|
||||
xmltree.workspace = true
|
||||
|
||||
[target.'cfg(unix)'.dependencies]
|
||||
uzers.workspace = true
|
||||
@@ -570,11 +570,14 @@ fn detect_ufw(commands: &CollectorCommands<'_>) -> io::Result<Option<UfwInfo>> {
|
||||
let Some(ufw) = commands.resolve("ufw") else {
|
||||
return Ok(None);
|
||||
};
|
||||
#[cfg(unix)]
|
||||
let output = if uzers::get_effective_uid() == 0 {
|
||||
commands.run_path(&ufw, &["status"])?
|
||||
} else {
|
||||
commands.run("sudo", &["-n", &ufw.to_string_lossy(), "status"])?
|
||||
};
|
||||
#[cfg(windows)]
|
||||
let output = commands.run_path(&ufw, &["status"])?;
|
||||
let Some(output) = output.filter(|output| output.status.success()) else {
|
||||
return Ok(None);
|
||||
};
|
||||
|
||||
Reference in new issue
Block a user