Commit graph

77 commits

Author SHA1 Message Date
Alexandr Stelnykovych
b9a9129e81 Merge branch 'feature/sqlite-db-v1' into develop 2025-03-25 17:08:32 +02:00
Daniel
be133b8856 Improve filterlist ingestion logging 2025-03-17 15:43:59 +01:00
Alexandr Stelnykovych
32c7f6e7d1 Merge branch 'feature/sqlite-db-v1' into develop 2025-03-17 16:31:48 +02:00
Daniel
c0d8d0c2f0 Add new PurgeOlderThan interface method to SQLite Database 2025-03-10 10:34:57 +01:00
Daniel
67cfefde9b Fix tests 2025-03-04 17:05:03 +01:00
Daniel
b8ab348095 Fix tests and linters 2025-03-04 15:25:44 +01:00
Daniel
b68646c689 Use transaction for PutMany and cursor Query 2025-02-26 16:52:34 +01:00
Daniel
130c4a427c Fix timing on database root path initialization 2025-02-26 13:25:55 +01:00
Daniel
76c352da5a Make test parallel 2025-02-26 13:21:51 +01:00
Daniel
83292d761c Fix domain list generation within public suffix 2025-02-26 13:13:28 +01:00
Daniel
90ead7d5e5 Switch core and cache databases to use sqlite when bbold db is not present 2025-02-25 13:49:49 +01:00
Vladimir Stoilov
40b443282f
[service] Fix IPv6 payload layer set 2025-02-11 13:55:29 +02:00
Vladimir Stoilov
0f28af66cd
Add PID in ETW DNS event in the integration dll ()
* [service] Add reading of PID in ETW DNS event

* [service] Use PID of the ETW DNS events

* [service] Fix use of nil pointer

* [service] Fix compiler error
2025-01-27 17:21:54 +02:00
Daniel Hååvi
b4fda1bdce
Merge pull request from stenya/fix_logical_mistake
[fix] Logical mistake while determining local resolvers
2025-01-13 13:45:11 +01:00
Daniel Hååvi
0937bedd6c
Merge pull request from stenya/fix_crash_SleepyTicker
[fix] Panic while accessing SleepyTicker methods Stop()/SetSleep()
2025-01-13 13:44:59 +01:00
Daniel Hååvi
241bf20c7a
Merge pull request from stenya/intel_small_cache
[improvement] Small cache size
2025-01-13 13:44:31 +01:00
Alexandr Stelnykovych
6c014d227c [fix] Panic while accessing SleepyTicker methods Stop()/SetSleep()
The time.Ticker object was stored as a value type, but it is expected to be a pointer according to its implementation:
```
func (t *Ticker) Stop()
func (t *Ticker) Reset(d Duration)
```

This was leading to an application crash.

STR 1:
Run `portmaster-core` without privileged rights. It will not be able to start the kernel driver (Windows).
During unloading of already initialized modules, the process crashes because of stopping SleepyTicker instances in workers of the "network" module.

STR 2:
Run tests from `service\mgr\sleepyticker_test.go`
2024-12-17 15:49:52 +02:00
Alexandr Stelnykovych
df70c70ab5 [improvement] Small cache size
(2 ^ 8) = (2 XOR 8) = 10.
Was it intended to be 256?
2024-12-16 16:01:42 +02:00
Alexandr Stelnykovych
692838b696 [fix] Logical mistake while determining local resolvers 2024-12-13 17:02:38 +02:00
Vladimir Stoilov
05a5d5e350
[service] Fix unit tests 2024-12-06 14:47:24 +02:00
Vladimir Stoilov
22253c4e9e
[service] Fix windows permissions 2024-12-06 12:00:20 +02:00
Vladimir Stoilov
ed2338fdb9
[service] Fix error on unitilized dns monitor 2024-12-02 15:25:58 +02:00
Vladimir Stoilov
2a9d75433f
[service] Fix module failure when dll is missing 2024-12-02 14:02:49 +02:00
Daniel
ef0995b1f7 Define identifier for portmaster-core.dll and make it mandatory 2024-11-28 11:45:29 +01:00
Daniel
614d8972a2 Improve logging 2024-11-27 16:37:59 +01:00
Vladimir Stoilov
1a1bc14804
Feature/systemd query events ()
* [service] Subscribe to systemd-resolver events

* [service] Add disabled state to the resolver

* [service] Add ETW DNS event listener

* [service] DNS listener refactoring

* [service] Add windows core dll project

* [service] DNSListener refactoring, small bugfixes

* [service] Change dns bypass rule

* [service] Update gitignore

* [service] Remove shim from integration module

* [service] Add DNS packet analyzer

* [service] Add self-check in dns monitor

* [service] Fix go linter errors

* [CI] Add github workflow for the windows core dll

* [service] Minor fixes to the dns monitor
2024-11-27 17:10:47 +02:00
Vladimir Stoilov
943b9b7859
Fix file permissions on windows ()
* [service] Set file permissions on windows

* [service] Fix minor windows permission bugs

* [service] Fix permission bugs

