Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(windows-client): clear Firezone-specific DNS rules at startup #4918

Merged
merged 32 commits into from
May 13, 2024
Merged
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
e742f80
proof of concept for installing a system service with WiX
ReactorScram May 7, 2024
c83174f
this one gets the service to run, but it doesn't respond, so Windows …
ReactorScram May 7, 2024
6d36d31
Merge remote-tracking branch 'origin/main' into chore/windows-service…
ReactorScram May 7, 2024
abc9953
fmt
ReactorScram May 7, 2024
e615f93
this one starts and stops properly
ReactorScram May 7, 2024
b8a8670
fix Linux build
ReactorScram May 7, 2024
4011ca3
Merge remote-tracking branch 'origin/main' into chore/windows-service…
ReactorScram May 7, 2024
618c941
refactor(gui-client): move `known_dirs` module into `headless-client`
ReactorScram May 7, 2024
442e01c
fix Linux build
ReactorScram May 7, 2024
7e17b56
Merge branch 'refactor/move-known-dirs' into chore/windows-service-poc
ReactorScram May 8, 2024
8585e2d
Merge branch 'chore/windows-service-poc' of github.com:firezone/firez…
ReactorScram May 8, 2024
679a9da
DRY log dirs
ReactorScram May 8, 2024
606469f
typo
ReactorScram May 8, 2024
12edbc1
fix logging
ReactorScram May 8, 2024
0c77e34
fix stopping, remove debug file
ReactorScram May 8, 2024
9bc5d5c
opt in to receive shutdown signals
ReactorScram May 8, 2024
6083819
do a test install of the MSI
ReactorScram May 8, 2024
83f807d
fix(windows-client): clear Firezone-specific DNS rules at startup
ReactorScram May 8, 2024
0a35424
/passive wasn't working in CI
ReactorScram May 8, 2024
d5f58a6
try to fix CI
ReactorScram May 8, 2024
900737b
you gotta escape those deadly forward slashes
ReactorScram May 8, 2024
0f9de54
fix test checklist
ReactorScram May 8, 2024
c654e35
Merge branch 'chore/windows-service-poc' into fix/windows-dns-4899
ReactorScram May 8, 2024
470eb1c
Merge remote-tracking branch 'origin/main' into chore/windows-service…
ReactorScram May 9, 2024
ed5ee6a
Merge branch 'chore/windows-service-poc' into fix/windows-dns-4899
ReactorScram May 9, 2024
91b2c10
Merge branch 'main' into chore/windows-service-poc
ReactorScram May 9, 2024
dc9eb42
Merge branch 'chore/windows-service-poc' into fix/windows-dns-4899
ReactorScram May 9, 2024
0a7e678
remove unimplemented fn
ReactorScram May 10, 2024
9be70e2
feedback from review
ReactorScram May 10, 2024
733afa0
Merge branch 'main' into chore/windows-service-poc
ReactorScram May 10, 2024
19a03c2
Merge branch 'chore/windows-service-poc' into fix/windows-dns-4899
ReactorScram May 10, 2024
e7cc5a1
Merge remote-tracking branch 'origin/main' into fix/windows-dns-4899
ReactorScram May 13, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 7 additions & 1 deletion rust/headless-client/src/imp_windows.rs
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,10 @@ fn fallible_windows_service_run() -> Result<()> {
}
};

// Fixes <https://github.com/firezone/firezone/issues/4899>,
// DNS rules persisting after reboot
connlib_shared::deactivate_dns_control().ok();

// Tell Windows that we're running (equivalent to sd_notify in systemd)
let status_handle = service_control_handler::register(SERVICE_NAME, event_handler)?;
status_handle.set_service_status(ServiceStatus {
Expand All @@ -134,7 +138,9 @@ fn fallible_windows_service_run() -> Result<()> {
process_id: None,
})?;

run_ipc_service(cli, rt, shutdown_rx)?;
if let Err(error) = run_ipc_service(cli, rt, shutdown_rx) {
tracing::error!(?error, "error from run_ipc_service");
}

// Tell Windows that we're stopping
status_handle.set_service_status(ServiceStatus {
Expand Down