From d67c8e9a04003751dbfcaf3b77f48c77811e05ce Mon Sep 17 00:00:00 2001 From: Alexandr Stelnykovych Date: Tue, 2 Sep 2025 18:24:50 +0300 Subject: [PATCH] fix: Ensure intel data for the main SPN map is initialized before Portmaster starts an SPN connection MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Related Issue Details: In some situations, SPN intel data was not fully applied. This lead to Portmaster making connections that don’t align with the intended intel preferences. https://github.com/safing/portmaster/issues/1999 https://github.com/safing/portmaster-shadow/issues/35 --- spn/captain/module.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/spn/captain/module.go b/spn/captain/module.go index c5279c4d..c2d698ee 100644 --- a/spn/captain/module.go +++ b/spn/captain/module.go @@ -135,8 +135,9 @@ func start() error { crew.EnableConnecting(publicIdentity.Hub) } - // Initialize intel. - module.mgr.Go("start", func(wc *mgr.WorkerCtx) error { + // Initialize SPN intel. + // Do this synchronously to ensure everything is up to date before + module.mgr.Do("start", func(wc *mgr.WorkerCtx) error { if err := registerIntelUpdateHook(); err != nil { return err }