* [service] Fix windows non admin user start
2024-11-26 17:00:01 +02:00
Daniel
f4b96e1ce7 Make saving IP and CNAMEs more defensive 2024-11-12 15:13:44 +01:00
Daniel
07acb9befa Notify packet issues asynchronously 2024-11-12 15:11:07 +01:00
Daniel
a99b68ec91 Warn instead of failing when process username cannot be found 2024-11-12 15:10:41 +01:00
Daniel
57e81fb6fb [service] Make linter happy 2024-08-28 11:55:40 +02:00
Daniel
4b2e4f208f [service] Run event callbacks asynchronously 2024-08-28 11:55:32 +02:00
Daniel
de4cb5b34f [service] Submit state clear event outside of lock 2024-08-28 11:55:01 +02:00
Daniel
c6ddaf8e1e [service] Fix startup race condition 2024-08-28 11:52:45 +02:00
Daniel
7f0b5ca149 [service] Fix starting and stopping of SPN 2024-08-27 16:42:22 +02:00
Daniel
57f08eccd7 [service] Add worker info system 2024-08-27 16:32:23 +02:00
Daniel
2fd7c61acb Fix and improve start order 2024-08-23 10:18:33 +02:00
Daniel
b6b07296ae [service] Do not warn when custom filter lists are not configured 2024-08-23 10:18:26 +02:00
Daniel
4d5bbe42bd [service] Deactivate android interface code for now 2024-08-21 15:00:52 +02:00
Daniel Hååvi
80664d1a27
Restructure modules ()
* Move portbase into monorepo

* Add new simple module mgr

* [WIP] Switch to new simple module mgr

* Add StateMgr and more worker variants

* [WIP] Switch more modules

* [WIP] Switch more modules

* [WIP] swtich more modules

* [WIP] switch all SPN modules

* [WIP] switch all service modules

* [WIP] Convert all workers to the new module system

* [WIP] add new task system to module manager

* [WIP] Add second take for scheduling workers

* [WIP] Add FIXME for bugs in new scheduler

* [WIP] Add minor improvements to scheduler

* [WIP] Add new worker scheduler

* [WIP] Fix more bug related to new module system

* [WIP] Fix start handing of the new module system

* [WIP] Improve startup process

* [WIP] Fix minor issues

* [WIP] Fix missing subsystem in settings

* [WIP] Initialize managers in constructor

* [WIP] Move module event initialization to constrictors

* [WIP] Fix setting for enabling and disabling the SPN module

* [WIP] Move API registeration into module construction

* [WIP] Update states mgr for all modules

* [WIP] Add CmdLine operation support

* Add state helper methods to module group and instance

* Add notification and module status handling to status package

* Fix starting issues

* Remove pilot widget and update security lock to new status data

* Remove debug logs

* Improve http server shutdown

* Add workaround for cleanly shutting down firewall+netquery

* Improve logging

* Add syncing states with notifications for new module system

* Improve starting, stopping, shutdown; resolve FIXMEs/TODOs

* [WIP] Fix most unit tests

* Review new module system and fix minor issues

* Push shutdown and restart events again via API

* Set sleep mode via interface

* Update example/template module

* [WIP] Fix spn/cabin unit test

* Remove deprecated UI elements

* Make log output more similar for the logging transition phase

* Switch spn hub and observer cmds to new module system

* Fix log sources

* Make worker mgr less error prone

* Fix tests and minor issues

* Fix observation hub

* Improve shutdown and restart handling

* Split up big connection.go source file

* Move varint and dsd packages to structures repo

* Improve expansion test

* Fix linter warnings

* Fix interception module on windows

* Fix linter errors

---------

Co-authored-by: Vladimir Stoilov <vladimir@safing.io>
2024-08-09 18:15:48 +03:00
Daniel Hååvi
5ec32d102e
Merge pull request from safing/feature/link-local-resolvesr
Add option to ignore DNS server if out-of-network
2024-07-19 16:12:27 +02:00
Vladimir Stoilov
c868598deb
[cmds] Move new UI to a zip for windows 2024-07-16 11:26:20 +03:00
Vladimir Stoilov
0b72e99edd [cmds] Allow running of tauri in beta 2024-07-08 09:22:11 +03:00
Daniel
42e725921b Add option to DNS server to ignore them when they are not available via an interface network 2024-07-03 17:17:51 +02:00
Vladimir Stoilov
2e3304809f [windows_kext] Fix minor problems 2024-07-01 15:06:54 +03:00
Vladimir Stoilov
b1d168e06d [service] Improve kext verdict translation 2024-06-28 13:29:35 +03:00
Vladimir Stoilov
4bf1736a83 [service] Add check for kext command size 2024-06-28 13:20:18 +03:00
Vladimir Stoilov
176494550e [service] Fix kext verdict of update command 2024-06-27 16:39:31 +03:00
Daniel
7e4e4c47a8 [service] Always put ICMP in the Other Connections group instead of Network Noise 2024-05-28 16:32:55 +02:00
Daniel
274f81e4eb Update go deps 2024-05-28 15:57:38 +02:00