From 4919630cccbdfab0be57d42c79bcbe0575172f2c Mon Sep 17 00:00:00 2001 From: Stanislav Chzhen Date: Thu, 3 Oct 2024 18:47:28 +0300 Subject: [PATCH 1/3] Pull request 2288: upd-chlog Squashed commit of the following: commit f064da09e4fa644c085b4e21f18bb27c65549b92 Author: Ainar Garipov Date: Thu Oct 3 18:33:58 2024 +0300 all: imp chlog more commit 662ba0f56995e9f955446b134f7c71e9d4d59ccd Author: Stanislav Chzhen Date: Thu Oct 3 18:25:09 2024 +0300 all: upd chlog --- CHANGELOG.md | 40 +++++++++++++++++++++++----------------- 1 file changed, 23 insertions(+), 17 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5802f32e..d6e3a093 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,20 +16,28 @@ TODO(a.garipov): Use the common markdown formatting tools. ## [Unreleased] + + + + +## [v0.107.53] - 2024-10-03 + +See also the [v0.107.53 GitHub milestone][ms-v0.107.53]. + ### Security -- Previous versions of AdGuard Home allowed users to add any system it had +- Previous versions of AdGuard Home allowed users to add any system file it had access to as filters, exposing them to be world-readable. To prevent this, AdGuard Home now allows adding filtering-rule list files only from files matching the patterns enumerated in the `filtering.safe_fs_patterns` property @@ -69,8 +77,8 @@ In this release, the schema version has changed from 28 to 29. - Property `clients.runtime_sources.dhcp` in the configuration file not taking effect. -- Update Google safe search domains list ([#7155]). -- Enforce Bing safe search from Edge sidebar ([#7154]). +- Stale Google safe search domains list ([#7155]). +- Bing safe search from Edge sidebar ([#7154]). - Text overflow on the query log page ([#7119]). ### Known issues @@ -83,7 +91,7 @@ In this release, the schema version has changed from 28 to 29. to more restrictive ones manually. To do that: 1. Locate the `AdGuardHome` directory. - 2. Right-click on it and navigate to *Properties → Security → Advanced*. + 2. Right-click on it and navigate to *Properties → Security → Advanced.* 3. (You might need to disable permission inheritance to make them more restricted.) 4. Adjust to give the `Full control` access to only the user which runs @@ -95,11 +103,8 @@ In this release, the schema version has changed from 28 to 29. [#7154]: https://github.com/AdguardTeam/AdGuardHome/pull/7154 [#7155]: https://github.com/AdguardTeam/AdGuardHome/pull/7155 -[go-1.23.2]: https://groups.google.com/g/golang-announce/c/NKEc8VT7Fz0 - - +[go-1.23.2]: https://groups.google.com/g/golang-announce/c/NKEc8VT7Fz0 +[ms-v0.107.53]: https://github.com/AdguardTeam/AdGuardHome/milestone/88?closed=1 @@ -3137,11 +3142,12 @@ See also the [v0.104.2 GitHub milestone][ms-v0.104.2]. -[Unreleased]: https://github.com/AdguardTeam/AdGuardHome/compare/v0.107.52...HEAD +[Unreleased]: https://github.com/AdguardTeam/AdGuardHome/compare/v0.107.53...HEAD +[v0.107.53]: https://github.com/AdguardTeam/AdGuardHome/compare/v0.107.52...v0.107.53 [v0.107.52]: https://github.com/AdguardTeam/AdGuardHome/compare/v0.107.51...v0.107.52 [v0.107.51]: https://github.com/AdguardTeam/AdGuardHome/compare/v0.107.50...v0.107.51 [v0.107.50]: https://github.com/AdguardTeam/AdGuardHome/compare/v0.107.49...v0.107.50 From df097341c3f643ef4c2d67a5ae2158ddfe707b03 Mon Sep 17 00:00:00 2001 From: Stanislav Chzhen Date: Fri, 4 Oct 2024 18:10:56 +0300 Subject: [PATCH 2/3] Pull request 2287: 7315-fix-client-storage-panic Closes #7315. Squashed commit of the following: commit 94c8473a14d98b45b5086de432bc68dd55eb654b Author: Stanislav Chzhen Date: Thu Oct 3 19:09:23 2024 +0300 all: upd chlog commit 82b772b1dde19277832d44f9b22c47d22f90bf7e Merge: e7f34cc43 4919630cc Author: Stanislav Chzhen Date: Thu Oct 3 19:00:53 2024 +0300 Merge branch 'master' into 7315-fix-client-storage-panic commit e7f34cc435f53b80aca328a62e27c6aaa8fe6462 Author: Stanislav Chzhen Date: Thu Oct 3 17:55:39 2024 +0300 home: fix client storage panic --- CHANGELOG.md | 7 +++++++ internal/home/clients.go | 6 +++--- internal/home/home.go | 16 ++++++++-------- 3 files changed, 18 insertions(+), 11 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d6e3a093..70133cb9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -25,6 +25,13 @@ See also the [v0.107.54 GitHub milestone][ms-v0.107.54]. NOTE: Add new changes BELOW THIS COMMENT. --> +### Fixed + +- Missing runtime clients with information from the system hosts file on first + AdGuard Home start ([#7315]). + +[#7315]: https://github.com/AdguardTeam/AdGuardHome/issues/7315 + diff --git a/internal/home/clients.go b/internal/home/clients.go index 5a30d6bc..eef52834 100644 --- a/internal/home/clients.go +++ b/internal/home/clients.go @@ -92,9 +92,9 @@ func (clients *clientsContainer) Init( // TODO(e.burkov): The option should probably be returned, since hosts file // currently used not only for clients' information enrichment, but also in // the filtering module and upstream addresses resolution. - var hosts client.HostsContainer = etcHosts - if !config.Clients.Sources.HostsFile { - hosts = nil + var hosts client.HostsContainer + if config.Clients.Sources.HostsFile && etcHosts != nil { + hosts = etcHosts } clients.storage, err = client.NewStorage(&client.StorageConfig{ diff --git a/internal/home/home.go b/internal/home/home.go index df4e4296..56718394 100644 --- a/internal/home/home.go +++ b/internal/home/home.go @@ -148,6 +148,14 @@ func setupContext(opts options) (err error) { Context.tlsRoots = aghtls.SystemRootCAs() Context.mux = http.NewServeMux() + if !opts.noEtcHosts { + err = setupHostsContainer() + if err != nil { + // Don't wrap the error, because it's informative enough as is. + return err + } + } + if Context.firstRun { log.Info("This is the first time AdGuard Home is launched") checkPermissions() @@ -168,14 +176,6 @@ func setupContext(opts options) (err error) { os.Exit(0) } - if !opts.noEtcHosts { - err = setupHostsContainer() - if err != nil { - // Don't wrap the error, because it's informative enough as is. - return err - } - } - return nil } From 2c64ab5a5105098c0d4152e2b482d84d404c2086 Mon Sep 17 00:00:00 2001 From: Stanislav Chzhen Date: Fri, 4 Oct 2024 19:10:32 +0300 Subject: [PATCH 3/3] Pull request 2289: upd-urlfilter Updates #6818. Squashed commit of the following: commit d03b518457ef14d1c565a46c1dbfce1a47bf301d Author: Stanislav Chzhen Date: Fri Oct 4 18:58:10 2024 +0300 all: upd chlog commit 80ee9146998d622c173a9559b8d6af139b750d23 Author: Stanislav Chzhen Date: Fri Oct 4 18:50:24 2024 +0300 all: upd urlfilter --- CHANGELOG.md | 5 +++++ go.mod | 21 +++++++++--------- go.sum | 40 +++++++++++++++++----------------- internal/dhcpsvc/config.go | 10 ++++----- internal/dhcpsvc/server.go | 9 ++++---- internal/home/log.go | 7 +++++- scripts/translations/upload.go | 11 ++++++---- 7 files changed, 59 insertions(+), 44 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 70133cb9..58a9f4cc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -25,11 +25,16 @@ See also the [v0.107.54 GitHub milestone][ms-v0.107.54]. NOTE: Add new changes BELOW THIS COMMENT. --> +### Changed + +- Improved filtering performance ([#6818]). + ### Fixed - Missing runtime clients with information from the system hosts file on first AdGuard Home start ([#7315]). +[#6818]: https://github.com/AdguardTeam/AdGuardHome/issues/6818 [#7315]: https://github.com/AdguardTeam/AdGuardHome/issues/7315