Skip to content

Commit

Permalink
Use world writeable paths (#750)
Browse files Browse the repository at this point in the history
  • Loading branch information
hulto authored Apr 18, 2024
1 parent c1061c7 commit 7a68572
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions implants/imix/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -215,8 +215,14 @@ fn get_host_id_path() -> String {
#[cfg(target_os = "windows")]
return String::from("C:\\ProgramData\\system-id");

#[cfg(not(target_os = "windows"))]
return String::from("/etc/system-id");
#[cfg(target_os = "linux")]
return String::from("/var/run/lock/system-id");

#[cfg(target_os = "macos")]
return String::from("/Users/Shared/system-id");

#[cfg(target_os = "freebsd")]
return String::from("/var/run/systemd-id");
}

/*
Expand Down

0 comments on commit 7a68572

Please sign in to comment.