portmaster
portmaster copied to clipboard
Bug: DNSMonitor module crash on stop
OS: Windows
When the DNSMonitor module stops, it occasionally crashes, causing the whole application to terminate.
2025-11-11 14:20:41.815 ERR tor/module:053 > 009 dnsmonitor: failed to close listener: DestroySession failed: failed with status code: 7007
Exception 0xc0000005 0x0 0xffffffffffffffff 0x7ffa912f1155
PC=0x7ffa912f1155
runtime.cgocall(0x6786a0, 0xc00008f360)
C:/Program Files/Go/src/runtime/cgocall.go:167 +0x3e fp=0xc005acf038 sp=0xc005acefd0 pc=0x66c05e
runtime.syscall_syscalln(0x0?, 0x300000002?, {0xc001267088?, 0xc0012670e8?, 0x66f8a5?})
C:/Program Files/Go/src/runtime/syscall_windows.go:521 +0x69 fp=0xc005acf060 sp=0xc005acf038 pc=0x65a429
syscall.Syscall(0xc000efc820?, 0x0?, 0xc0012670e8?, 0x66f4bf?, 0x66c05e?)
C:/Program Files/Go/src/runtime/syscall_windows.go:457 +0x29 fp=0xc005acf0b0 sp=0xc005acf060 pc=0x672ea9
golang.org/x/sys/windows.(*Proc).Call(0xc000efc820, {0xc005ab0340, 0x1, 0x1})
C:/Users/stenya/go/pkg/mod/golang.org/x/[email protected]/windows/dll_windows.go:170 +0x1cf fp=0xc005acf7b8 sp=0xc005acf0b0 pc=0xc4efaf
github.com/safing/portmaster/service/integration.ETWFunctions.StartTrace({0xc000efc7e0, 0xc000efc800, 0xc000efc820, 0xc000efc840, 0xc000efc860, 0xc000efc880, 0xc000efc8a0}, 0x1fe05c6bef0)
D:/Projects/Portmaster/portmaster/service/integration/etw_windows.go:82 +0x1f3 fp=0xc005acf920 sp=0xc005acf7b8 pc=0x18dc213
github.com/safing/portmaster/service/firewall/interception/dnsmonitor.(*ETWSession).StartTrace(0xc00255a540)
D:/Projects/Portmaster/portmaster/service/firewall/interception/dnsmonitor/etwlink_windows.go:65 +0x138 fp=0xc005acfa20 sp=0xc005acf920 pc=0x18df438
github.com/safing/portmaster/service/firewall/interception/dnsmonitor.initializeSessions.func1(0xc005ab60a0)
D:/Projects/Portmaster/portmaster/service/firewall/interception/dnsmonitor/eventlistener_windows.go:51 +0x36 fp=0xc005acfa68 sp=0xc005acfa20 pc=0x18e0156
github.com/safing/portmaster/service/mgr.(*Manager).runWorker(0xc00027f650, 0xc005ab60a0, 0xc000e00e80)
D:/Projects/Portmaster/portmaster/service/mgr/worker.go:354 +0x282 fp=0xc005acfb88 sp=0xc005acfa68 pc=0xe26ec2
github.com/safing/portmaster/service/mgr.(*Manager).manageWorker(0xc00027f650, {0x1e52bf8, 0x16}, 0xc000e00e80)
D:/Projects/Portmaster/portmaster/service/mgr/worker.go:188 +0x3cb fp=0xc005acff90 sp=0xc005acfb88 pc=0xe2552b
github.com/safing/portmaster/service/mgr.(*Manager).Go.gowrap1()
D:/Projects/Portmaster/portmaster/service/mgr/worker.go:170 +0x4f fp=0xc005acffe0 sp=0xc005acff90 pc=0xe2512f
runtime.goexit({})
C:/Program Files/Go/src/runtime/asm_amd64.s:1700 +0x1 fp=0xc005acffe8 sp=0xc005acffe0 pc=0x676e41
created by github.com/safing/portmaster/service/mgr.(*Manager).Go in goroutine 111
D:/Projects/Portmaster/portmaster/service/mgr/worker.go:170 +0x107