AdGuardHome/internal/home/home.go

1079 lines
27 KiB
Go
Raw Normal View History

// Package home contains AdGuard Home's HTTP API methods.
package home
2018-08-30 15:25:33 +01:00
import (
2019-04-25 12:57:03 +01:00
"context"
"crypto/tls"
"crypto/x509"
2018-08-30 15:25:33 +01:00
"fmt"
"io/fs"
2018-08-30 15:25:33 +01:00
"net"
"net/http"
"net/netip"
2020-03-12 12:11:08 +00:00
"net/url"
2018-08-30 15:25:33 +01:00
"os"
"os/signal"
2018-08-30 15:25:33 +01:00
"path/filepath"
"runtime"
"sync"
"syscall"
"time"
2018-08-30 15:25:33 +01:00
"github.com/AdguardTeam/AdGuardHome/internal/aghalg"
Pull request: 4871 imp filtering Merge in DNS/adguard-home from 4871-imp-filtering to master Closes #4871. Squashed commit of the following: commit 618e7c558447703c114332708c94ef1b34362cf9 Merge: 41ff8ab7 11e4f091 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 19:27:08 2022 +0300 Merge branch 'master' into 4871-imp-filtering commit 41ff8ab755a87170e7334dedcae00f01dcca238a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 19:26:11 2022 +0300 filtering: imp code, log commit e4ae1d1788406ffd7ef0fcc6df896a22b0c2db37 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 14:11:07 2022 +0300 filtering: move handlers into single func commit f7a340b4c10980f512ae935a156f02b0133a1627 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 21 19:21:09 2022 +0300 all: imp code commit e064bf4d3de0283e4bda2aaf5b9822bb8a08f4a6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 20:12:16 2022 +0300 all: imp name commit e7eda3905762f0821e1be1ac3cf77e0ecbedeff4 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:51:23 2022 +0300 all: finally get rid of filtering commit 188550d873e625cc2951583bb3a2eaad036745f5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:36:03 2022 +0300 filtering: merge refresh commit e54ed9c7952b17e66b790c835269b28fbc26f9ca Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:16:23 2022 +0300 filtering: merge filters commit 32da31b754a319487d5f9d5e81e607d349b90180 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 14:48:13 2022 +0300 filtering: imp docs commit 43b0cafa7a27bb9b620c2ba50ccdddcf32cfcecc Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 14:38:04 2022 +0300 all: imp code commit 253a2ea6c92815d364546e34d631e406dd604644 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 20:43:15 2022 +0300 filtering: rm important flag commit 1b87f08f946389d410f13412c7e486290d5e752d Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 17:05:40 2022 +0300 all: move filtering to the package commit daa13499f1dd4fe475c4b75769e34f1eb0915bdf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 15:13:55 2022 +0300 all: finish merging commit d6db75eb2e1f23528e9200ea51507eb793eefa3c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 16 18:18:14 2022 +0300 all: continue merging commit 45b4c484deb7198a469aa18d719bb9dbe81e5d22 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 14 15:44:22 2022 +0300 all: merge filtering types
2022-09-23 11:23:35 +01:00
"github.com/AdguardTeam/AdGuardHome/internal/aghhttp"
"github.com/AdguardTeam/AdGuardHome/internal/aghnet"
"github.com/AdguardTeam/AdGuardHome/internal/aghos"
"github.com/AdguardTeam/AdGuardHome/internal/aghtls"
"github.com/AdguardTeam/AdGuardHome/internal/dhcpd"
"github.com/AdguardTeam/AdGuardHome/internal/dnsforward"
"github.com/AdguardTeam/AdGuardHome/internal/filtering"
Pull request 1837: AG-21462-imp-safebrowsing-parental Merge in DNS/adguard-home from AG-21462-imp-safebrowsing-parental to master Squashed commit of the following: commit 85016d4f1105e21a407efade0bd45b8362808061 Merge: 0e61edade 620b51e3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 16:36:30 2023 +0300 Merge branch 'master' into AG-21462-imp-safebrowsing-parental commit 0e61edadeff34f6305e941c1db94575c82f238d9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 14:51:37 2023 +0300 filtering: imp tests commit 994255514cc0f67dfe33d5a0892432e8924d1e36 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 11:13:19 2023 +0300 filtering: fix typo commit 96d1069573171538333330d6af94ef0f4208a9c4 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 11:00:18 2023 +0300 filtering: imp code more commit c2a5620b04c4a529eea69983f1520cd2bc82ea9b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 26 19:13:26 2023 +0300 all: add todo commit e5dcc2e9701f8bccfde6ef8c01a4a2e7eb31599e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 26 14:36:08 2023 +0300 all: imp code more commit b6e734ccbeda82669023f6578481260b7c1f7161 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Apr 25 15:01:56 2023 +0300 filtering: imp code commit 530648dadf836c1a4bd9917e0d3b47256fa8ff52 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 24 20:06:36 2023 +0300 all: imp code commit 49fa6e587052a40bb431fea457701ee860493527 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 24 14:57:19 2023 +0300 all: rm safe browsing ctx commit bbcb66cb03e18fa875e3c33cf16295892739e507 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Apr 21 17:54:18 2023 +0300 filtering: add cache item commit cb7c9fffe8c4ff5e7a21ca912c223c799f61385f Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 18:43:02 2023 +0300 filtering: fix hashes commit 153fec46270212af03f3631bfb42c5d680c4e142 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 16:15:15 2023 +0300 filtering: add test cases commit 09372f92bbb1fc082f1b1283594ee589100209c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 15:38:05 2023 +0300 filtering: imp code commit 466bc26d524ea6d1c3efb33692a7785d39e491ca Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 19 18:38:40 2023 +0300 filtering: add tests commit 24365ecf8c60512fdac65833ee603c80864ae018 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 19 11:38:57 2023 +0300 filtering: add hashprefix
2023-04-27 14:39:35 +01:00
"github.com/AdguardTeam/AdGuardHome/internal/filtering/hashprefix"
Pull request: 1163 safesearch vol.2 Merge in DNS/adguard-home from 1163-safesearch-1-2-1 to master Squashed commit of the following: commit d3a5ebef35210019842145074e898129b42f1f2c Merge: b85264ae c6706445 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 15 09:17:53 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 # Conflicts: # CHANGELOG.md commit b85264aefc5f191ac6cb194b519f03ba15829a4e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 14 00:16:07 2023 +0700 home: imp code commit ac2ed7a5ce8db40628e7d4d1c8634641e5f38b0b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 23:02:06 2023 +0700 all: changelog commit f0fccafcb01f50c7051df53bbe9b02cab75aa71e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:42:36 2023 +0700 all: changelog commit 37df29bf6372939644fb28e3d70365496e0cb4f6 Merge: b227b277 595484e0 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:38:57 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit b227b2775b4866d69241ad87acf99700715552cb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:56:01 2023 +0700 all: imp docs commit 6fd39fc3565c3f4bc7a7113d17733c20dfe24d8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:55:03 2023 +0700 home: imp code commit 3bb3bb7c7dcf97b2a5602a7d2b6770c08b4d863d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 12:16:53 2023 +0700 home: imp docs commit 5f573a56a9fd9942ad677fa0fae6b24228dab653 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 11:56:47 2023 +0700 home: imp code commit 23eeb5552cf2510596b2311cc3eda53ac678ffcc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 10 10:57:33 2023 +0700 home: imp code commit 643de2fca1b5917c61fe83e1e472222404f3cd21 Merge: dada6e63 a2053526 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 21:03:08 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit dada6e63ca5324d30775e2da1727da891743f654 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 17:09:03 2023 +0700 all: imp docs commit 81a180d99dd9a995440d5f4e2ebca34678e7d0c7 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 15:12:43 2023 +0700 all: imp code commit fa84877bc777004d246d71d0a9ae0bd9ee568a91 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:53:05 2023 +0700 all: imp code commit 6d7e02e745d72921a693d4f09eec7ce21c2aefd4 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:40:02 2023 +0700 all: imp docs commit 0a4332997070fb8d2fb3a34d32b92f57a325ff06 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 7 22:00:52 2023 +0700 safesearch: fix merge commit 145c2222ba4cf7f8909b816d83829d2217c94243 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 2 11:41:48 2023 +0700 safesearch: fix merge commit 14c6a8005fe15b5d5a39f91b17c96d8670975811 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:50:09 2023 +0700 all: docs commit 2a85c8831866bf1c34c423a289461fc1e32667b5 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:47:00 2023 +0700 all: use safesearch package
2023-03-15 11:31:07 +00:00
"github.com/AdguardTeam/AdGuardHome/internal/filtering/safesearch"
"github.com/AdguardTeam/AdGuardHome/internal/querylog"
"github.com/AdguardTeam/AdGuardHome/internal/stats"
"github.com/AdguardTeam/AdGuardHome/internal/updater"
"github.com/AdguardTeam/AdGuardHome/internal/version"
Pull request 1837: AG-21462-imp-safebrowsing-parental Merge in DNS/adguard-home from AG-21462-imp-safebrowsing-parental to master Squashed commit of the following: commit 85016d4f1105e21a407efade0bd45b8362808061 Merge: 0e61edade 620b51e3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 16:36:30 2023 +0300 Merge branch 'master' into AG-21462-imp-safebrowsing-parental commit 0e61edadeff34f6305e941c1db94575c82f238d9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 14:51:37 2023 +0300 filtering: imp tests commit 994255514cc0f67dfe33d5a0892432e8924d1e36 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 11:13:19 2023 +0300 filtering: fix typo commit 96d1069573171538333330d6af94ef0f4208a9c4 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 11:00:18 2023 +0300 filtering: imp code more commit c2a5620b04c4a529eea69983f1520cd2bc82ea9b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 26 19:13:26 2023 +0300 all: add todo commit e5dcc2e9701f8bccfde6ef8c01a4a2e7eb31599e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 26 14:36:08 2023 +0300 all: imp code more commit b6e734ccbeda82669023f6578481260b7c1f7161 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Apr 25 15:01:56 2023 +0300 filtering: imp code commit 530648dadf836c1a4bd9917e0d3b47256fa8ff52 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 24 20:06:36 2023 +0300 all: imp code commit 49fa6e587052a40bb431fea457701ee860493527 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 24 14:57:19 2023 +0300 all: rm safe browsing ctx commit bbcb66cb03e18fa875e3c33cf16295892739e507 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Apr 21 17:54:18 2023 +0300 filtering: add cache item commit cb7c9fffe8c4ff5e7a21ca912c223c799f61385f Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 18:43:02 2023 +0300 filtering: fix hashes commit 153fec46270212af03f3631bfb42c5d680c4e142 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 16:15:15 2023 +0300 filtering: add test cases commit 09372f92bbb1fc082f1b1283594ee589100209c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 15:38:05 2023 +0300 filtering: imp code commit 466bc26d524ea6d1c3efb33692a7785d39e491ca Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 19 18:38:40 2023 +0300 filtering: add tests commit 24365ecf8c60512fdac65833ee603c80864ae018 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 19 11:38:57 2023 +0300 filtering: add hashprefix
2023-04-27 14:39:35 +01:00
"github.com/AdguardTeam/dnsproxy/upstream"
"github.com/AdguardTeam/golibs/errors"
"github.com/AdguardTeam/golibs/log"
"github.com/AdguardTeam/golibs/netutil"
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
"github.com/AdguardTeam/golibs/stringutil"
Pull request: 4871 imp filtering Merge in DNS/adguard-home from 4871-imp-filtering to master Closes #4871. Squashed commit of the following: commit 618e7c558447703c114332708c94ef1b34362cf9 Merge: 41ff8ab7 11e4f091 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 19:27:08 2022 +0300 Merge branch 'master' into 4871-imp-filtering commit 41ff8ab755a87170e7334dedcae00f01dcca238a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 19:26:11 2022 +0300 filtering: imp code, log commit e4ae1d1788406ffd7ef0fcc6df896a22b0c2db37 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 14:11:07 2022 +0300 filtering: move handlers into single func commit f7a340b4c10980f512ae935a156f02b0133a1627 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 21 19:21:09 2022 +0300 all: imp code commit e064bf4d3de0283e4bda2aaf5b9822bb8a08f4a6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 20:12:16 2022 +0300 all: imp name commit e7eda3905762f0821e1be1ac3cf77e0ecbedeff4 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:51:23 2022 +0300 all: finally get rid of filtering commit 188550d873e625cc2951583bb3a2eaad036745f5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:36:03 2022 +0300 filtering: merge refresh commit e54ed9c7952b17e66b790c835269b28fbc26f9ca Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:16:23 2022 +0300 filtering: merge filters commit 32da31b754a319487d5f9d5e81e607d349b90180 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 14:48:13 2022 +0300 filtering: imp docs commit 43b0cafa7a27bb9b620c2ba50ccdddcf32cfcecc Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 14:38:04 2022 +0300 all: imp code commit 253a2ea6c92815d364546e34d631e406dd604644 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 20:43:15 2022 +0300 filtering: rm important flag commit 1b87f08f946389d410f13412c7e486290d5e752d Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 17:05:40 2022 +0300 all: move filtering to the package commit daa13499f1dd4fe475c4b75769e34f1eb0915bdf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 15:13:55 2022 +0300 all: finish merging commit d6db75eb2e1f23528e9200ea51507eb793eefa3c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 16 18:18:14 2022 +0300 all: continue merging commit 45b4c484deb7198a469aa18d719bb9dbe81e5d22 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 14 15:44:22 2022 +0300 all: merge filtering types
2022-09-23 11:23:35 +01:00
"golang.org/x/exp/slices"
Pull request: return 501 when we don't support features Merge in DNS/adguard-home from 2295-dhcp-windows to master Updates #2295. Squashed commit of the following: commit 3b00a90c3d9bc33e9af478e4062c0f938d4f327d Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Nov 16 16:45:43 2020 +0300 all: use the 501 handlers instead of the real ones, revert other changes commit 0a3b37736a21abd6181e0d28c32069e8d7a576d0 Merge: 45feba755 6358240e9 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Nov 16 15:59:15 2020 +0300 Merge branch 'master' into 2295-dhcp-windows and update commit 45feba755dde37e43cc8075b896e1576157341e6 Merge: cd987d8bc a19523b25 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Nov 16 15:51:16 2020 +0300 Merge branch 'master' into 2295-dhcp-windows commit cd987d8bc2cd524b7454d9037b595069714645f9 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 15:55:23 2020 +0300 all: improve tests and refactor dhcp checking code even more commit 3aad675443f325b5909523bcc1c987aa04ac61d9 Merge: 70c477e61 09196118e Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 14:44:43 2020 +0300 Merge branch 'master' into 2295-dhcp-windows commit 70c477e61cdc1237603918f1c44470c1549f1136 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 14:34:06 2020 +0300 home: fix dhcpd test on windows commit e59597d783fb9304e63f94eee2b5a5d67a5b2169 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 13:38:25 2020 +0300 all: mention the feature in the changelog commit 5555c8d881b1c20b5b0a0cb096a17cf56e209c06 Merge: c3b6a5a93 e802e6645 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 13:35:35 2020 +0300 Merge branch 'master' into 2295-dhcp-windows commit c3b6a5a930693090838eb1ef9f75a09b5b223ba6 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Nov 12 20:37:09 2020 +0300 util: fix comment commit ed92dfdb5d3a6c4ba5d032cbe781e7fd87882813 Author: ArtemBaskal <asbaskal@miem.hse.ru> Date: Thu Nov 12 20:24:14 2020 +0300 Adapt client commit e6f0494c20a4ad5388492af9091568eea5c6e2d6 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Nov 12 13:35:25 2020 +0300 return 501 when we don't support features
2020-11-16 16:01:12 +00:00
"gopkg.in/natefinch/lumberjack.v2"
2018-08-30 15:25:33 +01:00
)
const (
// Used in config to indicate that syslog or eventlog (win) should be used for logger output
configSyslog = "syslog"
)
Merge: * use upstream servers directly for the internal DNS resolver Close #1212 * Server.Start(config *ServerConfig) -> Start() + Server.Prepare(config *ServerConfig) + Server.Resolve(host string) + Server.Exchange() * rDNS: use internal DNS resolver - clients: fix race in WriteDiskConfig() - fix race: move 'clients' object from 'configuration' to 'HomeContext' Go race detector didn't like our 'clients' object in 'configuration'. + add AGH startup test . Create a configuration file . Start AGH instance . Check Web server . Check DNS server . Wait until the filters are downloaded . Stop and cleanup * move module objects from config.* to Context.* * don't call log.SetLevel() if not necessary This helps to avoid Go race detector's warning * ci.sh: 'make' and then run tests Squashed commit of the following: commit 86500c7f749307f37af4cc8c2a1066f679d0cfad Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 18:08:53 2019 +0300 minor commit 6e6abb9dca3cd250c458bec23aa30d2250a9eb40 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 18:08:31 2019 +0300 * ci.sh: 'make' and then run tests commit 114192eefea6800e565ba9ab238202c006516c27 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 17:50:04 2019 +0300 fix commit d426deea7f02cdfd4c7217a38c59e51251956a0f Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 17:46:33 2019 +0300 tests commit 7b350edf03027895b4e43dee908d0155a9b0ac9b Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:56:12 2019 +0300 fix test commit 2f5f116873bbbfdd4bb7f82a596f9e1f5c2bcfd8 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:48:56 2019 +0300 fix tests commit 3fbdc77f9c34726e2295185279444983652d559e Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:45:00 2019 +0300 linter commit 9da0b6965a2b6863bcd552fa83a4de2866600bb8 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:33:23 2019 +0300 * config.dnsctx.whois -> Context.whois commit c71ebdbdf6efd88c877b2f243c69d3bc00a997d7 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:31:08 2019 +0300 * don't call log.SetLevel() if not necessary This helps to avoid Go race detector's warning commit 0f250220133cefdcb0843a50000cb932802b8324 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:28:19 2019 +0300 * rdns: refactor commit c460d8c9414940dac852e390b6c1b4d4fb38dff9 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 14:08:08 2019 +0300 Revert: * stats: serialize access to 'limit' Use 'conf *Config' and update it atomically, as in querylog module. (Note: Race detector still doesn't like it) commit 488bcb884971276de0d5629384b29e22c59ee7e6 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:50:23 2019 +0300 * config.dnsFilter -> Context.dnsFilter commit 86c0a6827a450414b50acec7ebfc5220d13b81e4 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:45:05 2019 +0300 * config.dnsServer -> Context.dnsServer commit ee35ef095ccaabc89e3de0ef52c9b5ed56b36873 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:42:10 2019 +0300 * config.dhcpServer -> Context.dhcpServer commit 1537001cd211099d5fad01696c0b806ae5d257b1 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:39:45 2019 +0300 * config.queryLog -> Context.queryLog commit e5955fe4ff1ef6f41763461b37b502ea25a3d04c Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:03:18 2019 +0300 * config.httpsServer -> Context.httpsServer commit 6153c10a9ac173e159d1f05e0db1512579b9203c Author: Simon Zolin <s.zolin@adguard.com> Date: Mon Dec 9 20:12:24 2019 +0300 * config.httpServer -> Context.httpServer commit abd021fb94039015cd45c97614e8b78d4694f956 Author: Simon Zolin <s.zolin@adguard.com> Date: Mon Dec 9 20:08:05 2019 +0300 * stats: serialize access to 'limit' commit 38c2decfd87c712100edcabe62a6d4518719cb53 Author: Simon Zolin <s.zolin@adguard.com> Date: Mon Dec 9 19:57:04 2019 +0300 * config.stats -> Context.stats commit 6caf8965ad44db9dce9a7a5103aa8fa305ad9a06 Author: Simon Zolin <s.zolin@adguard.com> Date: Mon Dec 9 19:45:23 2019 +0300 fix Restart() ... and 6 more commits
2019-12-11 09:38:58 +00:00
// Global context
type homeContext struct {
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
// Modules
// --
Pull request: 2499 merge rewrites vol.1 Merge in DNS/adguard-home from 2499-merge-rewrites-vol.1 to master Updates #2499. Squashed commit of the following: commit 6b308bc2b360cee8c22e506f31d62bacb4bf8fb3 Merge: f49e9186 2b635bf6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 19:23:07 2021 +0300 Merge branch 'master' into 2499-merge-rewrites-vol.1 commit f49e9186ffc8b7074d03c6721ee56cdb09243684 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 18:50:49 2021 +0300 aghos: fix fs events filtering commit 567dd646556606212af5dab60e3ecbb8fff22c25 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 16:50:37 2021 +0300 all: imp code, docs, fix windows commit 140c8bf519345eb54d0e7500a996fcf465353d71 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 19:41:53 2021 +0300 aghnet: use const commit bebf3f76bd394a498ccad812c57d4507c69529ba Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 19:32:37 2021 +0300 all: imp tests, docs commit 9bfdbb6eb454833135d616e208e82699f98e2562 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 18:42:20 2021 +0300 all: imp path more, imp docs commit ee9ea4c132a6b17787d150bf2bee703abaa57be3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 16:09:46 2021 +0300 all: fix windows, imp paths commit 6fac8338a81e9ecfebfc23a1adcb964e89f6aee6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Oct 11 19:53:35 2021 +0300 all: imp code, docs commit da1ce1a2a3dd2be3fdff2412a6dbd596859dc249 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Oct 11 18:22:50 2021 +0300 aghnet: fix windows tests commit d29de359ed68118d71efb226a8433fac15ff5c66 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Oct 8 21:02:14 2021 +0300 all: repl & imp commit 1356c08944cdbb85ce5532d90fe5b077219ce5ff Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Oct 8 01:41:19 2021 +0300 all: add tests, mv logic, added tmpfs commit f4b11adf8998bc8d9d955c5ac9f386f671bd5213 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 7 14:26:30 2021 +0300 all: imp filewalker, refactor hosts container
2021-10-14 17:39:21 +01:00
clients clientsContainer // per-client-settings module
Pull request: 4358 fix stats Merge in DNS/adguard-home from 4358-fix-stats to master Updates #4358. Updates #4342. Squashed commit of the following: commit 5683cb304688ea639e5ba7f219a7bf12370211a4 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Aug 4 18:20:54 2022 +0300 stats: rm races test commit 63dd67650ed64eaf9685b955a4fdf3c0067a7f8c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Aug 4 17:13:36 2022 +0300 stats: try to imp test commit 59a0f249fc00566872db62e362c87bc0c201b333 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Aug 4 16:38:57 2022 +0300 stats: fix nil ptr deref commit 7fc3ff18a34a1d0e0fec3ca83a33f499ac752572 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Apr 7 16:02:51 2022 +0300 stats: fix races finally, imp tests commit c63f5f4e7929819fe79b3a1e392f6b91cd630846 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Aug 4 00:56:49 2022 +0300 aghhttp: add register func commit 61adc7f0e95279c1b7f4a0c0af5ab387ee461411 Merge: edbdb2d4 9b3adac1 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Aug 4 00:36:01 2022 +0300 Merge branch 'master' into 4358-fix-stats commit edbdb2d4c6a06dcbf8107a28c4c3a61ba394e907 Merge: a91e4d7a a481ff4c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Aug 3 21:00:42 2022 +0300 Merge branch 'master' into 4358-fix-stats commit a91e4d7af13591eeef45cb7980d1ebc1650a5cb7 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Aug 3 18:46:19 2022 +0300 stats: imp code, docs commit c5f3814c5c1a734ca8ff6726cc9ffc1177a055cf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Aug 3 18:16:13 2022 +0300 all: log changes commit 5e6caafc771dddc4c6be07c34658de359106fbe5 Merge: 091ba756 eb8e8166 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Aug 3 18:09:10 2022 +0300 Merge branch 'master' into 4358-fix-stats commit 091ba75618d3689b9c04f05431283417c8cc52f9 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Aug 3 18:07:39 2022 +0300 stats: imp docs, code commit f2b2de77ce5f0448d6df9232a614a3710f1e2e8a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Aug 2 17:09:30 2022 +0300 all: refactor stats & add mutexes commit b3f11c455ceaa3738ec20eefc46f866ff36ed046 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Apr 27 15:30:09 2022 +0300 WIP
2022-08-04 17:05:28 +01:00
stats stats.Interface // statistics module
Pull request: 2499 merge rewrites vol.1 Merge in DNS/adguard-home from 2499-merge-rewrites-vol.1 to master Updates #2499. Squashed commit of the following: commit 6b308bc2b360cee8c22e506f31d62bacb4bf8fb3 Merge: f49e9186 2b635bf6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 19:23:07 2021 +0300 Merge branch 'master' into 2499-merge-rewrites-vol.1 commit f49e9186ffc8b7074d03c6721ee56cdb09243684 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 18:50:49 2021 +0300 aghos: fix fs events filtering commit 567dd646556606212af5dab60e3ecbb8fff22c25 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 16:50:37 2021 +0300 all: imp code, docs, fix windows commit 140c8bf519345eb54d0e7500a996fcf465353d71 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 19:41:53 2021 +0300 aghnet: use const commit bebf3f76bd394a498ccad812c57d4507c69529ba Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 19:32:37 2021 +0300 all: imp tests, docs commit 9bfdbb6eb454833135d616e208e82699f98e2562 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 18:42:20 2021 +0300 all: imp path more, imp docs commit ee9ea4c132a6b17787d150bf2bee703abaa57be3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 16:09:46 2021 +0300 all: fix windows, imp paths commit 6fac8338a81e9ecfebfc23a1adcb964e89f6aee6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Oct 11 19:53:35 2021 +0300 all: imp code, docs commit da1ce1a2a3dd2be3fdff2412a6dbd596859dc249 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Oct 11 18:22:50 2021 +0300 aghnet: fix windows tests commit d29de359ed68118d71efb226a8433fac15ff5c66 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Oct 8 21:02:14 2021 +0300 all: repl & imp commit 1356c08944cdbb85ce5532d90fe5b077219ce5ff Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Oct 8 01:41:19 2021 +0300 all: add tests, mv logic, added tmpfs commit f4b11adf8998bc8d9d955c5ac9f386f671bd5213 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 7 14:26:30 2021 +0300 all: imp filewalker, refactor hosts container
2021-10-14 17:39:21 +01:00
queryLog querylog.QueryLog // query log module
dnsServer *dnsforward.Server // DNS module
rdns *RDNS // rDNS module
Pull request: 4722 dhcp http panic Merge in DNS/adguard-home from 4722-dhcp-http-panic to master Updates #4722. Squashed commit of the following: commit 8a8db48c3bd4f6bb7fabe65b5b7b162f0986fc76 Merge: 39b344f9 b74b92fc Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 13 20:11:23 2022 +0300 Merge branch 'master' into 4722-dhcp-http-panic commit 39b344f97180af17ab22041e5655a27bcc99c29e Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 13 18:33:56 2022 +0300 dhcpd: imp code, fmt commit a36d70d2c25791b2e657e21d6f4681b33497f0cd Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 13 17:38:17 2022 +0300 dhcpd: imp names, docs commit 600d63da7af62de5cb52fc7670ef28c9f4fe95a7 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 13 17:36:17 2022 +0300 dhcpd: rename files, imp tags commit 44f5507649db8536a07c4c21c8ad6e4a60ba3f43 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 13 16:40:26 2022 +0300 dhcpd: add mock commit cfc3cfb714705067d3aa71a7cb5df4245e091cfd Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 13 16:15:27 2022 +0300 all: use ptr instead of value commit ec526c2cf22df3470641296cfc402113c23c3f9b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 13 14:57:10 2022 +0300 all: log changes commit 0eca09f4c72bbdc73a2334c839d7781847ba3962 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 13 14:50:32 2022 +0300 dhcpd: let v4 be unconfigured commit 59636e9ff48aea989d7bdfd216b37899b57137d2 Merge: 9238ca0a bc1503af Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 13 14:50:17 2022 +0300 Merge branch 'master' into 4722-dhcp-http-panic commit 9238ca0a1e190ddc344f01959f474932809f086a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 7 18:28:56 2022 +0300 dhcpd: imp conf commit 5f801c9be96c2fa735a50373495d8c6ca2914f32 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 6 16:31:13 2022 +0300 dhcpd: hide behind iface commit a95c2741a7e3e5bfe8775bf937a3709217b76da0 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Aug 31 16:24:02 2022 +0300 dhcpd: separate os files
2022-09-13 21:45:35 +01:00
dhcpServer dhcpd.Interface // DHCP module
Pull request: 2499 merge rewrites vol.1 Merge in DNS/adguard-home from 2499-merge-rewrites-vol.1 to master Updates #2499. Squashed commit of the following: commit 6b308bc2b360cee8c22e506f31d62bacb4bf8fb3 Merge: f49e9186 2b635bf6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 19:23:07 2021 +0300 Merge branch 'master' into 2499-merge-rewrites-vol.1 commit f49e9186ffc8b7074d03c6721ee56cdb09243684 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 18:50:49 2021 +0300 aghos: fix fs events filtering commit 567dd646556606212af5dab60e3ecbb8fff22c25 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 16:50:37 2021 +0300 all: imp code, docs, fix windows commit 140c8bf519345eb54d0e7500a996fcf465353d71 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 19:41:53 2021 +0300 aghnet: use const commit bebf3f76bd394a498ccad812c57d4507c69529ba Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 19:32:37 2021 +0300 all: imp tests, docs commit 9bfdbb6eb454833135d616e208e82699f98e2562 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 18:42:20 2021 +0300 all: imp path more, imp docs commit ee9ea4c132a6b17787d150bf2bee703abaa57be3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 16:09:46 2021 +0300 all: fix windows, imp paths commit 6fac8338a81e9ecfebfc23a1adcb964e89f6aee6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Oct 11 19:53:35 2021 +0300 all: imp code, docs commit da1ce1a2a3dd2be3fdff2412a6dbd596859dc249 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Oct 11 18:22:50 2021 +0300 aghnet: fix windows tests commit d29de359ed68118d71efb226a8433fac15ff5c66 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Oct 8 21:02:14 2021 +0300 all: repl & imp commit 1356c08944cdbb85ce5532d90fe5b077219ce5ff Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Oct 8 01:41:19 2021 +0300 all: add tests, mv logic, added tmpfs commit f4b11adf8998bc8d9d955c5ac9f386f671bd5213 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 7 14:26:30 2021 +0300 all: imp filewalker, refactor hosts container
2021-10-14 17:39:21 +01:00
auth *Auth // HTTP authentication module
Pull request: 4871 imp filtering Merge in DNS/adguard-home from 4871-imp-filtering to master Closes #4871. Squashed commit of the following: commit 618e7c558447703c114332708c94ef1b34362cf9 Merge: 41ff8ab7 11e4f091 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 19:27:08 2022 +0300 Merge branch 'master' into 4871-imp-filtering commit 41ff8ab755a87170e7334dedcae00f01dcca238a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 19:26:11 2022 +0300 filtering: imp code, log commit e4ae1d1788406ffd7ef0fcc6df896a22b0c2db37 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 14:11:07 2022 +0300 filtering: move handlers into single func commit f7a340b4c10980f512ae935a156f02b0133a1627 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 21 19:21:09 2022 +0300 all: imp code commit e064bf4d3de0283e4bda2aaf5b9822bb8a08f4a6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 20:12:16 2022 +0300 all: imp name commit e7eda3905762f0821e1be1ac3cf77e0ecbedeff4 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:51:23 2022 +0300 all: finally get rid of filtering commit 188550d873e625cc2951583bb3a2eaad036745f5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:36:03 2022 +0300 filtering: merge refresh commit e54ed9c7952b17e66b790c835269b28fbc26f9ca Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:16:23 2022 +0300 filtering: merge filters commit 32da31b754a319487d5f9d5e81e607d349b90180 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 14:48:13 2022 +0300 filtering: imp docs commit 43b0cafa7a27bb9b620c2ba50ccdddcf32cfcecc Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 14:38:04 2022 +0300 all: imp code commit 253a2ea6c92815d364546e34d631e406dd604644 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 20:43:15 2022 +0300 filtering: rm important flag commit 1b87f08f946389d410f13412c7e486290d5e752d Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 17:05:40 2022 +0300 all: move filtering to the package commit daa13499f1dd4fe475c4b75769e34f1eb0915bdf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 15:13:55 2022 +0300 all: finish merging commit d6db75eb2e1f23528e9200ea51507eb793eefa3c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 16 18:18:14 2022 +0300 all: continue merging commit 45b4c484deb7198a469aa18d719bb9dbe81e5d22 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 14 15:44:22 2022 +0300 all: merge filtering types
2022-09-23 11:23:35 +01:00
filters *filtering.DNSFilter // DNS filtering module
web *webAPI // Web (HTTP, HTTPS) module
tls *tlsManager // TLS module
// etcHosts contains IP-hostname mappings taken from the OS-specific hosts
// configuration files, for example /etc/hosts.
Pull request: 2499 merge rewrites vol.1 Merge in DNS/adguard-home from 2499-merge-rewrites-vol.1 to master Updates #2499. Squashed commit of the following: commit 6b308bc2b360cee8c22e506f31d62bacb4bf8fb3 Merge: f49e9186 2b635bf6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 19:23:07 2021 +0300 Merge branch 'master' into 2499-merge-rewrites-vol.1 commit f49e9186ffc8b7074d03c6721ee56cdb09243684 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 18:50:49 2021 +0300 aghos: fix fs events filtering commit 567dd646556606212af5dab60e3ecbb8fff22c25 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 16:50:37 2021 +0300 all: imp code, docs, fix windows commit 140c8bf519345eb54d0e7500a996fcf465353d71 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 19:41:53 2021 +0300 aghnet: use const commit bebf3f76bd394a498ccad812c57d4507c69529ba Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 19:32:37 2021 +0300 all: imp tests, docs commit 9bfdbb6eb454833135d616e208e82699f98e2562 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 18:42:20 2021 +0300 all: imp path more, imp docs commit ee9ea4c132a6b17787d150bf2bee703abaa57be3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 16:09:46 2021 +0300 all: fix windows, imp paths commit 6fac8338a81e9ecfebfc23a1adcb964e89f6aee6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Oct 11 19:53:35 2021 +0300 all: imp code, docs commit da1ce1a2a3dd2be3fdff2412a6dbd596859dc249 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Oct 11 18:22:50 2021 +0300 aghnet: fix windows tests commit d29de359ed68118d71efb226a8433fac15ff5c66 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Oct 8 21:02:14 2021 +0300 all: repl & imp commit 1356c08944cdbb85ce5532d90fe5b077219ce5ff Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Oct 8 01:41:19 2021 +0300 all: add tests, mv logic, added tmpfs commit f4b11adf8998bc8d9d955c5ac9f386f671bd5213 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 7 14:26:30 2021 +0300 all: imp filewalker, refactor hosts container
2021-10-14 17:39:21 +01:00
etcHosts *aghnet.HostsContainer
updater *updater.Updater
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
// mux is our custom http.ServeMux.
mux *http.ServeMux
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
// Runtime properties
// --
configFilename string // Config filename (can be overridden via the command line arguments)
workDir string // Location of our directory, used to protect against CWD being somewhere else
pidFileName string // PID file name. Empty if no PID file was created.
controlLock sync.Mutex
tlsRoots *x509.CertPool // list of root CAs for TLSv1.2
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
client *http.Client
appSignalChannel chan os.Signal // Channel for receiving OS signals by the console app
2022-10-14 18:14:07 +01:00
Pull request 1858: AG-22594-imp-whois Merge in DNS/adguard-home from AG-22594-imp-whois to master Squashed commit of the following: commit 093feed53291d02469fb1bd8d99472597ebd5015 Merge: 956d20dc4 ca313521d Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Jun 21 12:42:40 2023 +0300 Merge branch 'master' into AG-22594-imp-whois commit 956d20dc473dcec90895b6f618fc56e96e9ff833 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Jun 20 18:30:48 2023 +0300 whois: imp code more commit c771fd9c5e4d90e76d079a0d25ab097ab5652a42 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Jun 20 15:05:45 2023 +0300 whois: imp code commit 21900fd468e10d9aee22149a6312b8596ff39810 Merge: 8dbe132c0 371261b2c Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Jun 20 11:34:06 2023 +0300 Merge branch 'master' into AG-22594-imp-whois commit 8dbe132c08d3ad4a63b0d4bdb9d00a5bc25971f4 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Jun 20 11:33:26 2023 +0300 whois: imp code more commit f5e761a260237579c67cbd48f01ea90499bff6b0 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jun 19 16:04:35 2023 +0300 whois: imp code commit 2780f7e16aacddad8736f83b77ef9bfa1271f8b1 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Jun 16 17:33:47 2023 +0300 all: imp code commit 1fc67016068b745a46b3d0d341ab14f9f5bdc9aa Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Jun 16 17:29:19 2023 +0300 whois: imp tests commit 204761870764fb10feea20065d79dee8c321e70b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Jun 16 11:55:37 2023 +0300 all: upd deps commit ded4f59498c5c544277b9c8e249567626547680e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Jun 14 20:43:32 2023 +0300 all: imp tests commit 0eed9834ff9dd94d0788ce69d0bb0521fa725410 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Jun 14 19:31:49 2023 +0300 all: imp code commit 9f867587c8ad87363b8c8b061ead536c1ec59c5d Merge: 504e9484d 681c604c2 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Jun 13 14:20:44 2023 +0300 Merge branch 'master' into AG-22594-imp-whois commit 504e9484dd84ab9d7c84a3f8399993d6422d3b67 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Jun 13 14:18:06 2023 +0300 all: imp cache commit c492abe41ace7ad76fcd4e297c22b910a90fec30 Merge: db36adb9c 826b314f1 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Jun 9 16:06:12 2023 +0300 Merge branch 'master' into AG-22594-imp-whois commit db36adb9c14ce92b3971db0d87ec313d5bcd787e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Jun 9 15:53:33 2023 +0300 all: add todo commit 5cf192de9f93cd0d8521a3a6b4ded7f2bc5e0031 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Jun 8 14:59:26 2023 +0300 all: imp docs commit 021aa3eb5b9476a93b4af5fc90cc9ccf014ca152 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jun 5 18:35:25 2023 +0300 all: imp naming commit 4626c3a7fa3f2543501806c9fa1a19531547f394 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Jun 2 17:41:00 2023 +0300 all: imp tests commit 1afcc9605ca176e4c7f76a03a2c996cf7d6bde13 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Jun 2 12:44:32 2023 +0300 all: imp docs commit cdd0544ff1a63faed5ced3dae6bfb3b783e45428 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Jun 1 17:21:37 2023 +0300 all: add docs ... and 2 more commits
2023-06-21 10:53:53 +01:00
// whoisCh is the channel for receiving IPs for WHOIS processing.
whoisCh chan netip.Addr
2022-10-14 18:14:07 +01:00
// tlsCipherIDs are the ID of the cipher suites that AdGuard Home must use.
tlsCipherIDs []uint16
// disableUpdate, if true, tells AdGuard Home to not check for updates.
disableUpdate bool
// firstRun, if true, tells AdGuard Home to only start the web interface
// service, and only serve the first-run APIs.
firstRun bool
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
// runningAsService flag is set to true when options are passed from the service runner
runningAsService bool
}
// getDataDir returns path to the directory where we store databases and filters
func (c *homeContext) getDataDir() string {
return filepath.Join(c.workDir, dataDir)
Merge: * use upstream servers directly for the internal DNS resolver Close #1212 * Server.Start(config *ServerConfig) -> Start() + Server.Prepare(config *ServerConfig) + Server.Resolve(host string) + Server.Exchange() * rDNS: use internal DNS resolver - clients: fix race in WriteDiskConfig() - fix race: move 'clients' object from 'configuration' to 'HomeContext' Go race detector didn't like our 'clients' object in 'configuration'. + add AGH startup test . Create a configuration file . Start AGH instance . Check Web server . Check DNS server . Wait until the filters are downloaded . Stop and cleanup * move module objects from config.* to Context.* * don't call log.SetLevel() if not necessary This helps to avoid Go race detector's warning * ci.sh: 'make' and then run tests Squashed commit of the following: commit 86500c7f749307f37af4cc8c2a1066f679d0cfad Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 18:08:53 2019 +0300 minor commit 6e6abb9dca3cd250c458bec23aa30d2250a9eb40 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 18:08:31 2019 +0300 * ci.sh: 'make' and then run tests commit 114192eefea6800e565ba9ab238202c006516c27 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 17:50:04 2019 +0300 fix commit d426deea7f02cdfd4c7217a38c59e51251956a0f Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 17:46:33 2019 +0300 tests commit 7b350edf03027895b4e43dee908d0155a9b0ac9b Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:56:12 2019 +0300 fix test commit 2f5f116873bbbfdd4bb7f82a596f9e1f5c2bcfd8 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:48:56 2019 +0300 fix tests commit 3fbdc77f9c34726e2295185279444983652d559e Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:45:00 2019 +0300 linter commit 9da0b6965a2b6863bcd552fa83a4de2866600bb8 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:33:23 2019 +0300 * config.dnsctx.whois -> Context.whois commit c71ebdbdf6efd88c877b2f243c69d3bc00a997d7 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:31:08 2019 +0300 * don't call log.SetLevel() if not necessary This helps to avoid Go race detector's warning commit 0f250220133cefdcb0843a50000cb932802b8324 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:28:19 2019 +0300 * rdns: refactor commit c460d8c9414940dac852e390b6c1b4d4fb38dff9 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 14:08:08 2019 +0300 Revert: * stats: serialize access to 'limit' Use 'conf *Config' and update it atomically, as in querylog module. (Note: Race detector still doesn't like it) commit 488bcb884971276de0d5629384b29e22c59ee7e6 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:50:23 2019 +0300 * config.dnsFilter -> Context.dnsFilter commit 86c0a6827a450414b50acec7ebfc5220d13b81e4 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:45:05 2019 +0300 * config.dnsServer -> Context.dnsServer commit ee35ef095ccaabc89e3de0ef52c9b5ed56b36873 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:42:10 2019 +0300 * config.dhcpServer -> Context.dhcpServer commit 1537001cd211099d5fad01696c0b806ae5d257b1 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:39:45 2019 +0300 * config.queryLog -> Context.queryLog commit e5955fe4ff1ef6f41763461b37b502ea25a3d04c Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:03:18 2019 +0300 * config.httpsServer -> Context.httpsServer commit 6153c10a9ac173e159d1f05e0db1512579b9203c Author: Simon Zolin <s.zolin@adguard.com> Date: Mon Dec 9 20:12:24 2019 +0300 * config.httpServer -> Context.httpServer commit abd021fb94039015cd45c97614e8b78d4694f956 Author: Simon Zolin <s.zolin@adguard.com> Date: Mon Dec 9 20:08:05 2019 +0300 * stats: serialize access to 'limit' commit 38c2decfd87c712100edcabe62a6d4518719cb53 Author: Simon Zolin <s.zolin@adguard.com> Date: Mon Dec 9 19:57:04 2019 +0300 * config.stats -> Context.stats commit 6caf8965ad44db9dce9a7a5103aa8fa305ad9a06 Author: Simon Zolin <s.zolin@adguard.com> Date: Mon Dec 9 19:45:23 2019 +0300 fix Restart() ... and 6 more commits
2019-12-11 09:38:58 +00:00
}
// Context - a global context object
var Context homeContext
2019-07-09 16:52:18 +01:00
// Main is the entry point
func Main(clientBuildFS fs.FS) {
initCmdLineOpts()
// The configuration file path can be overridden, but other command-line
// options have to override config values. Therefore, do it manually
// instead of using package flag.
//
// TODO(a.garipov): The comment above is most likely false. Replace with
// package flag.
opts := loadCmdLineOpts()
2018-08-30 15:25:33 +01:00
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
Context.appSignalChannel = make(chan os.Signal)
signal.Notify(Context.appSignalChannel, syscall.SIGINT, syscall.SIGTERM, syscall.SIGHUP, syscall.SIGQUIT)
go func() {
for {
sig := <-Context.appSignalChannel
Pull request:* all: remove github.com/joomcode/errorx dependency Merge in DNS/adguard-home from 2240-removing-errorx-dependency to master Squashed commit of the following: commit 5bbe0567356f06e3b9ee5b3dc38d357b472cacb1 Merge: a6040850d 02d16a0b4 Author: Eugene Burkov <e.burkov@adguard.com> Date: Thu Nov 5 14:32:22 2020 +0300 Merge branch 'master' into 2240-removing-errorx-dependency commit a6040850da3cefb131208097477b0956e80063fb Author: Eugene Burkov <e.burkov@adguard.com> Date: Thu Nov 5 14:23:36 2020 +0300 * dhcpd: convert some abbreviations to lowercase. commit d05bd51b994906b0ff52c5a8e779bd1f512f4bb7 Author: Eugene Burkov <e.burkov@adguard.com> Date: Thu Nov 5 12:47:20 2020 +0300 * agherr: last final fixes commit 164bca55035ff44e50b0abb33e129a0d24ffe87c Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Nov 3 19:11:10 2020 +0300 * all: final fixes again commit a0ac26f409c0b28a176cf2861d52c2f471b59484 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Nov 3 18:51:39 2020 +0300 * all: final fixes commit 6147b02d402b513323b07e85856b348884f3a088 Merge: 9fd3af1a3 62cc334f4 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 3 18:26:03 2020 +0300 Merge branch 'master' into 2240-removing-errorx-dependency commit 9fd3af1a39a3189b5c41315a8ad1568ae5cb4fc9 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 3 18:23:08 2020 +0300 * all: remove useless helper commit 7cd9aeae639762b28b25f354d69c5cf74f670211 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 3 17:19:26 2020 +0300 * agherr: improved code tidiness commit a74a49236e9aaace070646dac710de9201105262 Merge: dc9dedbf2 df34ee5c0 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 3 16:54:29 2020 +0300 Merge branch 'master' into 2240-removing-errorx-dependency commit dc9dedbf205756e3adaa3bc776d349bf3d8c69a5 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 3 16:40:08 2020 +0300 * agherr: improve and cover by tests commit fd6bfe9e282156cc60e006cb7cd46cce4d3a07a8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 3 14:06:27 2020 +0300 * all: improve code quality commit ea00c2f8c5060e9611f9a80cfd0e4a039526d0c4 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 3 13:03:57 2020 +0300 * all: fix linter style warnings commit 8e75e1a681a7218c2b4c69adfa2b7e1e2966f9ac Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 3 12:29:26 2020 +0300 * all: remove github.com/joomcode/errorx dependency Closes #2240.
2020-11-05 12:20:57 +00:00
log.Info("Received signal %q", sig)
switch sig {
case syscall.SIGHUP:
Context.clients.reloadARP()
Context.tls.reload()
default:
cleanup(context.Background())
cleanupAlways()
os.Exit(0)
}
}
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
}()
if opts.serviceControlAction != "" {
handleServiceControlAction(opts, clientBuildFS)
return
}
// run the protection
run(opts, clientBuildFS)
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// setupContext initializes [Context] fields. It also reads and upgrades
// config file if necessary.
func setupContext(opts options) (err error) {
setupContextFlags(opts)
Context.tlsRoots = aghtls.SystemRootCAs()
Context.client = &http.Client{
Timeout: time.Minute * 5,
Transport: &http.Transport{
DialContext: customDialContext,
Proxy: getHTTPProxy,
TLSClientConfig: &tls.Config{
RootCAs: Context.tlsRoots,
CipherSuites: Context.tlsCipherIDs,
MinVersion: tls.VersionTLS12,
},
},
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
Context.mux = http.NewServeMux()
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
if !Context.firstRun {
// Do the upgrade if necessary.
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
err = upgradeConfig()
if err != nil {
// Don't wrap the error, because it's informative enough as is.
return err
}
if err = parseConfig(); err != nil {
log.Error("parsing configuration file: %s", err)
os.Exit(1)
}
if opts.checkConfig {
log.Info("configuration file is ok")
os.Exit(0)
}
if !opts.noEtcHosts && config.Clients.Sources.HostsFile {
err = setupHostsContainer()
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
if err != nil {
// Don't wrap the error, because it's informative enough as is.
return err
}
}
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
return nil
Pull request: 2271 handle nolint Merge in DNS/adguard-home from 2271-handle-nolint to master Closes #2271. Squashed commit of the following: commit fde5c8795ac79e1f7d02ba8c8e369b5a724a000e Merge: fc2acd898 642dcd647 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Nov 20 17:12:28 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit fc2acd89871de08c39e80ace9e5bb8a7acb7afba Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 17 11:55:29 2020 +0300 dnsforward: fix test output strings commit c4ebae6ea9c293bad239519c44ca5a6c576bb921 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 22:43:20 2020 +0300 dnsfilter: make package pass tests commit f2d98c6acabd8977f3b1b361987eaa31eb6eb9ad Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 20:05:00 2020 +0300 querylog: make decoding pass tests commit ab5850d24c50d53b8393f2de448cc340241351d7 Merge: 6ed2066bf 8a9c6e8a0 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 19:48:31 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit 6ed2066bf567e13dd14cfa16fc7b109b59fa39ef Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 18:13:45 2020 +0300 home: fix tests naming commit af691081fb02b7500a746b16492f01f7f9befe9a Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 12:15:49 2020 +0300 home: impove code quality commit 2914cd3cd23ef2a1964116baab9187d89b377f86 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 15:46:39 2020 +0300 * querylog: remove useless check commit 9996840650e784ccc76d1f29964560435ba27dc7 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 13:18:34 2020 +0300 * all: fix noticed defects commit 2b15293e59337f70302fbc0db81ebb26bee0bed2 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 20:15:53 2020 +0300 * stats: remove last nolint directive commit b2e1ddf7b58196a2fdbf879f084edb41ca1aa1eb Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:35:41 2020 +0300 * all: remove another nolint directive commit c6fc5cfcc9c95ab9e570a95ab41c3e5c0125e62e Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:11:28 2020 +0300 * querylog: remove nolint directive commit 226ddbf2c92f737f085b44a4ddf6daec7b602153 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:35:26 2020 +0300 * home: remove nolint directive commit 2ea3086ad41e9003282add7e996ae722d72d878b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:13:57 2020 +0300 * home: reduce cyclomatic complexity of run function commit f479b480c48e0bb832ddef8f57586f56b8a55bab Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 15:35:46 2020 +0300 * home: use crypto/rand instead of math/rand commit a28d4a53e3b930136b036606fc7e78404f1d208b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 14:11:07 2020 +0300 * dnsforward: remove gocyclo nolint directive commit 64a0a324cc2b20614ceec3ccc6505e960fe526e9 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 11:45:49 2020 +0300 all *: remove some nolint directives Updates #2271.
2020-11-20 14:32:41 +00:00
}
// setupContextFlags sets global flags and prints their status to the log.
func setupContextFlags(opts options) {
Context.firstRun = detectFirstRun()
if Context.firstRun {
log.Info("This is the first time AdGuard Home is launched")
checkPermissions()
}
Context.runningAsService = opts.runningAsService
// Don't print the runningAsService flag, since that has already been done
// in [run].
Context.disableUpdate = opts.disableUpdate || version.Channel() == version.ChannelDevelopment
if Context.disableUpdate {
log.Info("AdGuard Home updates are disabled")
}
}
// logIfUnsupported logs a formatted warning if the error is one of the
// unsupported errors and returns nil. If err is nil, logIfUnsupported returns
// nil. Otherwise, it returns err.
func logIfUnsupported(msg string, err error) (outErr error) {
if errors.As(err, new(*aghos.UnsupportedError)) {
log.Debug(msg, err)
return nil
}
return err
}
// configureOS sets the OS-related configuration.
func configureOS(conf *configuration) (err error) {
osConf := conf.OSConfig
if osConf == nil {
return nil
}
if osConf.Group != "" {
err = aghos.SetGroup(osConf.Group)
err = logIfUnsupported("warning: setting group", err)
if err != nil {
return fmt.Errorf("setting group: %w", err)
}
log.Info("group set to %s", osConf.Group)
}
if osConf.User != "" {
err = aghos.SetUser(osConf.User)
err = logIfUnsupported("warning: setting user", err)
if err != nil {
return fmt.Errorf("setting user: %w", err)
}
log.Info("user set to %s", osConf.User)
}
if osConf.RlimitNoFile != 0 {
err = aghos.SetRlimit(osConf.RlimitNoFile)
err = logIfUnsupported("warning: setting rlimit", err)
if err != nil {
return fmt.Errorf("setting rlimit: %w", err)
}
log.Info("rlimit_nofile set to %d", osConf.RlimitNoFile)
}
return nil
}
// setupHostsContainer initializes the structures to keep up-to-date the hosts
// provided by the OS.
func setupHostsContainer() (err error) {
hostsWatcher, err := aghos.NewOSWritesWatcher()
if err != nil {
return fmt.Errorf("initing hosts watcher: %w", err)
}
Context.etcHosts, err = aghnet.NewHostsContainer(
filtering.SysHostsListID,
aghos.RootDirFS(),
hostsWatcher,
aghnet.DefaultHostsPaths()...,
)
if err != nil {
closeErr := hostsWatcher.Close()
if errors.Is(err, aghnet.ErrNoHostsPaths) && closeErr == nil {
log.Info("warning: initing hosts container: %s", err)
return nil
}
return errors.WithDeferred(fmt.Errorf("initing hosts container: %w", err), closeErr)
}
return nil
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// setupOpts sets up command-line options.
func setupOpts(opts options) (err error) {
err = setupBindOpts(opts)
Pull request 1837: AG-21462-imp-safebrowsing-parental Merge in DNS/adguard-home from AG-21462-imp-safebrowsing-parental to master Squashed commit of the following: commit 85016d4f1105e21a407efade0bd45b8362808061 Merge: 0e61edade 620b51e3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 16:36:30 2023 +0300 Merge branch 'master' into AG-21462-imp-safebrowsing-parental commit 0e61edadeff34f6305e941c1db94575c82f238d9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 14:51:37 2023 +0300 filtering: imp tests commit 994255514cc0f67dfe33d5a0892432e8924d1e36 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 11:13:19 2023 +0300 filtering: fix typo commit 96d1069573171538333330d6af94ef0f4208a9c4 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 11:00:18 2023 +0300 filtering: imp code more commit c2a5620b04c4a529eea69983f1520cd2bc82ea9b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 26 19:13:26 2023 +0300 all: add todo commit e5dcc2e9701f8bccfde6ef8c01a4a2e7eb31599e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 26 14:36:08 2023 +0300 all: imp code more commit b6e734ccbeda82669023f6578481260b7c1f7161 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Apr 25 15:01:56 2023 +0300 filtering: imp code commit 530648dadf836c1a4bd9917e0d3b47256fa8ff52 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 24 20:06:36 2023 +0300 all: imp code commit 49fa6e587052a40bb431fea457701ee860493527 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 24 14:57:19 2023 +0300 all: rm safe browsing ctx commit bbcb66cb03e18fa875e3c33cf16295892739e507 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Apr 21 17:54:18 2023 +0300 filtering: add cache item commit cb7c9fffe8c4ff5e7a21ca912c223c799f61385f Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 18:43:02 2023 +0300 filtering: fix hashes commit 153fec46270212af03f3631bfb42c5d680c4e142 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 16:15:15 2023 +0300 filtering: add test cases commit 09372f92bbb1fc082f1b1283594ee589100209c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 15:38:05 2023 +0300 filtering: imp code commit 466bc26d524ea6d1c3efb33692a7785d39e491ca Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 19 18:38:40 2023 +0300 filtering: add tests commit 24365ecf8c60512fdac65833ee603c80864ae018 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 19 11:38:57 2023 +0300 filtering: add hashprefix
2023-04-27 14:39:35 +01:00
if err != nil {
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// Don't wrap the error, because it's informative enough as is.
return err
Pull request 1837: AG-21462-imp-safebrowsing-parental Merge in DNS/adguard-home from AG-21462-imp-safebrowsing-parental to master Squashed commit of the following: commit 85016d4f1105e21a407efade0bd45b8362808061 Merge: 0e61edade 620b51e3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 16:36:30 2023 +0300 Merge branch 'master' into AG-21462-imp-safebrowsing-parental commit 0e61edadeff34f6305e941c1db94575c82f238d9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 14:51:37 2023 +0300 filtering: imp tests commit 994255514cc0f67dfe33d5a0892432e8924d1e36 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 11:13:19 2023 +0300 filtering: fix typo commit 96d1069573171538333330d6af94ef0f4208a9c4 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 11:00:18 2023 +0300 filtering: imp code more commit c2a5620b04c4a529eea69983f1520cd2bc82ea9b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 26 19:13:26 2023 +0300 all: add todo commit e5dcc2e9701f8bccfde6ef8c01a4a2e7eb31599e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 26 14:36:08 2023 +0300 all: imp code more commit b6e734ccbeda82669023f6578481260b7c1f7161 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Apr 25 15:01:56 2023 +0300 filtering: imp code commit 530648dadf836c1a4bd9917e0d3b47256fa8ff52 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 24 20:06:36 2023 +0300 all: imp code commit 49fa6e587052a40bb431fea457701ee860493527 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 24 14:57:19 2023 +0300 all: rm safe browsing ctx commit bbcb66cb03e18fa875e3c33cf16295892739e507 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Apr 21 17:54:18 2023 +0300 filtering: add cache item commit cb7c9fffe8c4ff5e7a21ca912c223c799f61385f Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 18:43:02 2023 +0300 filtering: fix hashes commit 153fec46270212af03f3631bfb42c5d680c4e142 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 16:15:15 2023 +0300 filtering: add test cases commit 09372f92bbb1fc082f1b1283594ee589100209c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 15:38:05 2023 +0300 filtering: imp code commit 466bc26d524ea6d1c3efb33692a7785d39e491ca Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 19 18:38:40 2023 +0300 filtering: add tests commit 24365ecf8c60512fdac65833ee603c80864ae018 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 19 11:38:57 2023 +0300 filtering: add hashprefix
2023-04-27 14:39:35 +01:00
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
if len(opts.pidFile) != 0 && writePIDFile(opts.pidFile) {
Context.pidFileName = opts.pidFile
Pull request 1837: AG-21462-imp-safebrowsing-parental Merge in DNS/adguard-home from AG-21462-imp-safebrowsing-parental to master Squashed commit of the following: commit 85016d4f1105e21a407efade0bd45b8362808061 Merge: 0e61edade 620b51e3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 16:36:30 2023 +0300 Merge branch 'master' into AG-21462-imp-safebrowsing-parental commit 0e61edadeff34f6305e941c1db94575c82f238d9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 14:51:37 2023 +0300 filtering: imp tests commit 994255514cc0f67dfe33d5a0892432e8924d1e36 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 11:13:19 2023 +0300 filtering: fix typo commit 96d1069573171538333330d6af94ef0f4208a9c4 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 11:00:18 2023 +0300 filtering: imp code more commit c2a5620b04c4a529eea69983f1520cd2bc82ea9b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 26 19:13:26 2023 +0300 all: add todo commit e5dcc2e9701f8bccfde6ef8c01a4a2e7eb31599e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 26 14:36:08 2023 +0300 all: imp code more commit b6e734ccbeda82669023f6578481260b7c1f7161 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Apr 25 15:01:56 2023 +0300 filtering: imp code commit 530648dadf836c1a4bd9917e0d3b47256fa8ff52 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 24 20:06:36 2023 +0300 all: imp code commit 49fa6e587052a40bb431fea457701ee860493527 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 24 14:57:19 2023 +0300 all: rm safe browsing ctx commit bbcb66cb03e18fa875e3c33cf16295892739e507 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Apr 21 17:54:18 2023 +0300 filtering: add cache item commit cb7c9fffe8c4ff5e7a21ca912c223c799f61385f Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 18:43:02 2023 +0300 filtering: fix hashes commit 153fec46270212af03f3631bfb42c5d680c4e142 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 16:15:15 2023 +0300 filtering: add test cases commit 09372f92bbb1fc082f1b1283594ee589100209c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 15:38:05 2023 +0300 filtering: imp code commit 466bc26d524ea6d1c3efb33692a7785d39e491ca Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 19 18:38:40 2023 +0300 filtering: add tests commit 24365ecf8c60512fdac65833ee603c80864ae018 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 19 11:38:57 2023 +0300 filtering: add hashprefix
2023-04-27 14:39:35 +01:00
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
return nil
}
Pull request 1837: AG-21462-imp-safebrowsing-parental Merge in DNS/adguard-home from AG-21462-imp-safebrowsing-parental to master Squashed commit of the following: commit 85016d4f1105e21a407efade0bd45b8362808061 Merge: 0e61edade 620b51e3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 16:36:30 2023 +0300 Merge branch 'master' into AG-21462-imp-safebrowsing-parental commit 0e61edadeff34f6305e941c1db94575c82f238d9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 14:51:37 2023 +0300 filtering: imp tests commit 994255514cc0f67dfe33d5a0892432e8924d1e36 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 11:13:19 2023 +0300 filtering: fix typo commit 96d1069573171538333330d6af94ef0f4208a9c4 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 27 11:00:18 2023 +0300 filtering: imp code more commit c2a5620b04c4a529eea69983f1520cd2bc82ea9b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 26 19:13:26 2023 +0300 all: add todo commit e5dcc2e9701f8bccfde6ef8c01a4a2e7eb31599e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 26 14:36:08 2023 +0300 all: imp code more commit b6e734ccbeda82669023f6578481260b7c1f7161 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Apr 25 15:01:56 2023 +0300 filtering: imp code commit 530648dadf836c1a4bd9917e0d3b47256fa8ff52 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 24 20:06:36 2023 +0300 all: imp code commit 49fa6e587052a40bb431fea457701ee860493527 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 24 14:57:19 2023 +0300 all: rm safe browsing ctx commit bbcb66cb03e18fa875e3c33cf16295892739e507 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Apr 21 17:54:18 2023 +0300 filtering: add cache item commit cb7c9fffe8c4ff5e7a21ca912c223c799f61385f Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 18:43:02 2023 +0300 filtering: fix hashes commit 153fec46270212af03f3631bfb42c5d680c4e142 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 16:15:15 2023 +0300 filtering: add test cases commit 09372f92bbb1fc082f1b1283594ee589100209c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Apr 20 15:38:05 2023 +0300 filtering: imp code commit 466bc26d524ea6d1c3efb33692a7785d39e491ca Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 19 18:38:40 2023 +0300 filtering: add tests commit 24365ecf8c60512fdac65833ee603c80864ae018 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 19 11:38:57 2023 +0300 filtering: add hashprefix
2023-04-27 14:39:35 +01:00
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// initContextClients initializes Context clients and related fields.
func initContextClients() (err error) {
err = setupDNSFilteringConf(config.DNS.DnsfilterConf)
Pull request: 1163 safesearch vol.2 Merge in DNS/adguard-home from 1163-safesearch-1-2-1 to master Squashed commit of the following: commit d3a5ebef35210019842145074e898129b42f1f2c Merge: b85264ae c6706445 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 15 09:17:53 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 # Conflicts: # CHANGELOG.md commit b85264aefc5f191ac6cb194b519f03ba15829a4e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 14 00:16:07 2023 +0700 home: imp code commit ac2ed7a5ce8db40628e7d4d1c8634641e5f38b0b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 23:02:06 2023 +0700 all: changelog commit f0fccafcb01f50c7051df53bbe9b02cab75aa71e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:42:36 2023 +0700 all: changelog commit 37df29bf6372939644fb28e3d70365496e0cb4f6 Merge: b227b277 595484e0 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:38:57 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit b227b2775b4866d69241ad87acf99700715552cb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:56:01 2023 +0700 all: imp docs commit 6fd39fc3565c3f4bc7a7113d17733c20dfe24d8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:55:03 2023 +0700 home: imp code commit 3bb3bb7c7dcf97b2a5602a7d2b6770c08b4d863d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 12:16:53 2023 +0700 home: imp docs commit 5f573a56a9fd9942ad677fa0fae6b24228dab653 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 11:56:47 2023 +0700 home: imp code commit 23eeb5552cf2510596b2311cc3eda53ac678ffcc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 10 10:57:33 2023 +0700 home: imp code commit 643de2fca1b5917c61fe83e1e472222404f3cd21 Merge: dada6e63 a2053526 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 21:03:08 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit dada6e63ca5324d30775e2da1727da891743f654 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 17:09:03 2023 +0700 all: imp docs commit 81a180d99dd9a995440d5f4e2ebca34678e7d0c7 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 15:12:43 2023 +0700 all: imp code commit fa84877bc777004d246d71d0a9ae0bd9ee568a91 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:53:05 2023 +0700 all: imp code commit 6d7e02e745d72921a693d4f09eec7ce21c2aefd4 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:40:02 2023 +0700 all: imp docs commit 0a4332997070fb8d2fb3a34d32b92f57a325ff06 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 7 22:00:52 2023 +0700 safesearch: fix merge commit 145c2222ba4cf7f8909b816d83829d2217c94243 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 2 11:41:48 2023 +0700 safesearch: fix merge commit 14c6a8005fe15b5d5a39f91b17c96d8670975811 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:50:09 2023 +0700 all: docs commit 2a85c8831866bf1c34c423a289461fc1e32667b5 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:47:00 2023 +0700 all: use safesearch package
2023-03-15 11:31:07 +00:00
if err != nil {
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// Don't wrap the error, because it's informative enough as is.
return err
Pull request: 1163 safesearch vol.2 Merge in DNS/adguard-home from 1163-safesearch-1-2-1 to master Squashed commit of the following: commit d3a5ebef35210019842145074e898129b42f1f2c Merge: b85264ae c6706445 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 15 09:17:53 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 # Conflicts: # CHANGELOG.md commit b85264aefc5f191ac6cb194b519f03ba15829a4e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 14 00:16:07 2023 +0700 home: imp code commit ac2ed7a5ce8db40628e7d4d1c8634641e5f38b0b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 23:02:06 2023 +0700 all: changelog commit f0fccafcb01f50c7051df53bbe9b02cab75aa71e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:42:36 2023 +0700 all: changelog commit 37df29bf6372939644fb28e3d70365496e0cb4f6 Merge: b227b277 595484e0 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:38:57 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit b227b2775b4866d69241ad87acf99700715552cb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:56:01 2023 +0700 all: imp docs commit 6fd39fc3565c3f4bc7a7113d17733c20dfe24d8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:55:03 2023 +0700 home: imp code commit 3bb3bb7c7dcf97b2a5602a7d2b6770c08b4d863d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 12:16:53 2023 +0700 home: imp docs commit 5f573a56a9fd9942ad677fa0fae6b24228dab653 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 11:56:47 2023 +0700 home: imp code commit 23eeb5552cf2510596b2311cc3eda53ac678ffcc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 10 10:57:33 2023 +0700 home: imp code commit 643de2fca1b5917c61fe83e1e472222404f3cd21 Merge: dada6e63 a2053526 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 21:03:08 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit dada6e63ca5324d30775e2da1727da891743f654 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 17:09:03 2023 +0700 all: imp docs commit 81a180d99dd9a995440d5f4e2ebca34678e7d0c7 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 15:12:43 2023 +0700 all: imp code commit fa84877bc777004d246d71d0a9ae0bd9ee568a91 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:53:05 2023 +0700 all: imp code commit 6d7e02e745d72921a693d4f09eec7ce21c2aefd4 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:40:02 2023 +0700 all: imp docs commit 0a4332997070fb8d2fb3a34d32b92f57a325ff06 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 7 22:00:52 2023 +0700 safesearch: fix merge commit 145c2222ba4cf7f8909b816d83829d2217c94243 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 2 11:41:48 2023 +0700 safesearch: fix merge commit 14c6a8005fe15b5d5a39f91b17c96d8670975811 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:50:09 2023 +0700 all: docs commit 2a85c8831866bf1c34c423a289461fc1e32667b5 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:47:00 2023 +0700 all: use safesearch package
2023-03-15 11:31:07 +00:00
}
Pull request 1817: AG-20352-imp-leases-db Merge in DNS/adguard-home from AG-20352-imp-leases-db to master Squashed commit of the following: commit 2235fb4671bb3f80c933847362cd35b5704dd18d Merge: 0c4d76d4f 76a74b271 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Apr 18 15:09:34 2023 +0300 Merge branch 'master' into AG-20352-imp-leases-db commit 0c4d76d4f6222ae06c568864d366df866dc55a54 Merge: e586b82c7 4afd39b22 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Apr 18 11:07:27 2023 +0300 Merge branch 'master' into AG-20352-imp-leases-db commit e586b82c700c4d432e34f36400519eb08b2653ad Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Apr 18 11:06:40 2023 +0300 dhcpd: imp docs commit 411d4e6f6e36051bf6a66c709380ed268c161c41 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 17 16:56:56 2023 +0300 dhcpd: imp code commit e457dc2c385ab62b36df7f96c949e6b90ed2034a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 17 14:29:29 2023 +0300 all: imp code more commit c2df20d0125d368d0155af0808af979921763e1f Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Apr 14 15:07:53 2023 +0300 all: imp code commit a4e9ffb9ae769c828c22d62ddf231f7bcfea14db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 12 19:19:35 2023 +0300 dhcpd: fix test more commit 138d89414f1a89558b23962acb7174dce28346d9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 12 18:08:29 2023 +0300 dhcpd: fix test commit e07e7a23e7c913951c8ecb38c12a3345ebe473be Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 12 17:22:27 2023 +0300 all: upd chlog commit 1b6a76e79cf4beed9ca980766ce97930b375bfde Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 12 13:24:11 2023 +0300 all: migrate leases db
2023-04-18 13:12:11 +01:00
//lint:ignore SA1019 Migration is not over.
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
config.DHCP.WorkDir = Context.workDir
Pull request 1817: AG-20352-imp-leases-db Merge in DNS/adguard-home from AG-20352-imp-leases-db to master Squashed commit of the following: commit 2235fb4671bb3f80c933847362cd35b5704dd18d Merge: 0c4d76d4f 76a74b271 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Apr 18 15:09:34 2023 +0300 Merge branch 'master' into AG-20352-imp-leases-db commit 0c4d76d4f6222ae06c568864d366df866dc55a54 Merge: e586b82c7 4afd39b22 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Apr 18 11:07:27 2023 +0300 Merge branch 'master' into AG-20352-imp-leases-db commit e586b82c700c4d432e34f36400519eb08b2653ad Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Apr 18 11:06:40 2023 +0300 dhcpd: imp docs commit 411d4e6f6e36051bf6a66c709380ed268c161c41 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 17 16:56:56 2023 +0300 dhcpd: imp code commit e457dc2c385ab62b36df7f96c949e6b90ed2034a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Apr 17 14:29:29 2023 +0300 all: imp code more commit c2df20d0125d368d0155af0808af979921763e1f Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Apr 14 15:07:53 2023 +0300 all: imp code commit a4e9ffb9ae769c828c22d62ddf231f7bcfea14db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 12 19:19:35 2023 +0300 dhcpd: fix test more commit 138d89414f1a89558b23962acb7174dce28346d9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 12 18:08:29 2023 +0300 dhcpd: fix test commit e07e7a23e7c913951c8ecb38c12a3345ebe473be Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 12 17:22:27 2023 +0300 all: upd chlog commit 1b6a76e79cf4beed9ca980766ce97930b375bfde Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Apr 12 13:24:11 2023 +0300 all: migrate leases db
2023-04-18 13:12:11 +01:00
config.DHCP.DataDir = Context.getDataDir()
2019-10-11 17:56:18 +01:00
config.DHCP.HTTPRegister = httpRegister
config.DHCP.ConfigModified = onConfigModified
Pull request: return 501 when we don't support features Merge in DNS/adguard-home from 2295-dhcp-windows to master Updates #2295. Squashed commit of the following: commit 3b00a90c3d9bc33e9af478e4062c0f938d4f327d Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Nov 16 16:45:43 2020 +0300 all: use the 501 handlers instead of the real ones, revert other changes commit 0a3b37736a21abd6181e0d28c32069e8d7a576d0 Merge: 45feba755 6358240e9 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Nov 16 15:59:15 2020 +0300 Merge branch 'master' into 2295-dhcp-windows and update commit 45feba755dde37e43cc8075b896e1576157341e6 Merge: cd987d8bc a19523b25 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Nov 16 15:51:16 2020 +0300 Merge branch 'master' into 2295-dhcp-windows commit cd987d8bc2cd524b7454d9037b595069714645f9 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 15:55:23 2020 +0300 all: improve tests and refactor dhcp checking code even more commit 3aad675443f325b5909523bcc1c987aa04ac61d9 Merge: 70c477e61 09196118e Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 14:44:43 2020 +0300 Merge branch 'master' into 2295-dhcp-windows commit 70c477e61cdc1237603918f1c44470c1549f1136 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 14:34:06 2020 +0300 home: fix dhcpd test on windows commit e59597d783fb9304e63f94eee2b5a5d67a5b2169 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 13:38:25 2020 +0300 all: mention the feature in the changelog commit 5555c8d881b1c20b5b0a0cb096a17cf56e209c06 Merge: c3b6a5a93 e802e6645 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 13:35:35 2020 +0300 Merge branch 'master' into 2295-dhcp-windows commit c3b6a5a930693090838eb1ef9f75a09b5b223ba6 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Nov 12 20:37:09 2020 +0300 util: fix comment commit ed92dfdb5d3a6c4ba5d032cbe781e7fd87882813 Author: ArtemBaskal <asbaskal@miem.hse.ru> Date: Thu Nov 12 20:24:14 2020 +0300 Adapt client commit e6f0494c20a4ad5388492af9091568eea5c6e2d6 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Nov 12 13:35:25 2020 +0300 return 501 when we don't support features
2020-11-16 16:01:12 +00:00
Context.dhcpServer, err = dhcpd.Create(config.DHCP)
if Context.dhcpServer == nil || err != nil {
// TODO(a.garipov): There are a lot of places in the code right
// now which assume that the DHCP server can be nil despite this
// condition. Inspect them and perhaps rewrite them to use
// Enabled() instead.
return fmt.Errorf("initing dhcp: %w", err)
}
Pull request: return 501 when we don't support features Merge in DNS/adguard-home from 2295-dhcp-windows to master Updates #2295. Squashed commit of the following: commit 3b00a90c3d9bc33e9af478e4062c0f938d4f327d Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Nov 16 16:45:43 2020 +0300 all: use the 501 handlers instead of the real ones, revert other changes commit 0a3b37736a21abd6181e0d28c32069e8d7a576d0 Merge: 45feba755 6358240e9 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Nov 16 15:59:15 2020 +0300 Merge branch 'master' into 2295-dhcp-windows and update commit 45feba755dde37e43cc8075b896e1576157341e6 Merge: cd987d8bc a19523b25 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Nov 16 15:51:16 2020 +0300 Merge branch 'master' into 2295-dhcp-windows commit cd987d8bc2cd524b7454d9037b595069714645f9 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 15:55:23 2020 +0300 all: improve tests and refactor dhcp checking code even more commit 3aad675443f325b5909523bcc1c987aa04ac61d9 Merge: 70c477e61 09196118e Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 14:44:43 2020 +0300 Merge branch 'master' into 2295-dhcp-windows commit 70c477e61cdc1237603918f1c44470c1549f1136 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 14:34:06 2020 +0300 home: fix dhcpd test on windows commit e59597d783fb9304e63f94eee2b5a5d67a5b2169 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 13:38:25 2020 +0300 all: mention the feature in the changelog commit 5555c8d881b1c20b5b0a0cb096a17cf56e209c06 Merge: c3b6a5a93 e802e6645 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Nov 13 13:35:35 2020 +0300 Merge branch 'master' into 2295-dhcp-windows commit c3b6a5a930693090838eb1ef9f75a09b5b223ba6 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Nov 12 20:37:09 2020 +0300 util: fix comment commit ed92dfdb5d3a6c4ba5d032cbe781e7fd87882813 Author: ArtemBaskal <asbaskal@miem.hse.ru> Date: Thu Nov 12 20:24:14 2020 +0300 Adapt client commit e6f0494c20a4ad5388492af9091568eea5c6e2d6 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Nov 12 13:35:25 2020 +0300 return 501 when we don't support features
2020-11-16 16:01:12 +00:00
Context.updater = updater.NewUpdater(&updater.Config{
Client: Context.client,
Version: version.Version(),
Channel: version.Channel(),
GOARCH: runtime.GOARCH,
GOOS: runtime.GOOS,
GOARM: version.GOARM(),
GOMIPS: version.GOMIPS(),
WorkDir: Context.workDir,
ConfName: config.getConfigFilename(),
2020-07-22 18:27:20 +01:00
})
2020-07-22 12:20:14 +01:00
var arpdb aghnet.ARPDB
if config.Clients.Sources.ARP {
arpdb = aghnet.NewARPDB()
}
2021-12-13 12:18:21 +00:00
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
Context.clients.Init(
config.Clients.Persistent,
Context.dhcpServer,
Context.etcHosts,
arpdb,
config.DNS.DnsfilterConf,
)
return nil
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// setupBindOpts overrides bind host/port from the opts.
func setupBindOpts(opts options) (err error) {
if opts.bindPort != 0 {
Pull request: 1163 safesearch vol.2 Merge in DNS/adguard-home from 1163-safesearch-1-2-1 to master Squashed commit of the following: commit d3a5ebef35210019842145074e898129b42f1f2c Merge: b85264ae c6706445 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 15 09:17:53 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 # Conflicts: # CHANGELOG.md commit b85264aefc5f191ac6cb194b519f03ba15829a4e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 14 00:16:07 2023 +0700 home: imp code commit ac2ed7a5ce8db40628e7d4d1c8634641e5f38b0b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 23:02:06 2023 +0700 all: changelog commit f0fccafcb01f50c7051df53bbe9b02cab75aa71e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:42:36 2023 +0700 all: changelog commit 37df29bf6372939644fb28e3d70365496e0cb4f6 Merge: b227b277 595484e0 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:38:57 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit b227b2775b4866d69241ad87acf99700715552cb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:56:01 2023 +0700 all: imp docs commit 6fd39fc3565c3f4bc7a7113d17733c20dfe24d8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:55:03 2023 +0700 home: imp code commit 3bb3bb7c7dcf97b2a5602a7d2b6770c08b4d863d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 12:16:53 2023 +0700 home: imp docs commit 5f573a56a9fd9942ad677fa0fae6b24228dab653 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 11:56:47 2023 +0700 home: imp code commit 23eeb5552cf2510596b2311cc3eda53ac678ffcc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 10 10:57:33 2023 +0700 home: imp code commit 643de2fca1b5917c61fe83e1e472222404f3cd21 Merge: dada6e63 a2053526 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 21:03:08 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit dada6e63ca5324d30775e2da1727da891743f654 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 17:09:03 2023 +0700 all: imp docs commit 81a180d99dd9a995440d5f4e2ebca34678e7d0c7 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 15:12:43 2023 +0700 all: imp code commit fa84877bc777004d246d71d0a9ae0bd9ee568a91 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:53:05 2023 +0700 all: imp code commit 6d7e02e745d72921a693d4f09eec7ce21c2aefd4 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:40:02 2023 +0700 all: imp docs commit 0a4332997070fb8d2fb3a34d32b92f57a325ff06 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 7 22:00:52 2023 +0700 safesearch: fix merge commit 145c2222ba4cf7f8909b816d83829d2217c94243 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 2 11:41:48 2023 +0700 safesearch: fix merge commit 14c6a8005fe15b5d5a39f91b17c96d8670975811 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:50:09 2023 +0700 all: docs commit 2a85c8831866bf1c34c423a289461fc1e32667b5 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:47:00 2023 +0700 all: use safesearch package
2023-03-15 11:31:07 +00:00
config.BindPort = opts.bindPort
Pull request: 1163 safesearch vol.2 Merge in DNS/adguard-home from 1163-safesearch-1-2-1 to master Squashed commit of the following: commit d3a5ebef35210019842145074e898129b42f1f2c Merge: b85264ae c6706445 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 15 09:17:53 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 # Conflicts: # CHANGELOG.md commit b85264aefc5f191ac6cb194b519f03ba15829a4e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 14 00:16:07 2023 +0700 home: imp code commit ac2ed7a5ce8db40628e7d4d1c8634641e5f38b0b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 23:02:06 2023 +0700 all: changelog commit f0fccafcb01f50c7051df53bbe9b02cab75aa71e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:42:36 2023 +0700 all: changelog commit 37df29bf6372939644fb28e3d70365496e0cb4f6 Merge: b227b277 595484e0 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:38:57 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit b227b2775b4866d69241ad87acf99700715552cb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:56:01 2023 +0700 all: imp docs commit 6fd39fc3565c3f4bc7a7113d17733c20dfe24d8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:55:03 2023 +0700 home: imp code commit 3bb3bb7c7dcf97b2a5602a7d2b6770c08b4d863d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 12:16:53 2023 +0700 home: imp docs commit 5f573a56a9fd9942ad677fa0fae6b24228dab653 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 11:56:47 2023 +0700 home: imp code commit 23eeb5552cf2510596b2311cc3eda53ac678ffcc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 10 10:57:33 2023 +0700 home: imp code commit 643de2fca1b5917c61fe83e1e472222404f3cd21 Merge: dada6e63 a2053526 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 21:03:08 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit dada6e63ca5324d30775e2da1727da891743f654 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 17:09:03 2023 +0700 all: imp docs commit 81a180d99dd9a995440d5f4e2ebca34678e7d0c7 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 15:12:43 2023 +0700 all: imp code commit fa84877bc777004d246d71d0a9ae0bd9ee568a91 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:53:05 2023 +0700 all: imp code commit 6d7e02e745d72921a693d4f09eec7ce21c2aefd4 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:40:02 2023 +0700 all: imp docs commit 0a4332997070fb8d2fb3a34d32b92f57a325ff06 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 7 22:00:52 2023 +0700 safesearch: fix merge commit 145c2222ba4cf7f8909b816d83829d2217c94243 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 2 11:41:48 2023 +0700 safesearch: fix merge commit 14c6a8005fe15b5d5a39f91b17c96d8670975811 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:50:09 2023 +0700 all: docs commit 2a85c8831866bf1c34c423a289461fc1e32667b5 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:47:00 2023 +0700 all: use safesearch package
2023-03-15 11:31:07 +00:00
err = checkPorts()
if err != nil {
// Don't wrap the error, because it's informative enough as is.
return err
}
}
if opts.bindHost.IsValid() {
config.BindHost = opts.bindHost
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
return nil
}
// setupDNSFilteringConf sets up DNS filtering configuration settings.
func setupDNSFilteringConf(conf *filtering.Config) (err error) {
const (
dnsTimeout = 3 * time.Second
sbService = "safe browsing"
defaultSafeBrowsingServer = `https://family.adguard-dns.com/dns-query`
sbTXTSuffix = `sb.dns.adguard.com.`
pcService = "parental control"
defaultParentalServer = `https://family.adguard-dns.com/dns-query`
pcTXTSuffix = `pc.dns.adguard.com.`
)
conf.EtcHosts = Context.etcHosts
conf.ConfigModified = onConfigModified
conf.HTTPRegister = httpRegister
conf.DataDir = Context.getDataDir()
conf.Filters = slices.Clone(config.Filters)
conf.WhitelistFilters = slices.Clone(config.WhitelistFilters)
conf.UserRules = slices.Clone(config.UserRules)
conf.HTTPClient = Context.client
cacheTime := time.Duration(conf.CacheTime) * time.Minute
upsOpts := &upstream.Options{
Timeout: dnsTimeout,
ServerIPAddrs: []net.IP{
{94, 140, 14, 15},
{94, 140, 15, 16},
net.ParseIP("2a10:50c0::bad1:ff"),
net.ParseIP("2a10:50c0::bad2:ff"),
},
}
sbUps, err := upstream.AddressToUpstream(defaultSafeBrowsingServer, upsOpts)
if err != nil {
return fmt.Errorf("converting safe browsing server: %w", err)
}
conf.SafeBrowsingChecker = hashprefix.New(&hashprefix.Config{
Upstream: sbUps,
ServiceName: sbService,
TXTSuffix: sbTXTSuffix,
CacheTime: cacheTime,
CacheSize: conf.SafeBrowsingCacheSize,
})
parUps, err := upstream.AddressToUpstream(defaultParentalServer, upsOpts)
if err != nil {
return fmt.Errorf("converting parental server: %w", err)
}
conf.ParentalControlChecker = hashprefix.New(&hashprefix.Config{
Upstream: parUps,
ServiceName: pcService,
TXTSuffix: pcTXTSuffix,
CacheTime: cacheTime,
CacheSize: conf.SafeBrowsingCacheSize,
})
conf.SafeSearchConf.CustomResolver = safeSearchResolver{}
conf.SafeSearch, err = safesearch.NewDefault(
conf.SafeSearchConf,
"default",
conf.SafeSearchCacheSize,
cacheTime,
)
if err != nil {
return fmt.Errorf("initializing safesearch: %w", err)
}
return nil
Pull request: 2271 handle nolint Merge in DNS/adguard-home from 2271-handle-nolint to master Closes #2271. Squashed commit of the following: commit fde5c8795ac79e1f7d02ba8c8e369b5a724a000e Merge: fc2acd898 642dcd647 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Nov 20 17:12:28 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit fc2acd89871de08c39e80ace9e5bb8a7acb7afba Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 17 11:55:29 2020 +0300 dnsforward: fix test output strings commit c4ebae6ea9c293bad239519c44ca5a6c576bb921 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 22:43:20 2020 +0300 dnsfilter: make package pass tests commit f2d98c6acabd8977f3b1b361987eaa31eb6eb9ad Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 20:05:00 2020 +0300 querylog: make decoding pass tests commit ab5850d24c50d53b8393f2de448cc340241351d7 Merge: 6ed2066bf 8a9c6e8a0 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 19:48:31 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit 6ed2066bf567e13dd14cfa16fc7b109b59fa39ef Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 18:13:45 2020 +0300 home: fix tests naming commit af691081fb02b7500a746b16492f01f7f9befe9a Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 12:15:49 2020 +0300 home: impove code quality commit 2914cd3cd23ef2a1964116baab9187d89b377f86 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 15:46:39 2020 +0300 * querylog: remove useless check commit 9996840650e784ccc76d1f29964560435ba27dc7 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 13:18:34 2020 +0300 * all: fix noticed defects commit 2b15293e59337f70302fbc0db81ebb26bee0bed2 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 20:15:53 2020 +0300 * stats: remove last nolint directive commit b2e1ddf7b58196a2fdbf879f084edb41ca1aa1eb Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:35:41 2020 +0300 * all: remove another nolint directive commit c6fc5cfcc9c95ab9e570a95ab41c3e5c0125e62e Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:11:28 2020 +0300 * querylog: remove nolint directive commit 226ddbf2c92f737f085b44a4ddf6daec7b602153 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:35:26 2020 +0300 * home: remove nolint directive commit 2ea3086ad41e9003282add7e996ae722d72d878b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:13:57 2020 +0300 * home: reduce cyclomatic complexity of run function commit f479b480c48e0bb832ddef8f57586f56b8a55bab Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 15:35:46 2020 +0300 * home: use crypto/rand instead of math/rand commit a28d4a53e3b930136b036606fc7e78404f1d208b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 14:11:07 2020 +0300 * dnsforward: remove gocyclo nolint directive commit 64a0a324cc2b20614ceec3ccc6505e960fe526e9 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 11:45:49 2020 +0300 all *: remove some nolint directives Updates #2271.
2020-11-20 14:32:41 +00:00
}
Pull request: 1163 safesearch vol.2 Merge in DNS/adguard-home from 1163-safesearch-1-2-1 to master Squashed commit of the following: commit d3a5ebef35210019842145074e898129b42f1f2c Merge: b85264ae c6706445 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 15 09:17:53 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 # Conflicts: # CHANGELOG.md commit b85264aefc5f191ac6cb194b519f03ba15829a4e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 14 00:16:07 2023 +0700 home: imp code commit ac2ed7a5ce8db40628e7d4d1c8634641e5f38b0b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 23:02:06 2023 +0700 all: changelog commit f0fccafcb01f50c7051df53bbe9b02cab75aa71e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:42:36 2023 +0700 all: changelog commit 37df29bf6372939644fb28e3d70365496e0cb4f6 Merge: b227b277 595484e0 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:38:57 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit b227b2775b4866d69241ad87acf99700715552cb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:56:01 2023 +0700 all: imp docs commit 6fd39fc3565c3f4bc7a7113d17733c20dfe24d8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:55:03 2023 +0700 home: imp code commit 3bb3bb7c7dcf97b2a5602a7d2b6770c08b4d863d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 12:16:53 2023 +0700 home: imp docs commit 5f573a56a9fd9942ad677fa0fae6b24228dab653 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 11:56:47 2023 +0700 home: imp code commit 23eeb5552cf2510596b2311cc3eda53ac678ffcc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 10 10:57:33 2023 +0700 home: imp code commit 643de2fca1b5917c61fe83e1e472222404f3cd21 Merge: dada6e63 a2053526 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 21:03:08 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit dada6e63ca5324d30775e2da1727da891743f654 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 17:09:03 2023 +0700 all: imp docs commit 81a180d99dd9a995440d5f4e2ebca34678e7d0c7 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 15:12:43 2023 +0700 all: imp code commit fa84877bc777004d246d71d0a9ae0bd9ee568a91 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:53:05 2023 +0700 all: imp code commit 6d7e02e745d72921a693d4f09eec7ce21c2aefd4 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:40:02 2023 +0700 all: imp docs commit 0a4332997070fb8d2fb3a34d32b92f57a325ff06 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 7 22:00:52 2023 +0700 safesearch: fix merge commit 145c2222ba4cf7f8909b816d83829d2217c94243 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 2 11:41:48 2023 +0700 safesearch: fix merge commit 14c6a8005fe15b5d5a39f91b17c96d8670975811 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:50:09 2023 +0700 all: docs commit 2a85c8831866bf1c34c423a289461fc1e32667b5 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:47:00 2023 +0700 all: use safesearch package
2023-03-15 11:31:07 +00:00
// checkPorts is a helper for ports validation in config.
func checkPorts() (err error) {
tcpPorts := aghalg.UniqChecker[tcpPort]{}
addPorts(tcpPorts, tcpPort(config.BindPort))
udpPorts := aghalg.UniqChecker[udpPort]{}
addPorts(udpPorts, udpPort(config.DNS.Port))
if config.TLS.Enabled {
addPorts(
tcpPorts,
tcpPort(config.TLS.PortHTTPS),
tcpPort(config.TLS.PortDNSOverTLS),
tcpPort(config.TLS.PortDNSCrypt),
)
addPorts(udpPorts, udpPort(config.TLS.PortDNSOverQUIC))
}
if err = tcpPorts.Validate(); err != nil {
return fmt.Errorf("validating tcp ports: %w", err)
} else if err = udpPorts.Validate(); err != nil {
return fmt.Errorf("validating udp ports: %w", err)
}
return nil
}
func initWeb(opts options, clientBuildFS fs.FS) (web *webAPI, err error) {
var clientFS fs.FS
if opts.localFrontend {
log.Info("warning: using local frontend files")
clientFS = os.DirFS("build/static")
} else {
clientFS, err = fs.Sub(clientBuildFS, "build/static")
if err != nil {
return nil, fmt.Errorf("getting embedded client subdir: %w", err)
}
}
webConf := webConfig{
firstRun: Context.firstRun,
BindHost: config.BindHost,
BindPort: config.BindPort,
ReadTimeout: readTimeout,
ReadHeaderTimeout: readHdrTimeout,
WriteTimeout: writeTimeout,
clientFS: clientFS,
serveHTTP3: config.DNS.ServeHTTP3,
}
web = newWebAPI(&webConf)
if web == nil {
return nil, fmt.Errorf("initializing web: %w", err)
}
return web, nil
}
func fatalOnError(err error) {
if err != nil {
log.Fatal(err)
}
}
// run configures and starts AdGuard Home.
func run(opts options, clientBuildFS fs.FS) {
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// Configure config filename.
initConfigFilename(opts)
Pull request: 2271 handle nolint Merge in DNS/adguard-home from 2271-handle-nolint to master Closes #2271. Squashed commit of the following: commit fde5c8795ac79e1f7d02ba8c8e369b5a724a000e Merge: fc2acd898 642dcd647 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Nov 20 17:12:28 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit fc2acd89871de08c39e80ace9e5bb8a7acb7afba Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 17 11:55:29 2020 +0300 dnsforward: fix test output strings commit c4ebae6ea9c293bad239519c44ca5a6c576bb921 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 22:43:20 2020 +0300 dnsfilter: make package pass tests commit f2d98c6acabd8977f3b1b361987eaa31eb6eb9ad Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 20:05:00 2020 +0300 querylog: make decoding pass tests commit ab5850d24c50d53b8393f2de448cc340241351d7 Merge: 6ed2066bf 8a9c6e8a0 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 19:48:31 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit 6ed2066bf567e13dd14cfa16fc7b109b59fa39ef Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 18:13:45 2020 +0300 home: fix tests naming commit af691081fb02b7500a746b16492f01f7f9befe9a Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 12:15:49 2020 +0300 home: impove code quality commit 2914cd3cd23ef2a1964116baab9187d89b377f86 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 15:46:39 2020 +0300 * querylog: remove useless check commit 9996840650e784ccc76d1f29964560435ba27dc7 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 13:18:34 2020 +0300 * all: fix noticed defects commit 2b15293e59337f70302fbc0db81ebb26bee0bed2 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 20:15:53 2020 +0300 * stats: remove last nolint directive commit b2e1ddf7b58196a2fdbf879f084edb41ca1aa1eb Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:35:41 2020 +0300 * all: remove another nolint directive commit c6fc5cfcc9c95ab9e570a95ab41c3e5c0125e62e Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:11:28 2020 +0300 * querylog: remove nolint directive commit 226ddbf2c92f737f085b44a4ddf6daec7b602153 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:35:26 2020 +0300 * home: remove nolint directive commit 2ea3086ad41e9003282add7e996ae722d72d878b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:13:57 2020 +0300 * home: reduce cyclomatic complexity of run function commit f479b480c48e0bb832ddef8f57586f56b8a55bab Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 15:35:46 2020 +0300 * home: use crypto/rand instead of math/rand commit a28d4a53e3b930136b036606fc7e78404f1d208b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 14:11:07 2020 +0300 * dnsforward: remove gocyclo nolint directive commit 64a0a324cc2b20614ceec3ccc6505e960fe526e9 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 11:45:49 2020 +0300 all *: remove some nolint directives Updates #2271.
2020-11-20 14:32:41 +00:00
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// Configure working dir and config path.
err := initWorkingDir(opts)
fatalOnError(err)
Pull request: 2271 handle nolint Merge in DNS/adguard-home from 2271-handle-nolint to master Closes #2271. Squashed commit of the following: commit fde5c8795ac79e1f7d02ba8c8e369b5a724a000e Merge: fc2acd898 642dcd647 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Nov 20 17:12:28 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit fc2acd89871de08c39e80ace9e5bb8a7acb7afba Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 17 11:55:29 2020 +0300 dnsforward: fix test output strings commit c4ebae6ea9c293bad239519c44ca5a6c576bb921 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 22:43:20 2020 +0300 dnsfilter: make package pass tests commit f2d98c6acabd8977f3b1b361987eaa31eb6eb9ad Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 20:05:00 2020 +0300 querylog: make decoding pass tests commit ab5850d24c50d53b8393f2de448cc340241351d7 Merge: 6ed2066bf 8a9c6e8a0 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 19:48:31 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit 6ed2066bf567e13dd14cfa16fc7b109b59fa39ef Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 18:13:45 2020 +0300 home: fix tests naming commit af691081fb02b7500a746b16492f01f7f9befe9a Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 12:15:49 2020 +0300 home: impove code quality commit 2914cd3cd23ef2a1964116baab9187d89b377f86 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 15:46:39 2020 +0300 * querylog: remove useless check commit 9996840650e784ccc76d1f29964560435ba27dc7 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 13:18:34 2020 +0300 * all: fix noticed defects commit 2b15293e59337f70302fbc0db81ebb26bee0bed2 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 20:15:53 2020 +0300 * stats: remove last nolint directive commit b2e1ddf7b58196a2fdbf879f084edb41ca1aa1eb Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:35:41 2020 +0300 * all: remove another nolint directive commit c6fc5cfcc9c95ab9e570a95ab41c3e5c0125e62e Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:11:28 2020 +0300 * querylog: remove nolint directive commit 226ddbf2c92f737f085b44a4ddf6daec7b602153 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:35:26 2020 +0300 * home: remove nolint directive commit 2ea3086ad41e9003282add7e996ae722d72d878b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:13:57 2020 +0300 * home: reduce cyclomatic complexity of run function commit f479b480c48e0bb832ddef8f57586f56b8a55bab Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 15:35:46 2020 +0300 * home: use crypto/rand instead of math/rand commit a28d4a53e3b930136b036606fc7e78404f1d208b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 14:11:07 2020 +0300 * dnsforward: remove gocyclo nolint directive commit 64a0a324cc2b20614ceec3ccc6505e960fe526e9 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 11:45:49 2020 +0300 all *: remove some nolint directives Updates #2271.
2020-11-20 14:32:41 +00:00
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// Configure log level and output.
err = configureLogger(opts)
fatalOnError(err)
Pull request: 2271 handle nolint Merge in DNS/adguard-home from 2271-handle-nolint to master Closes #2271. Squashed commit of the following: commit fde5c8795ac79e1f7d02ba8c8e369b5a724a000e Merge: fc2acd898 642dcd647 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Nov 20 17:12:28 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit fc2acd89871de08c39e80ace9e5bb8a7acb7afba Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 17 11:55:29 2020 +0300 dnsforward: fix test output strings commit c4ebae6ea9c293bad239519c44ca5a6c576bb921 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 22:43:20 2020 +0300 dnsfilter: make package pass tests commit f2d98c6acabd8977f3b1b361987eaa31eb6eb9ad Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 20:05:00 2020 +0300 querylog: make decoding pass tests commit ab5850d24c50d53b8393f2de448cc340241351d7 Merge: 6ed2066bf 8a9c6e8a0 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 19:48:31 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit 6ed2066bf567e13dd14cfa16fc7b109b59fa39ef Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 18:13:45 2020 +0300 home: fix tests naming commit af691081fb02b7500a746b16492f01f7f9befe9a Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 12:15:49 2020 +0300 home: impove code quality commit 2914cd3cd23ef2a1964116baab9187d89b377f86 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 15:46:39 2020 +0300 * querylog: remove useless check commit 9996840650e784ccc76d1f29964560435ba27dc7 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 13:18:34 2020 +0300 * all: fix noticed defects commit 2b15293e59337f70302fbc0db81ebb26bee0bed2 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 20:15:53 2020 +0300 * stats: remove last nolint directive commit b2e1ddf7b58196a2fdbf879f084edb41ca1aa1eb Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:35:41 2020 +0300 * all: remove another nolint directive commit c6fc5cfcc9c95ab9e570a95ab41c3e5c0125e62e Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:11:28 2020 +0300 * querylog: remove nolint directive commit 226ddbf2c92f737f085b44a4ddf6daec7b602153 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:35:26 2020 +0300 * home: remove nolint directive commit 2ea3086ad41e9003282add7e996ae722d72d878b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:13:57 2020 +0300 * home: reduce cyclomatic complexity of run function commit f479b480c48e0bb832ddef8f57586f56b8a55bab Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 15:35:46 2020 +0300 * home: use crypto/rand instead of math/rand commit a28d4a53e3b930136b036606fc7e78404f1d208b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 14:11:07 2020 +0300 * dnsforward: remove gocyclo nolint directive commit 64a0a324cc2b20614ceec3ccc6505e960fe526e9 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 11:45:49 2020 +0300 all *: remove some nolint directives Updates #2271.
2020-11-20 14:32:41 +00:00
// Print the first message after logger is configured.
log.Info(version.Full())
log.Debug("current working directory is %s", Context.workDir)
if opts.runningAsService {
Pull request: 2271 handle nolint Merge in DNS/adguard-home from 2271-handle-nolint to master Closes #2271. Squashed commit of the following: commit fde5c8795ac79e1f7d02ba8c8e369b5a724a000e Merge: fc2acd898 642dcd647 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Nov 20 17:12:28 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit fc2acd89871de08c39e80ace9e5bb8a7acb7afba Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 17 11:55:29 2020 +0300 dnsforward: fix test output strings commit c4ebae6ea9c293bad239519c44ca5a6c576bb921 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 22:43:20 2020 +0300 dnsfilter: make package pass tests commit f2d98c6acabd8977f3b1b361987eaa31eb6eb9ad Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 20:05:00 2020 +0300 querylog: make decoding pass tests commit ab5850d24c50d53b8393f2de448cc340241351d7 Merge: 6ed2066bf 8a9c6e8a0 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 19:48:31 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit 6ed2066bf567e13dd14cfa16fc7b109b59fa39ef Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 18:13:45 2020 +0300 home: fix tests naming commit af691081fb02b7500a746b16492f01f7f9befe9a Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 12:15:49 2020 +0300 home: impove code quality commit 2914cd3cd23ef2a1964116baab9187d89b377f86 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 15:46:39 2020 +0300 * querylog: remove useless check commit 9996840650e784ccc76d1f29964560435ba27dc7 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 13:18:34 2020 +0300 * all: fix noticed defects commit 2b15293e59337f70302fbc0db81ebb26bee0bed2 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 20:15:53 2020 +0300 * stats: remove last nolint directive commit b2e1ddf7b58196a2fdbf879f084edb41ca1aa1eb Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:35:41 2020 +0300 * all: remove another nolint directive commit c6fc5cfcc9c95ab9e570a95ab41c3e5c0125e62e Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:11:28 2020 +0300 * querylog: remove nolint directive commit 226ddbf2c92f737f085b44a4ddf6daec7b602153 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:35:26 2020 +0300 * home: remove nolint directive commit 2ea3086ad41e9003282add7e996ae722d72d878b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:13:57 2020 +0300 * home: reduce cyclomatic complexity of run function commit f479b480c48e0bb832ddef8f57586f56b8a55bab Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 15:35:46 2020 +0300 * home: use crypto/rand instead of math/rand commit a28d4a53e3b930136b036606fc7e78404f1d208b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 14:11:07 2020 +0300 * dnsforward: remove gocyclo nolint directive commit 64a0a324cc2b20614ceec3ccc6505e960fe526e9 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 11:45:49 2020 +0300 all *: remove some nolint directives Updates #2271.
2020-11-20 14:32:41 +00:00
log.Info("AdGuard Home is running as a service")
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
err = setupContext(opts)
fatalOnError(err)
Pull request: 2271 handle nolint Merge in DNS/adguard-home from 2271-handle-nolint to master Closes #2271. Squashed commit of the following: commit fde5c8795ac79e1f7d02ba8c8e369b5a724a000e Merge: fc2acd898 642dcd647 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Nov 20 17:12:28 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit fc2acd89871de08c39e80ace9e5bb8a7acb7afba Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 17 11:55:29 2020 +0300 dnsforward: fix test output strings commit c4ebae6ea9c293bad239519c44ca5a6c576bb921 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 22:43:20 2020 +0300 dnsfilter: make package pass tests commit f2d98c6acabd8977f3b1b361987eaa31eb6eb9ad Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 20:05:00 2020 +0300 querylog: make decoding pass tests commit ab5850d24c50d53b8393f2de448cc340241351d7 Merge: 6ed2066bf 8a9c6e8a0 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 19:48:31 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit 6ed2066bf567e13dd14cfa16fc7b109b59fa39ef Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 18:13:45 2020 +0300 home: fix tests naming commit af691081fb02b7500a746b16492f01f7f9befe9a Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 12:15:49 2020 +0300 home: impove code quality commit 2914cd3cd23ef2a1964116baab9187d89b377f86 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 15:46:39 2020 +0300 * querylog: remove useless check commit 9996840650e784ccc76d1f29964560435ba27dc7 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 13:18:34 2020 +0300 * all: fix noticed defects commit 2b15293e59337f70302fbc0db81ebb26bee0bed2 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 20:15:53 2020 +0300 * stats: remove last nolint directive commit b2e1ddf7b58196a2fdbf879f084edb41ca1aa1eb Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:35:41 2020 +0300 * all: remove another nolint directive commit c6fc5cfcc9c95ab9e570a95ab41c3e5c0125e62e Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:11:28 2020 +0300 * querylog: remove nolint directive commit 226ddbf2c92f737f085b44a4ddf6daec7b602153 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:35:26 2020 +0300 * home: remove nolint directive commit 2ea3086ad41e9003282add7e996ae722d72d878b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:13:57 2020 +0300 * home: reduce cyclomatic complexity of run function commit f479b480c48e0bb832ddef8f57586f56b8a55bab Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 15:35:46 2020 +0300 * home: use crypto/rand instead of math/rand commit a28d4a53e3b930136b036606fc7e78404f1d208b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 14:11:07 2020 +0300 * dnsforward: remove gocyclo nolint directive commit 64a0a324cc2b20614ceec3ccc6505e960fe526e9 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 11:45:49 2020 +0300 all *: remove some nolint directives Updates #2271.
2020-11-20 14:32:41 +00:00
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
err = configureOS(config)
fatalOnError(err)
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// Clients package uses filtering package's static data
// (filtering.BlockedSvcKnown()), so we have to initialize filtering static
// data first, but also to avoid relying on automatic Go init() function.
filtering.InitModule()
Pull request: 2271 handle nolint Merge in DNS/adguard-home from 2271-handle-nolint to master Closes #2271. Squashed commit of the following: commit fde5c8795ac79e1f7d02ba8c8e369b5a724a000e Merge: fc2acd898 642dcd647 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Nov 20 17:12:28 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit fc2acd89871de08c39e80ace9e5bb8a7acb7afba Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 17 11:55:29 2020 +0300 dnsforward: fix test output strings commit c4ebae6ea9c293bad239519c44ca5a6c576bb921 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 22:43:20 2020 +0300 dnsfilter: make package pass tests commit f2d98c6acabd8977f3b1b361987eaa31eb6eb9ad Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 20:05:00 2020 +0300 querylog: make decoding pass tests commit ab5850d24c50d53b8393f2de448cc340241351d7 Merge: 6ed2066bf 8a9c6e8a0 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 19:48:31 2020 +0300 Merge branch 'master' into 2271-handle-nolint commit 6ed2066bf567e13dd14cfa16fc7b109b59fa39ef Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 18:13:45 2020 +0300 home: fix tests naming commit af691081fb02b7500a746b16492f01f7f9befe9a Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Nov 16 12:15:49 2020 +0300 home: impove code quality commit 2914cd3cd23ef2a1964116baab9187d89b377f86 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 15:46:39 2020 +0300 * querylog: remove useless check commit 9996840650e784ccc76d1f29964560435ba27dc7 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Nov 11 13:18:34 2020 +0300 * all: fix noticed defects commit 2b15293e59337f70302fbc0db81ebb26bee0bed2 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 20:15:53 2020 +0300 * stats: remove last nolint directive commit b2e1ddf7b58196a2fdbf879f084edb41ca1aa1eb Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:35:41 2020 +0300 * all: remove another nolint directive commit c6fc5cfcc9c95ab9e570a95ab41c3e5c0125e62e Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 18:11:28 2020 +0300 * querylog: remove nolint directive commit 226ddbf2c92f737f085b44a4ddf6daec7b602153 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:35:26 2020 +0300 * home: remove nolint directive commit 2ea3086ad41e9003282add7e996ae722d72d878b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 16:13:57 2020 +0300 * home: reduce cyclomatic complexity of run function commit f479b480c48e0bb832ddef8f57586f56b8a55bab Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 15:35:46 2020 +0300 * home: use crypto/rand instead of math/rand commit a28d4a53e3b930136b036606fc7e78404f1d208b Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 14:11:07 2020 +0300 * dnsforward: remove gocyclo nolint directive commit 64a0a324cc2b20614ceec3ccc6505e960fe526e9 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Nov 10 11:45:49 2020 +0300 all *: remove some nolint directives Updates #2271.
2020-11-20 14:32:41 +00:00
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
err = initContextClients()
fatalOnError(err)
err = setupOpts(opts)
fatalOnError(err)
2018-08-30 15:25:33 +01:00
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// TODO(e.burkov): This could be made earlier, probably as the option's
Pull request: 5191-update-flag Merge in DNS/adguard-home from 5191-update-flag to master Updates #5191. Updates #4223. Squashed commit of the following: commit fbace4942844dc67f2467479385e06843c3abb6a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 9 12:05:16 2023 +0400 all: imp code, docs commit 8237dceb771ba95f545f79565d76cbb4ebd0d805 Merge: ca9518f2 bbdcc673 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Dec 30 14:45:55 2022 +0400 Merge branch 'master' into 5191-update-flag commit ca9518f20e5643572adf9734b93a5436ba30c865 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 20:36:33 2022 +0400 home: imp code commit 1dc6c7c3480df3df4a5f3f923f1feab7761a7945 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 18:26:08 2022 +0400 all: imp code, docs commit 7bbe893e98063b956482fd6f1c6be95a4f1956cf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:44:48 2022 +0400 home: restart service on update commit e0d3c287a7e1c05b1e397f4727c447a1fcd9f7f6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:22:49 2022 +0400 all: update on first run commit 0aa4e78f03bf3819425accb468ce59e747506ef3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 02:47:30 2022 +0400 all: move some code to init less commit 68aebfa050b9965afef26653e9b699ff4aaf5b8b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 00:36:00 2022 +0400 WIP commit 2c7fb97d701ac158613c5a3a4d4d35c5b79b3d59 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Dec 28 14:15:59 2022 +0400 home: imp logs commit 4b06d089da835d6d187803bbb5ca1caf9973e2d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Dec 27 19:21:17 2022 +0400 all: fix update flag
2023-01-09 10:38:31 +00:00
// effect.
cmdlineUpdate(opts)
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
if !Context.firstRun {
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// Save the updated config.
err = config.write()
fatalOnError(err)
if config.DebugPProf {
// TODO(a.garipov): Make the address configurable.
startPprof("localhost:6060")
}
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
dir := Context.getDataDir()
err = os.MkdirAll(dir, 0o755)
fatalOnError(errors.Annotate(err, "creating DNS data dir at %s: %w", dir))
2018-08-30 15:25:33 +01:00
GLMode = opts.glinetMode
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// Init auth module.
Context.auth, err = initUsers()
fatalOnError(err)
2020-02-19 12:24:55 +00:00
Context.tls, err = newTLSManager(config.TLS)
if err != nil {
log.Error("initializing tls: %s", err)
onConfigModified()
}
Context.web, err = initWeb(opts, clientBuildFS)
fatalOnError(err)
if !Context.firstRun {
Pull request: 5191-update-flag Merge in DNS/adguard-home from 5191-update-flag to master Updates #5191. Updates #4223. Squashed commit of the following: commit fbace4942844dc67f2467479385e06843c3abb6a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 9 12:05:16 2023 +0400 all: imp code, docs commit 8237dceb771ba95f545f79565d76cbb4ebd0d805 Merge: ca9518f2 bbdcc673 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Dec 30 14:45:55 2022 +0400 Merge branch 'master' into 5191-update-flag commit ca9518f20e5643572adf9734b93a5436ba30c865 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 20:36:33 2022 +0400 home: imp code commit 1dc6c7c3480df3df4a5f3f923f1feab7761a7945 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 18:26:08 2022 +0400 all: imp code, docs commit 7bbe893e98063b956482fd6f1c6be95a4f1956cf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:44:48 2022 +0400 home: restart service on update commit e0d3c287a7e1c05b1e397f4727c447a1fcd9f7f6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:22:49 2022 +0400 all: update on first run commit 0aa4e78f03bf3819425accb468ce59e747506ef3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 02:47:30 2022 +0400 all: move some code to init less commit 68aebfa050b9965afef26653e9b699ff4aaf5b8b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 00:36:00 2022 +0400 WIP commit 2c7fb97d701ac158613c5a3a4d4d35c5b79b3d59 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Dec 28 14:15:59 2022 +0400 home: imp logs commit 4b06d089da835d6d187803bbb5ca1caf9973e2d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Dec 27 19:21:17 2022 +0400 all: fix update flag
2023-01-09 10:38:31 +00:00
err = initDNS()
fatalOnError(err)
Context.tls.start()
go func() {
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
sErr := startDNSServer()
if sErr != nil {
closeDNSServer()
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
fatalOnError(sErr)
}
}()
if Context.dhcpServer != nil {
err = Context.dhcpServer.Start()
if err != nil {
log.Error("starting dhcp server: %s", err)
}
}
}
Context.web.start()
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// Wait indefinitely for other goroutines to complete their job.
select {}
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// initUsers initializes context auth module. Clears config users field.
func initUsers() (auth *Auth, err error) {
sessFilename := filepath.Join(Context.getDataDir(), "sessions.db")
var rateLimiter *authRateLimiter
if config.AuthAttempts > 0 && config.AuthBlockMin > 0 {
blockDur := time.Duration(config.AuthBlockMin) * time.Minute
rateLimiter = newAuthRateLimiter(blockDur, config.AuthAttempts)
} else {
log.Info("authratelimiter is disabled")
}
sessionTTL := config.WebSessionTTLHours * 60 * 60
auth = InitAuth(sessFilename, config.Users, sessionTTL, rateLimiter)
if auth == nil {
return nil, errors.Error("initializing auth module failed")
}
config.Users = nil
return auth, nil
}
Pull request: 5191-update-flag Merge in DNS/adguard-home from 5191-update-flag to master Updates #5191. Updates #4223. Squashed commit of the following: commit fbace4942844dc67f2467479385e06843c3abb6a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 9 12:05:16 2023 +0400 all: imp code, docs commit 8237dceb771ba95f545f79565d76cbb4ebd0d805 Merge: ca9518f2 bbdcc673 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Dec 30 14:45:55 2022 +0400 Merge branch 'master' into 5191-update-flag commit ca9518f20e5643572adf9734b93a5436ba30c865 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 20:36:33 2022 +0400 home: imp code commit 1dc6c7c3480df3df4a5f3f923f1feab7761a7945 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 18:26:08 2022 +0400 all: imp code, docs commit 7bbe893e98063b956482fd6f1c6be95a4f1956cf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:44:48 2022 +0400 home: restart service on update commit e0d3c287a7e1c05b1e397f4727c447a1fcd9f7f6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:22:49 2022 +0400 all: update on first run commit 0aa4e78f03bf3819425accb468ce59e747506ef3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 02:47:30 2022 +0400 all: move some code to init less commit 68aebfa050b9965afef26653e9b699ff4aaf5b8b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 00:36:00 2022 +0400 WIP commit 2c7fb97d701ac158613c5a3a4d4d35c5b79b3d59 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Dec 28 14:15:59 2022 +0400 home: imp logs commit 4b06d089da835d6d187803bbb5ca1caf9973e2d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Dec 27 19:21:17 2022 +0400 all: fix update flag
2023-01-09 10:38:31 +00:00
func (c *configuration) anonymizer() (ipmut *aghnet.IPMut) {
var anonFunc aghnet.IPMutFunc
if c.DNS.AnonymizeClientIP {
anonFunc = querylog.AnonymizeIP
}
return aghnet.NewIPMut(anonFunc)
}
// startMods initializes and starts the DNS server after installation.
Pull request: 5191-update-flag Merge in DNS/adguard-home from 5191-update-flag to master Updates #5191. Updates #4223. Squashed commit of the following: commit fbace4942844dc67f2467479385e06843c3abb6a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 9 12:05:16 2023 +0400 all: imp code, docs commit 8237dceb771ba95f545f79565d76cbb4ebd0d805 Merge: ca9518f2 bbdcc673 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Dec 30 14:45:55 2022 +0400 Merge branch 'master' into 5191-update-flag commit ca9518f20e5643572adf9734b93a5436ba30c865 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 20:36:33 2022 +0400 home: imp code commit 1dc6c7c3480df3df4a5f3f923f1feab7761a7945 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 18:26:08 2022 +0400 all: imp code, docs commit 7bbe893e98063b956482fd6f1c6be95a4f1956cf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:44:48 2022 +0400 home: restart service on update commit e0d3c287a7e1c05b1e397f4727c447a1fcd9f7f6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:22:49 2022 +0400 all: update on first run commit 0aa4e78f03bf3819425accb468ce59e747506ef3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 02:47:30 2022 +0400 all: move some code to init less commit 68aebfa050b9965afef26653e9b699ff4aaf5b8b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 00:36:00 2022 +0400 WIP commit 2c7fb97d701ac158613c5a3a4d4d35c5b79b3d59 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Dec 28 14:15:59 2022 +0400 home: imp logs commit 4b06d089da835d6d187803bbb5ca1caf9973e2d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Dec 27 19:21:17 2022 +0400 all: fix update flag
2023-01-09 10:38:31 +00:00
func startMods() (err error) {
err = initDNS()
if err != nil {
return err
}
Context.tls.start()
err = startDNSServer()
if err != nil {
closeDNSServer()
return err
}
return nil
}
2020-06-23 16:04:26 +01:00
// Check if the current user permissions are enough to run AdGuard Home
func checkPermissions() {
log.Info("Checking if AdGuard Home has necessary permissions")
if ok, err := aghnet.CanBindPrivilegedPorts(); !ok || err != nil {
log.Fatal("This is the first launch of AdGuard Home. You must run it as Administrator.")
}
// We should check if AdGuard Home is able to bind to port 53
err := aghnet.CheckPort("tcp", netip.AddrPortFrom(netutil.IPv4Localhost(), defaultPortDNS))
if err != nil {
if errors.Is(err, os.ErrPermission) {
log.Fatal(`Permission check failed.
AdGuard Home is not allowed to bind to privileged ports (for instance, port 53).
Please note, that this is crucial for a server to be able to use privileged ports.
You have two options:
1. Run AdGuard Home with root privileges
2. On Linux you can grant the CAP_NET_BIND_SERVICE capability:
https://github.com/AdguardTeam/AdGuardHome/wiki/Getting-Started#running-without-superuser`)
}
log.Info(
"AdGuard failed to bind to port 53: %s\n\n"+
"Please note, that this is crucial for a DNS server to be able to use that port.",
err,
)
}
log.Info("AdGuard Home can bind to port 53")
}
// Write PID to a file
func writePIDFile(fn string) bool {
data := fmt.Sprintf("%d", os.Getpid())
err := os.WriteFile(fn, []byte(data), 0o644)
if err != nil {
log.Error("Couldn't write PID to file %s: %v", fn, err)
return false
}
return true
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// initConfigFilename sets up context config file path. This file path can be
// overridden by command-line arguments, or is set to default.
func initConfigFilename(opts options) {
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
Context.configFilename = stringutil.Coalesce(opts.confFilename, "AdGuardHome.yaml")
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// initWorkingDir initializes the workDir. If no command-line arguments are
// specified, the directory with the binary file is used.
func initWorkingDir(opts options) (err error) {
2020-02-11 09:59:21 +00:00
execPath, err := os.Executable()
if err != nil {
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// Don't wrap the error, because it's informative enough as is.
return err
}
if opts.workDir != "" {
2019-02-05 17:35:48 +00:00
// If there is a custom config file, use it's directory as our working dir
Context.workDir = opts.workDir
} else {
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
Context.workDir = filepath.Dir(execPath)
}
Pull request: all: client id support Merge in DNS/adguard-home from 1383-client-id to master Updates #1383. Squashed commit of the following: commit ebe2678bfa9bf651a2cb1e64499b38edcf19a7ad Author: Ildar Kamalov <ik@adguard.com> Date: Wed Jan 27 17:51:59 2021 +0300 - client: check if IP is valid commit 0c330585a170ea149ee75e43dfa65211e057299c Author: Ildar Kamalov <ik@adguard.com> Date: Wed Jan 27 17:07:50 2021 +0300 - client: find clients by client_id commit 71c9593ee35d996846f061e114b7867c3aa3c978 Merge: 9104f161 3e9edd9e Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Jan 27 16:09:45 2021 +0300 Merge branch 'master' into 1383-client-id commit 9104f1615d2d462606c52017df25a422df872cea Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Jan 27 13:28:50 2021 +0300 dnsforward: imp tests commit ed47f26e611ade625a2cc2c2f71a291b796bbf8f Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Jan 27 12:39:52 2021 +0300 dnsforward: fix address commit 98b222ba69a5d265f620c180c960d01c84a1fb3b Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 19:50:31 2021 +0300 home: imp code commit 4f3966548a2d8437d0b68207dd108dd1a6cb7d20 Merge: 199fdc05 c215b820 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 19:45:13 2021 +0300 Merge branch 'master' into 1383-client-id commit 199fdc056f8a8be5500584f3aaee32865188aedc Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 19:20:37 2021 +0300 all: imp tests, logging, etc commit 35ff14f4d534251aecb2ea60baba225f3eed8a3e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Jan 26 18:55:19 2021 +0300 + client: remove block button from clients with client_id commit 32991a0b4c56583a02fb5e00bba95d96000bce20 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Jan 26 18:54:25 2021 +0300 + client: add requests count for client_id commit 2d68df4d2eac4a296d7469923e601dad4575c1a1 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 15:49:50 2021 +0300 stats: handle client ids commit 4e14ab3590328f93a8cd6e9cbe1665baf74f220b Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 13:45:25 2021 +0300 openapi: fix example commit ca9cf3f744fe197cace2c28ddc5bc68f71dad1f3 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 13:37:10 2021 +0300 openapi: improve clients find api docs commit f79876e550c424558b704bc316a4cd04f25db011 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 13:18:52 2021 +0300 home: accept ids in clients find commit 5b72595122aa0bd64debadfd753ed8a0e0840629 Merge: 607e241f abf8f65f Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Jan 25 18:34:56 2021 +0300 Merge branch 'master' into 1383-client-id commit 607e241f1c339dd6397218f70b8301e3de6a1ee0 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Jan 25 18:30:39 2021 +0300 dnsforward: fix quic commit f046352fef93e46234c2bbe8ae316d21034260e5 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Jan 25 16:53:09 2021 +0300 all: remove wildcard requirement commit 3b679489bae82c54177372be453fe184d8f0bab6 Author: Andrey Meshkov <am@adguard.com> Date: Mon Jan 25 16:02:28 2021 +0300 workDir now supports symlinks commit 0647ab4f113de2223f6949df001f42ecab05c995 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Jan 25 14:59:46 2021 +0300 - client: remove wildcard from domain validation commit b1aec04a4ecadc9d65648ed6d284188fecce01c3 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Jan 25 14:55:39 2021 +0300 + client: add form to download mobileconfig ... and 12 more commits
2021-01-27 15:32:13 +00:00
workDir, err := filepath.EvalSymlinks(Context.workDir)
if err != nil {
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// Don't wrap the error, because it's informative enough as is.
return err
Pull request: all: client id support Merge in DNS/adguard-home from 1383-client-id to master Updates #1383. Squashed commit of the following: commit ebe2678bfa9bf651a2cb1e64499b38edcf19a7ad Author: Ildar Kamalov <ik@adguard.com> Date: Wed Jan 27 17:51:59 2021 +0300 - client: check if IP is valid commit 0c330585a170ea149ee75e43dfa65211e057299c Author: Ildar Kamalov <ik@adguard.com> Date: Wed Jan 27 17:07:50 2021 +0300 - client: find clients by client_id commit 71c9593ee35d996846f061e114b7867c3aa3c978 Merge: 9104f161 3e9edd9e Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Jan 27 16:09:45 2021 +0300 Merge branch 'master' into 1383-client-id commit 9104f1615d2d462606c52017df25a422df872cea Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Jan 27 13:28:50 2021 +0300 dnsforward: imp tests commit ed47f26e611ade625a2cc2c2f71a291b796bbf8f Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Jan 27 12:39:52 2021 +0300 dnsforward: fix address commit 98b222ba69a5d265f620c180c960d01c84a1fb3b Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 19:50:31 2021 +0300 home: imp code commit 4f3966548a2d8437d0b68207dd108dd1a6cb7d20 Merge: 199fdc05 c215b820 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 19:45:13 2021 +0300 Merge branch 'master' into 1383-client-id commit 199fdc056f8a8be5500584f3aaee32865188aedc Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 19:20:37 2021 +0300 all: imp tests, logging, etc commit 35ff14f4d534251aecb2ea60baba225f3eed8a3e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Jan 26 18:55:19 2021 +0300 + client: remove block button from clients with client_id commit 32991a0b4c56583a02fb5e00bba95d96000bce20 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Jan 26 18:54:25 2021 +0300 + client: add requests count for client_id commit 2d68df4d2eac4a296d7469923e601dad4575c1a1 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 15:49:50 2021 +0300 stats: handle client ids commit 4e14ab3590328f93a8cd6e9cbe1665baf74f220b Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 13:45:25 2021 +0300 openapi: fix example commit ca9cf3f744fe197cace2c28ddc5bc68f71dad1f3 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 13:37:10 2021 +0300 openapi: improve clients find api docs commit f79876e550c424558b704bc316a4cd04f25db011 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 13:18:52 2021 +0300 home: accept ids in clients find commit 5b72595122aa0bd64debadfd753ed8a0e0840629 Merge: 607e241f abf8f65f Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Jan 25 18:34:56 2021 +0300 Merge branch 'master' into 1383-client-id commit 607e241f1c339dd6397218f70b8301e3de6a1ee0 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Jan 25 18:30:39 2021 +0300 dnsforward: fix quic commit f046352fef93e46234c2bbe8ae316d21034260e5 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Jan 25 16:53:09 2021 +0300 all: remove wildcard requirement commit 3b679489bae82c54177372be453fe184d8f0bab6 Author: Andrey Meshkov <am@adguard.com> Date: Mon Jan 25 16:02:28 2021 +0300 workDir now supports symlinks commit 0647ab4f113de2223f6949df001f42ecab05c995 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Jan 25 14:59:46 2021 +0300 - client: remove wildcard from domain validation commit b1aec04a4ecadc9d65648ed6d284188fecce01c3 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Jan 25 14:55:39 2021 +0300 + client: add form to download mobileconfig ... and 12 more commits
2021-01-27 15:32:13 +00:00
}
Context.workDir = workDir
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
return nil
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// configureLogger configures logger level and output.
func configureLogger(opts options) (err error) {
ls := getLogSettings(opts)
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// Configure logger level.
if ls.Verbose {
Merge: * use upstream servers directly for the internal DNS resolver Close #1212 * Server.Start(config *ServerConfig) -> Start() + Server.Prepare(config *ServerConfig) + Server.Resolve(host string) + Server.Exchange() * rDNS: use internal DNS resolver - clients: fix race in WriteDiskConfig() - fix race: move 'clients' object from 'configuration' to 'HomeContext' Go race detector didn't like our 'clients' object in 'configuration'. + add AGH startup test . Create a configuration file . Start AGH instance . Check Web server . Check DNS server . Wait until the filters are downloaded . Stop and cleanup * move module objects from config.* to Context.* * don't call log.SetLevel() if not necessary This helps to avoid Go race detector's warning * ci.sh: 'make' and then run tests Squashed commit of the following: commit 86500c7f749307f37af4cc8c2a1066f679d0cfad Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 18:08:53 2019 +0300 minor commit 6e6abb9dca3cd250c458bec23aa30d2250a9eb40 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 18:08:31 2019 +0300 * ci.sh: 'make' and then run tests commit 114192eefea6800e565ba9ab238202c006516c27 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 17:50:04 2019 +0300 fix commit d426deea7f02cdfd4c7217a38c59e51251956a0f Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 17:46:33 2019 +0300 tests commit 7b350edf03027895b4e43dee908d0155a9b0ac9b Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:56:12 2019 +0300 fix test commit 2f5f116873bbbfdd4bb7f82a596f9e1f5c2bcfd8 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:48:56 2019 +0300 fix tests commit 3fbdc77f9c34726e2295185279444983652d559e Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:45:00 2019 +0300 linter commit 9da0b6965a2b6863bcd552fa83a4de2866600bb8 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:33:23 2019 +0300 * config.dnsctx.whois -> Context.whois commit c71ebdbdf6efd88c877b2f243c69d3bc00a997d7 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:31:08 2019 +0300 * don't call log.SetLevel() if not necessary This helps to avoid Go race detector's warning commit 0f250220133cefdcb0843a50000cb932802b8324 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 15:28:19 2019 +0300 * rdns: refactor commit c460d8c9414940dac852e390b6c1b4d4fb38dff9 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 14:08:08 2019 +0300 Revert: * stats: serialize access to 'limit' Use 'conf *Config' and update it atomically, as in querylog module. (Note: Race detector still doesn't like it) commit 488bcb884971276de0d5629384b29e22c59ee7e6 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:50:23 2019 +0300 * config.dnsFilter -> Context.dnsFilter commit 86c0a6827a450414b50acec7ebfc5220d13b81e4 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:45:05 2019 +0300 * config.dnsServer -> Context.dnsServer commit ee35ef095ccaabc89e3de0ef52c9b5ed56b36873 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:42:10 2019 +0300 * config.dhcpServer -> Context.dhcpServer commit 1537001cd211099d5fad01696c0b806ae5d257b1 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:39:45 2019 +0300 * config.queryLog -> Context.queryLog commit e5955fe4ff1ef6f41763461b37b502ea25a3d04c Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Dec 10 13:03:18 2019 +0300 * config.httpsServer -> Context.httpsServer commit 6153c10a9ac173e159d1f05e0db1512579b9203c Author: Simon Zolin <s.zolin@adguard.com> Date: Mon Dec 9 20:12:24 2019 +0300 * config.httpServer -> Context.httpServer commit abd021fb94039015cd45c97614e8b78d4694f956 Author: Simon Zolin <s.zolin@adguard.com> Date: Mon Dec 9 20:08:05 2019 +0300 * stats: serialize access to 'limit' commit 38c2decfd87c712100edcabe62a6d4518719cb53 Author: Simon Zolin <s.zolin@adguard.com> Date: Mon Dec 9 19:57:04 2019 +0300 * config.stats -> Context.stats commit 6caf8965ad44db9dce9a7a5103aa8fa305ad9a06 Author: Simon Zolin <s.zolin@adguard.com> Date: Mon Dec 9 19:45:23 2019 +0300 fix Restart() ... and 6 more commits
2019-12-11 09:38:58 +00:00
log.SetLevel(log.DEBUG)
}
// Make sure that we see the microseconds in logs, as networking stuff can
// happen pretty quickly.
log.SetFlags(log.LstdFlags | log.Lmicroseconds)
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// Write logs to stdout by default.
if ls.File == "" {
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
return nil
}
if ls.File == configSyslog {
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
// Use syslog where it is possible and eventlog on Windows.
err = aghos.ConfigureSyslog(serviceName)
if err != nil {
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
return fmt.Errorf("cannot initialize syslog: %w", err)
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
return nil
}
logFilePath := ls.File
if !filepath.IsAbs(logFilePath) {
logFilePath = filepath.Join(Context.workDir, logFilePath)
}
log.SetOutput(&lumberjack.Logger{
Filename: logFilePath,
Compress: ls.Compress,
LocalTime: ls.LocalTime,
MaxBackups: ls.MaxBackups,
MaxSize: ls.MaxSize,
MaxAge: ls.MaxAge,
})
return nil
}
// getLogSettings returns a log settings object properly initialized from opts.
func getLogSettings(opts options) (ls *logSettings) {
ls = readLogSettings()
// Command-line arguments can override config settings.
if opts.verbose || config.Verbose {
ls.Verbose = true
}
Pull request: home: imp code Merge in DNS/adguard-home from home-imp-code to master Squashed commit of the following: commit 459297e189c55393bf0340dd51ec9608d3475e55 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:42:34 2023 +0300 home: imp code commit ab38e1e80fed7b24fe57d4afdc57b70608f65d73 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 11:01:23 2023 +0300 all: lint script commit 7df68b128bf32172ef2e3bf7116f4f72a97baa2b Merge: bcb482714 db52f7a3a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 10 10:59:40 2023 +0300 Merge remote-tracking branch 'origin/master' into home-imp-code commit bcb482714780da882e69c261be08511ea4f36f3b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:48:27 2023 +0300 all: lint script commit 1c017f27715202ec1f40881f069a96f11f9822e8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:45:25 2023 +0300 all: lint script commit ee3d427a7d6ee7e377e67c5eb99eebc7fb1e6acc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:44:53 2023 +0300 home: imp code commit bc50430469123415216e60e178bd8e30fc229300 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 13:12:10 2023 +0300 home: imp code commit fc07e416aeab2612e68cf0e3f933aaed95931115 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:42:32 2023 +0300 aghos: service precheck commit a68480fd9c4cd6f3c89210bee6917c53074f7a82 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu May 4 11:07:05 2023 +0300 home: imp code commit 61b743a340ac1564c48212452c7a9acd1808d352 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:17:21 2023 +0300 all: lint script commit c6fe620510c4af5b65456e90cb3424831334e004 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 17:16:37 2023 +0300 home: imp code commit 4b2fb47ea9c932054ccc72b1fd1d11793c93e39c Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:55:44 2023 +0300 home: imp code commit 63df3e2ab58482920a074cfd5f4188e49a0f8448 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 16:25:38 2023 +0300 home: imp code commit c7f1502f976482c2891e0c64426218b549585e83 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 15:54:30 2023 +0300 home: imp code commit c64cdaf1c82495bb70d9cdcaf7be9eeee9a7c773 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:35:04 2023 +0300 home: imp code commit a50436e040b3a064ef51d5f936b879fe8de72d41 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:24:02 2023 +0300 home: imp code commit 2b66464f472df732ea27cbbe5ac5c673a13bc14b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:11:53 2023 +0300 home: imp code commit 713ce2963c210887faa0a06e41e01e4ebbf96894 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed May 3 14:10:54 2023 +0300 home: imp code
2023-05-10 14:30:03 +01:00
ls.File = stringutil.Coalesce(opts.logFile, config.File, ls.File)
// Handle default log settings overrides.
ls.Compress = config.Compress
ls.LocalTime = config.LocalTime
ls.MaxBackups = config.MaxBackups
ls.MaxSize = config.MaxSize
ls.MaxAge = config.MaxAge
if opts.runningAsService && ls.File == "" && runtime.GOOS == "windows" {
// When running as a Windows service, use eventlog by default if
// nothing else is configured. Otherwise, we'll lose the log output.
ls.File = configSyslog
}
return ls
2018-08-30 15:25:33 +01:00
}
// cleanup stops and resets all the modules.
func cleanup(ctx context.Context) {
log.Info("stopping AdGuard Home")
2020-02-19 12:24:55 +00:00
if Context.web != nil {
Context.web.close(ctx)
2020-02-19 12:24:55 +00:00
Context.web = nil
}
if Context.auth != nil {
Context.auth.Close()
Context.auth = nil
}
err := stopDNSServer()
if err != nil {
log.Error("stopping dns server: %s", err)
}
if Context.dhcpServer != nil {
err = Context.dhcpServer.Stop()
if err != nil {
log.Error("stopping dhcp server: %s", err)
}
}
Pull request: 2499 merge rewrites vol.1 Merge in DNS/adguard-home from 2499-merge-rewrites-vol.1 to master Updates #2499. Squashed commit of the following: commit 6b308bc2b360cee8c22e506f31d62bacb4bf8fb3 Merge: f49e9186 2b635bf6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 19:23:07 2021 +0300 Merge branch 'master' into 2499-merge-rewrites-vol.1 commit f49e9186ffc8b7074d03c6721ee56cdb09243684 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 18:50:49 2021 +0300 aghos: fix fs events filtering commit 567dd646556606212af5dab60e3ecbb8fff22c25 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 16:50:37 2021 +0300 all: imp code, docs, fix windows commit 140c8bf519345eb54d0e7500a996fcf465353d71 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 19:41:53 2021 +0300 aghnet: use const commit bebf3f76bd394a498ccad812c57d4507c69529ba Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 19:32:37 2021 +0300 all: imp tests, docs commit 9bfdbb6eb454833135d616e208e82699f98e2562 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 18:42:20 2021 +0300 all: imp path more, imp docs commit ee9ea4c132a6b17787d150bf2bee703abaa57be3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 16:09:46 2021 +0300 all: fix windows, imp paths commit 6fac8338a81e9ecfebfc23a1adcb964e89f6aee6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Oct 11 19:53:35 2021 +0300 all: imp code, docs commit da1ce1a2a3dd2be3fdff2412a6dbd596859dc249 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Oct 11 18:22:50 2021 +0300 aghnet: fix windows tests commit d29de359ed68118d71efb226a8433fac15ff5c66 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Oct 8 21:02:14 2021 +0300 all: repl & imp commit 1356c08944cdbb85ce5532d90fe5b077219ce5ff Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Oct 8 01:41:19 2021 +0300 all: add tests, mv logic, added tmpfs commit f4b11adf8998bc8d9d955c5ac9f386f671bd5213 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 7 14:26:30 2021 +0300 all: imp filewalker, refactor hosts container
2021-10-14 17:39:21 +01:00
if Context.etcHosts != nil {
if err = Context.etcHosts.Close(); err != nil {
log.Error("closing hosts container: %s", err)
Pull request: 2499 merge rewrites vol.1 Merge in DNS/adguard-home from 2499-merge-rewrites-vol.1 to master Updates #2499. Squashed commit of the following: commit 6b308bc2b360cee8c22e506f31d62bacb4bf8fb3 Merge: f49e9186 2b635bf6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 19:23:07 2021 +0300 Merge branch 'master' into 2499-merge-rewrites-vol.1 commit f49e9186ffc8b7074d03c6721ee56cdb09243684 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 18:50:49 2021 +0300 aghos: fix fs events filtering commit 567dd646556606212af5dab60e3ecbb8fff22c25 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 14 16:50:37 2021 +0300 all: imp code, docs, fix windows commit 140c8bf519345eb54d0e7500a996fcf465353d71 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 19:41:53 2021 +0300 aghnet: use const commit bebf3f76bd394a498ccad812c57d4507c69529ba Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 19:32:37 2021 +0300 all: imp tests, docs commit 9bfdbb6eb454833135d616e208e82699f98e2562 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 18:42:20 2021 +0300 all: imp path more, imp docs commit ee9ea4c132a6b17787d150bf2bee703abaa57be3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Oct 13 16:09:46 2021 +0300 all: fix windows, imp paths commit 6fac8338a81e9ecfebfc23a1adcb964e89f6aee6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Oct 11 19:53:35 2021 +0300 all: imp code, docs commit da1ce1a2a3dd2be3fdff2412a6dbd596859dc249 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Oct 11 18:22:50 2021 +0300 aghnet: fix windows tests commit d29de359ed68118d71efb226a8433fac15ff5c66 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Oct 8 21:02:14 2021 +0300 all: repl & imp commit 1356c08944cdbb85ce5532d90fe5b077219ce5ff Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Oct 8 01:41:19 2021 +0300 all: add tests, mv logic, added tmpfs commit f4b11adf8998bc8d9d955c5ac9f386f671bd5213 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Oct 7 14:26:30 2021 +0300 all: imp filewalker, refactor hosts container
2021-10-14 17:39:21 +01:00
}
}
Merge: + DNS: use rules from /etc/hosts - fix filtering logic: don't do DNS response check for Rewrite rules Close #1478 Squashed commit of the following: commit 1206b94881289ff664b7c8998ea97c1455da1ff8 Merge: c462577a 5fe98474 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Mar 20 15:00:25 2020 +0300 Merge remote-tracking branch 'origin/master' into 1478-auto-records commit c462577ad84754f5b3ea4cd58339838af817fe36 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Mar 20 14:33:17 2020 +0300 minor commit 7e824ba5f432648a976bc4b8076a645ba875ef70 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Mar 20 14:29:54 2020 +0300 more tests commit a22b62136c5cfd84cd0450897aef9e7d2e20585a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Mar 20 14:09:52 2020 +0300 rename, move commit 9e5ed49ad3c27c57d540edf18b78d29e56afb067 Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Mar 19 15:33:27 2020 +0300 fix logic - don't do DNS response check for Rewrite rules commit 6cfabc0348a41883b8bba834626a7e8760b76bf2 Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Mar 19 11:35:07 2020 +0300 minor commit 4540aed9327566078e5087d43c30f4e8bffab7b9 Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Mar 19 11:03:24 2020 +0300 fix commit 9ddddf7bded812da48613cc07084e360c15ddd0e Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Mar 19 10:49:13 2020 +0300 fix commit c5f8ef745b6f2a768be8a2ab23ad80b01b0aa54f Author: Simon Zolin <s.zolin@adguard.com> Date: Thu Mar 19 10:37:26 2020 +0300 fix commit f4be00947bf0528c9a7cd4f09c4090db444c4694 Author: Simon Zolin <s.zolin@adguard.com> Date: Mon Mar 16 20:13:00 2020 +0300 + auto DNS records from /etc/hosts
2020-03-20 12:05:43 +00:00
if Context.tls != nil {
Context.tls = nil
}
}
// This function is called before application exits
func cleanupAlways() {
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
if len(Context.pidFileName) != 0 {
_ = os.Remove(Context.pidFileName)
}
log.Info("stopped")
}
func exitWithError() {
os.Exit(64)
}
// loadCmdLineOpts reads command line arguments and initializes configuration
// from them. If there is an error or an effect, loadCmdLineOpts processes them
// and exits.
func loadCmdLineOpts() (opts options) {
opts, eff, err := parseCmdOpts(os.Args[0], os.Args[1:])
if err != nil {
log.Error(err.Error())
printHelp(os.Args[0])
exitWithError()
}
if eff != nil {
err = eff()
if err != nil {
log.Error(err.Error())
exitWithError()
2019-01-24 17:11:01 +00:00
}
os.Exit(0)
2019-01-24 17:11:01 +00:00
}
return opts
2019-01-24 17:11:01 +00:00
}
// printWebAddrs prints addresses built from proto, addr, and an appropriate
// port. At least one address is printed with the value of port. Output
// example:
//
// go to http://127.0.0.1:80
func printWebAddrs(proto, addr string, port int) {
log.Printf("go to %s://%s", proto, netutil.JoinHostPort(addr, port))
}
// printHTTPAddresses prints the IP addresses which user can use to access the
// admin interface. proto is either schemeHTTP or schemeHTTPS.
func printHTTPAddresses(proto string) {
tlsConf := tlsConfigSettings{}
if Context.tls != nil {
Context.tls.WriteDiskConfig(&tlsConf)
}
port := config.BindPort
Pull request: 4871 imp filtering Merge in DNS/adguard-home from 4871-imp-filtering to master Closes #4871. Squashed commit of the following: commit 618e7c558447703c114332708c94ef1b34362cf9 Merge: 41ff8ab7 11e4f091 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 19:27:08 2022 +0300 Merge branch 'master' into 4871-imp-filtering commit 41ff8ab755a87170e7334dedcae00f01dcca238a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 19:26:11 2022 +0300 filtering: imp code, log commit e4ae1d1788406ffd7ef0fcc6df896a22b0c2db37 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 14:11:07 2022 +0300 filtering: move handlers into single func commit f7a340b4c10980f512ae935a156f02b0133a1627 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 21 19:21:09 2022 +0300 all: imp code commit e064bf4d3de0283e4bda2aaf5b9822bb8a08f4a6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 20:12:16 2022 +0300 all: imp name commit e7eda3905762f0821e1be1ac3cf77e0ecbedeff4 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:51:23 2022 +0300 all: finally get rid of filtering commit 188550d873e625cc2951583bb3a2eaad036745f5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:36:03 2022 +0300 filtering: merge refresh commit e54ed9c7952b17e66b790c835269b28fbc26f9ca Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:16:23 2022 +0300 filtering: merge filters commit 32da31b754a319487d5f9d5e81e607d349b90180 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 14:48:13 2022 +0300 filtering: imp docs commit 43b0cafa7a27bb9b620c2ba50ccdddcf32cfcecc Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 14:38:04 2022 +0300 all: imp code commit 253a2ea6c92815d364546e34d631e406dd604644 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 20:43:15 2022 +0300 filtering: rm important flag commit 1b87f08f946389d410f13412c7e486290d5e752d Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 17:05:40 2022 +0300 all: move filtering to the package commit daa13499f1dd4fe475c4b75769e34f1eb0915bdf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 15:13:55 2022 +0300 all: finish merging commit d6db75eb2e1f23528e9200ea51507eb793eefa3c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 16 18:18:14 2022 +0300 all: continue merging commit 45b4c484deb7198a469aa18d719bb9dbe81e5d22 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 14 15:44:22 2022 +0300 all: merge filtering types
2022-09-23 11:23:35 +01:00
if proto == aghhttp.SchemeHTTPS {
port = tlsConf.PortHTTPS
}
// TODO(e.burkov): Inspect and perhaps merge with the previous condition.
Pull request: 4871 imp filtering Merge in DNS/adguard-home from 4871-imp-filtering to master Closes #4871. Squashed commit of the following: commit 618e7c558447703c114332708c94ef1b34362cf9 Merge: 41ff8ab7 11e4f091 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 19:27:08 2022 +0300 Merge branch 'master' into 4871-imp-filtering commit 41ff8ab755a87170e7334dedcae00f01dcca238a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 19:26:11 2022 +0300 filtering: imp code, log commit e4ae1d1788406ffd7ef0fcc6df896a22b0c2db37 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 22 14:11:07 2022 +0300 filtering: move handlers into single func commit f7a340b4c10980f512ae935a156f02b0133a1627 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 21 19:21:09 2022 +0300 all: imp code commit e064bf4d3de0283e4bda2aaf5b9822bb8a08f4a6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 20:12:16 2022 +0300 all: imp name commit e7eda3905762f0821e1be1ac3cf77e0ecbedeff4 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:51:23 2022 +0300 all: finally get rid of filtering commit 188550d873e625cc2951583bb3a2eaad036745f5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:36:03 2022 +0300 filtering: merge refresh commit e54ed9c7952b17e66b790c835269b28fbc26f9ca Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 17:16:23 2022 +0300 filtering: merge filters commit 32da31b754a319487d5f9d5e81e607d349b90180 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 14:48:13 2022 +0300 filtering: imp docs commit 43b0cafa7a27bb9b620c2ba50ccdddcf32cfcecc Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Sep 20 14:38:04 2022 +0300 all: imp code commit 253a2ea6c92815d364546e34d631e406dd604644 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 20:43:15 2022 +0300 filtering: rm important flag commit 1b87f08f946389d410f13412c7e486290d5e752d Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 17:05:40 2022 +0300 all: move filtering to the package commit daa13499f1dd4fe475c4b75769e34f1eb0915bdf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 19 15:13:55 2022 +0300 all: finish merging commit d6db75eb2e1f23528e9200ea51507eb793eefa3c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 16 18:18:14 2022 +0300 all: continue merging commit 45b4c484deb7198a469aa18d719bb9dbe81e5d22 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 14 15:44:22 2022 +0300 all: merge filtering types
2022-09-23 11:23:35 +01:00
if proto == aghhttp.SchemeHTTPS && tlsConf.ServerName != "" {
printWebAddrs(proto, tlsConf.ServerName, tlsConf.PortHTTPS)
return
}
bindhost := config.BindHost
if !bindhost.IsUnspecified() {
printWebAddrs(proto, bindhost.String(), port)
return
}
ifaces, err := aghnet.GetValidNetInterfacesForWeb()
if err != nil {
log.Error("web: getting iface ips: %s", err)
// That's weird, but we'll ignore it.
//
// TODO(e.burkov): Find out when it happens.
printWebAddrs(proto, bindhost.String(), port)
return
}
for _, iface := range ifaces {
for _, addr := range iface.Addresses {
printWebAddrs(proto, addr.String(), config.BindPort)
}
}
}
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
// -------------------
// first run / install
// -------------------
func detectFirstRun() bool {
configfile := Context.configFilename
if !filepath.IsAbs(configfile) {
configfile = filepath.Join(Context.workDir, Context.configFilename)
}
_, err := os.Stat(configfile)
Pull request: all: client id support Merge in DNS/adguard-home from 1383-client-id to master Updates #1383. Squashed commit of the following: commit ebe2678bfa9bf651a2cb1e64499b38edcf19a7ad Author: Ildar Kamalov <ik@adguard.com> Date: Wed Jan 27 17:51:59 2021 +0300 - client: check if IP is valid commit 0c330585a170ea149ee75e43dfa65211e057299c Author: Ildar Kamalov <ik@adguard.com> Date: Wed Jan 27 17:07:50 2021 +0300 - client: find clients by client_id commit 71c9593ee35d996846f061e114b7867c3aa3c978 Merge: 9104f161 3e9edd9e Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Jan 27 16:09:45 2021 +0300 Merge branch 'master' into 1383-client-id commit 9104f1615d2d462606c52017df25a422df872cea Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Jan 27 13:28:50 2021 +0300 dnsforward: imp tests commit ed47f26e611ade625a2cc2c2f71a291b796bbf8f Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed Jan 27 12:39:52 2021 +0300 dnsforward: fix address commit 98b222ba69a5d265f620c180c960d01c84a1fb3b Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 19:50:31 2021 +0300 home: imp code commit 4f3966548a2d8437d0b68207dd108dd1a6cb7d20 Merge: 199fdc05 c215b820 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 19:45:13 2021 +0300 Merge branch 'master' into 1383-client-id commit 199fdc056f8a8be5500584f3aaee32865188aedc Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 19:20:37 2021 +0300 all: imp tests, logging, etc commit 35ff14f4d534251aecb2ea60baba225f3eed8a3e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Jan 26 18:55:19 2021 +0300 + client: remove block button from clients with client_id commit 32991a0b4c56583a02fb5e00bba95d96000bce20 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Jan 26 18:54:25 2021 +0300 + client: add requests count for client_id commit 2d68df4d2eac4a296d7469923e601dad4575c1a1 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 15:49:50 2021 +0300 stats: handle client ids commit 4e14ab3590328f93a8cd6e9cbe1665baf74f220b Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 13:45:25 2021 +0300 openapi: fix example commit ca9cf3f744fe197cace2c28ddc5bc68f71dad1f3 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 13:37:10 2021 +0300 openapi: improve clients find api docs commit f79876e550c424558b704bc316a4cd04f25db011 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Jan 26 13:18:52 2021 +0300 home: accept ids in clients find commit 5b72595122aa0bd64debadfd753ed8a0e0840629 Merge: 607e241f abf8f65f Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Jan 25 18:34:56 2021 +0300 Merge branch 'master' into 1383-client-id commit 607e241f1c339dd6397218f70b8301e3de6a1ee0 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Jan 25 18:30:39 2021 +0300 dnsforward: fix quic commit f046352fef93e46234c2bbe8ae316d21034260e5 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Mon Jan 25 16:53:09 2021 +0300 all: remove wildcard requirement commit 3b679489bae82c54177372be453fe184d8f0bab6 Author: Andrey Meshkov <am@adguard.com> Date: Mon Jan 25 16:02:28 2021 +0300 workDir now supports symlinks commit 0647ab4f113de2223f6949df001f42ecab05c995 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Jan 25 14:59:46 2021 +0300 - client: remove wildcard from domain validation commit b1aec04a4ecadc9d65648ed6d284188fecce01c3 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Jan 25 14:55:39 2021 +0300 + client: add form to download mobileconfig ... and 12 more commits
2021-01-27 15:32:13 +00:00
return errors.Is(err, os.ErrNotExist)
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
}
// Connect to a remote server resolving hostname using our own DNS server.
//
// TODO(e.burkov): This messy logic should be decomposed and clarified.
//
// TODO(a.garipov): Support network.
func customDialContext(ctx context.Context, network, addr string) (conn net.Conn, err error) {
log.Debug("home: customdial: dialing addr %q for network %s", addr, network)
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
host, port, err := net.SplitHostPort(addr)
if err != nil {
return nil, err
}
dialer := &net.Dialer{
Timeout: time.Minute * 5,
}
if net.ParseIP(host) != nil || config.DNS.Port == 0 {
return dialer.DialContext(ctx, network, addr)
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
}
addrs, err := Context.dnsServer.Resolve(host)
if err != nil {
return nil, fmt.Errorf("resolving %q: %w", host, err)
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
}
log.Debug("dnsServer.Resolve: %q: %v", host, addrs)
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
if len(addrs) == 0 {
return nil, fmt.Errorf("couldn't lookup host: %q", host)
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
}
var dialErrs []error
for _, a := range addrs {
addr = net.JoinHostPort(a.String(), port)
conn, err = dialer.DialContext(ctx, network, addr)
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
if err != nil {
dialErrs = append(dialErrs, err)
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
continue
}
return conn, err
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
}
return nil, errors.List(fmt.Sprintf("couldn't dial to %s", addr), dialErrs...)
Fix #1069 install: check static ip Squashed commit of the following: commit 57466233cbeb89aff82d8610778f7c3b60fe8426 Merge: 2df5f281 867bf545 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:39:15 2020 +0300 Merge branch 'master' into 1069-install-static-ip commit 2df5f281c4f5949b92edd4747ece60ff73799e54 Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 18:35:54 2020 +0300 *: lang fix commit b4649a6b2781741979531faf862b88c2557f1445 Merge: c2785253 f61d5f0f Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 16:47:30 2020 +0300 *(home): fixed issues with setting static IP on Mac commit c27852537d2f5ce62b16c43f4241a15d0fb8c9fd Author: Andrey Meshkov <am@adguard.com> Date: Thu Feb 13 14:14:30 2020 +0300 +(dhcpd): added static IP for MacOS commit f61d5f0f85a954120b2676a5153f10a05662cf42 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 14:13:35 2020 +0300 + client: show confirm before setting static IP commit 7afa16fbe76dff4485d166f6164bae171e0110c9 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:51:52 2020 +0300 - client: fix text commit 019bff0851c584302fa44317fc748b3319be9470 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Thu Feb 13 13:49:16 2020 +0300 - client: pass all params to the check_config request commit 194bed72f567ae815cbd424e2df1ac5be65e0c02 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 17:12:16 2020 +0300 *: fix home_test commit 9359f6b55f5e36dd311fb85b6a83bb6227308f03 Merge: ae299058 c5ca2a77 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:54:54 2020 +0300 Merge with master commit ae2990582defd8062b99c546b2a932a8ba06c35d Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:53:36 2020 +0300 *(global): refactoring - moved runtime properties to Context commit d8d48c53869a94d18c5ea7bcf78613e83b24bfd8 Author: Andrey Meshkov <am@adguard.com> Date: Wed Feb 12 15:04:25 2020 +0300 *(dhcpd): refactoring, use dhcpd/network_utils where possible commit 8d039c572f0e5f5245bd155a4e4d35400e6962c6 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:37:39 2020 +0300 - client: fix button position commit 26c47e59dd63317bdb959cb416e7c1c0bfdf7dc1 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Feb 7 18:08:56 2020 +0300 - client: fix static ip description commit cb12babc4698d048478570303af8955a35e8531d Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 17:08:39 2020 +0300 *: lower log level for some commands commit d9001ff84852d708e400d039503141929e06d774 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 16:17:59 2020 +0300 *(documentation): updated openapi commit 1d213d53c88d5009a4b1d33d4cfa9e215c644bec Merge: 8406d7d2 80861860 Author: Andrey Meshkov <am@adguard.com> Date: Fri Feb 7 15:16:46 2020 +0300 *: merge with master commit 8406d7d28827ce1ed9d9f6770ce1700681811535 Author: Ildar Kamalov <i.kamalov@adguard.com> Date: Fri Jan 31 16:52:22 2020 +0300 - client: fix locales commit fb476b011768367be51010c89754dcd23b383f5a Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:29:03 2020 +0300 linter commit 84b5708e71c88a9643d402ab630270f5e7bf35b8 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:27:53 2020 +0300 linter commit 143a86a28a3465776f803f6b99b9f3c64b26400e Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Jan 31 13:26:47 2020 +0300 linter ... and 7 more commits
2020-02-13 15:42:07 +00:00
}
2020-03-12 12:11:08 +00:00
func getHTTPProxy(_ *http.Request) (*url.URL, error) {
if config.ProxyURL == "" {
2020-03-12 12:11:08 +00:00
return nil, nil
}
2020-03-12 12:11:08 +00:00
return url.Parse(config.ProxyURL)
}
// jsonError is a generic JSON error response.
//
Pull request: 5191-update-flag Merge in DNS/adguard-home from 5191-update-flag to master Updates #5191. Updates #4223. Squashed commit of the following: commit fbace4942844dc67f2467479385e06843c3abb6a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 9 12:05:16 2023 +0400 all: imp code, docs commit 8237dceb771ba95f545f79565d76cbb4ebd0d805 Merge: ca9518f2 bbdcc673 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Dec 30 14:45:55 2022 +0400 Merge branch 'master' into 5191-update-flag commit ca9518f20e5643572adf9734b93a5436ba30c865 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 20:36:33 2022 +0400 home: imp code commit 1dc6c7c3480df3df4a5f3f923f1feab7761a7945 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 18:26:08 2022 +0400 all: imp code, docs commit 7bbe893e98063b956482fd6f1c6be95a4f1956cf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:44:48 2022 +0400 home: restart service on update commit e0d3c287a7e1c05b1e397f4727c447a1fcd9f7f6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:22:49 2022 +0400 all: update on first run commit 0aa4e78f03bf3819425accb468ce59e747506ef3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 02:47:30 2022 +0400 all: move some code to init less commit 68aebfa050b9965afef26653e9b699ff4aaf5b8b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 00:36:00 2022 +0400 WIP commit 2c7fb97d701ac158613c5a3a4d4d35c5b79b3d59 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Dec 28 14:15:59 2022 +0400 home: imp logs commit 4b06d089da835d6d187803bbb5ca1caf9973e2d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Dec 27 19:21:17 2022 +0400 all: fix update flag
2023-01-09 10:38:31 +00:00
// TODO(a.garipov): Merge together with the implementations in [dhcpd] and other
// packages after refactoring the web handler registering.
type jsonError struct {
// Message is the error message, an opaque string.
Message string `json:"message"`
}
// cmdlineUpdate updates current application and exits.
func cmdlineUpdate(opts options) {
if !opts.performUpdate {
return
}
Pull request: 5191-update-flag Merge in DNS/adguard-home from 5191-update-flag to master Updates #5191. Updates #4223. Squashed commit of the following: commit fbace4942844dc67f2467479385e06843c3abb6a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 9 12:05:16 2023 +0400 all: imp code, docs commit 8237dceb771ba95f545f79565d76cbb4ebd0d805 Merge: ca9518f2 bbdcc673 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Dec 30 14:45:55 2022 +0400 Merge branch 'master' into 5191-update-flag commit ca9518f20e5643572adf9734b93a5436ba30c865 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 20:36:33 2022 +0400 home: imp code commit 1dc6c7c3480df3df4a5f3f923f1feab7761a7945 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 18:26:08 2022 +0400 all: imp code, docs commit 7bbe893e98063b956482fd6f1c6be95a4f1956cf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:44:48 2022 +0400 home: restart service on update commit e0d3c287a7e1c05b1e397f4727c447a1fcd9f7f6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:22:49 2022 +0400 all: update on first run commit 0aa4e78f03bf3819425accb468ce59e747506ef3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 02:47:30 2022 +0400 all: move some code to init less commit 68aebfa050b9965afef26653e9b699ff4aaf5b8b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 00:36:00 2022 +0400 WIP commit 2c7fb97d701ac158613c5a3a4d4d35c5b79b3d59 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Dec 28 14:15:59 2022 +0400 home: imp logs commit 4b06d089da835d6d187803bbb5ca1caf9973e2d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Dec 27 19:21:17 2022 +0400 all: fix update flag
2023-01-09 10:38:31 +00:00
// Initialize the DNS server to use the internal resolver which the updater
// needs to be able to resolve the update source hostname.
//
// TODO(e.burkov): We could probably initialize the internal resolver
// separately.
err := initDNSServer(nil, nil, nil, nil, nil, nil, &tlsConfigSettings{})
fatalOnError(err)
Pull request: 5191-update-flag Merge in DNS/adguard-home from 5191-update-flag to master Updates #5191. Updates #4223. Squashed commit of the following: commit fbace4942844dc67f2467479385e06843c3abb6a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 9 12:05:16 2023 +0400 all: imp code, docs commit 8237dceb771ba95f545f79565d76cbb4ebd0d805 Merge: ca9518f2 bbdcc673 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Dec 30 14:45:55 2022 +0400 Merge branch 'master' into 5191-update-flag commit ca9518f20e5643572adf9734b93a5436ba30c865 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 20:36:33 2022 +0400 home: imp code commit 1dc6c7c3480df3df4a5f3f923f1feab7761a7945 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 18:26:08 2022 +0400 all: imp code, docs commit 7bbe893e98063b956482fd6f1c6be95a4f1956cf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:44:48 2022 +0400 home: restart service on update commit e0d3c287a7e1c05b1e397f4727c447a1fcd9f7f6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:22:49 2022 +0400 all: update on first run commit 0aa4e78f03bf3819425accb468ce59e747506ef3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 02:47:30 2022 +0400 all: move some code to init less commit 68aebfa050b9965afef26653e9b699ff4aaf5b8b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 00:36:00 2022 +0400 WIP commit 2c7fb97d701ac158613c5a3a4d4d35c5b79b3d59 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Dec 28 14:15:59 2022 +0400 home: imp logs commit 4b06d089da835d6d187803bbb5ca1caf9973e2d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Dec 27 19:21:17 2022 +0400 all: fix update flag
2023-01-09 10:38:31 +00:00
log.Info("cmdline update: performing update")
Pull request: 5191-update-flag Merge in DNS/adguard-home from 5191-update-flag to master Updates #5191. Updates #4223. Squashed commit of the following: commit fbace4942844dc67f2467479385e06843c3abb6a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 9 12:05:16 2023 +0400 all: imp code, docs commit 8237dceb771ba95f545f79565d76cbb4ebd0d805 Merge: ca9518f2 bbdcc673 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Dec 30 14:45:55 2022 +0400 Merge branch 'master' into 5191-update-flag commit ca9518f20e5643572adf9734b93a5436ba30c865 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 20:36:33 2022 +0400 home: imp code commit 1dc6c7c3480df3df4a5f3f923f1feab7761a7945 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 18:26:08 2022 +0400 all: imp code, docs commit 7bbe893e98063b956482fd6f1c6be95a4f1956cf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:44:48 2022 +0400 home: restart service on update commit e0d3c287a7e1c05b1e397f4727c447a1fcd9f7f6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:22:49 2022 +0400 all: update on first run commit 0aa4e78f03bf3819425accb468ce59e747506ef3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 02:47:30 2022 +0400 all: move some code to init less commit 68aebfa050b9965afef26653e9b699ff4aaf5b8b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 00:36:00 2022 +0400 WIP commit 2c7fb97d701ac158613c5a3a4d4d35c5b79b3d59 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Dec 28 14:15:59 2022 +0400 home: imp logs commit 4b06d089da835d6d187803bbb5ca1caf9973e2d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Dec 27 19:21:17 2022 +0400 all: fix update flag
2023-01-09 10:38:31 +00:00
updater := Context.updater
info, err := updater.VersionInfo(true)
if err != nil {
Pull request: 5191-update-flag Merge in DNS/adguard-home from 5191-update-flag to master Updates #5191. Updates #4223. Squashed commit of the following: commit fbace4942844dc67f2467479385e06843c3abb6a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 9 12:05:16 2023 +0400 all: imp code, docs commit 8237dceb771ba95f545f79565d76cbb4ebd0d805 Merge: ca9518f2 bbdcc673 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Dec 30 14:45:55 2022 +0400 Merge branch 'master' into 5191-update-flag commit ca9518f20e5643572adf9734b93a5436ba30c865 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 20:36:33 2022 +0400 home: imp code commit 1dc6c7c3480df3df4a5f3f923f1feab7761a7945 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 18:26:08 2022 +0400 all: imp code, docs commit 7bbe893e98063b956482fd6f1c6be95a4f1956cf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:44:48 2022 +0400 home: restart service on update commit e0d3c287a7e1c05b1e397f4727c447a1fcd9f7f6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:22:49 2022 +0400 all: update on first run commit 0aa4e78f03bf3819425accb468ce59e747506ef3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 02:47:30 2022 +0400 all: move some code to init less commit 68aebfa050b9965afef26653e9b699ff4aaf5b8b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 00:36:00 2022 +0400 WIP commit 2c7fb97d701ac158613c5a3a4d4d35c5b79b3d59 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Dec 28 14:15:59 2022 +0400 home: imp logs commit 4b06d089da835d6d187803bbb5ca1caf9973e2d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Dec 27 19:21:17 2022 +0400 all: fix update flag
2023-01-09 10:38:31 +00:00
vcu := updater.VersionCheckURL()
log.Error("getting version info from %s: %s", vcu, err)
Pull request: 5191-update-flag Merge in DNS/adguard-home from 5191-update-flag to master Updates #5191. Updates #4223. Squashed commit of the following: commit fbace4942844dc67f2467479385e06843c3abb6a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 9 12:05:16 2023 +0400 all: imp code, docs commit 8237dceb771ba95f545f79565d76cbb4ebd0d805 Merge: ca9518f2 bbdcc673 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Dec 30 14:45:55 2022 +0400 Merge branch 'master' into 5191-update-flag commit ca9518f20e5643572adf9734b93a5436ba30c865 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 20:36:33 2022 +0400 home: imp code commit 1dc6c7c3480df3df4a5f3f923f1feab7761a7945 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 18:26:08 2022 +0400 all: imp code, docs commit 7bbe893e98063b956482fd6f1c6be95a4f1956cf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:44:48 2022 +0400 home: restart service on update commit e0d3c287a7e1c05b1e397f4727c447a1fcd9f7f6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:22:49 2022 +0400 all: update on first run commit 0aa4e78f03bf3819425accb468ce59e747506ef3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 02:47:30 2022 +0400 all: move some code to init less commit 68aebfa050b9965afef26653e9b699ff4aaf5b8b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 00:36:00 2022 +0400 WIP commit 2c7fb97d701ac158613c5a3a4d4d35c5b79b3d59 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Dec 28 14:15:59 2022 +0400 home: imp logs commit 4b06d089da835d6d187803bbb5ca1caf9973e2d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Dec 27 19:21:17 2022 +0400 all: fix update flag
2023-01-09 10:38:31 +00:00
os.Exit(1)
}
Pull request: 5191-update-flag Merge in DNS/adguard-home from 5191-update-flag to master Updates #5191. Updates #4223. Squashed commit of the following: commit fbace4942844dc67f2467479385e06843c3abb6a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 9 12:05:16 2023 +0400 all: imp code, docs commit 8237dceb771ba95f545f79565d76cbb4ebd0d805 Merge: ca9518f2 bbdcc673 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Dec 30 14:45:55 2022 +0400 Merge branch 'master' into 5191-update-flag commit ca9518f20e5643572adf9734b93a5436ba30c865 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 20:36:33 2022 +0400 home: imp code commit 1dc6c7c3480df3df4a5f3f923f1feab7761a7945 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 18:26:08 2022 +0400 all: imp code, docs commit 7bbe893e98063b956482fd6f1c6be95a4f1956cf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:44:48 2022 +0400 home: restart service on update commit e0d3c287a7e1c05b1e397f4727c447a1fcd9f7f6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:22:49 2022 +0400 all: update on first run commit 0aa4e78f03bf3819425accb468ce59e747506ef3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 02:47:30 2022 +0400 all: move some code to init less commit 68aebfa050b9965afef26653e9b699ff4aaf5b8b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 00:36:00 2022 +0400 WIP commit 2c7fb97d701ac158613c5a3a4d4d35c5b79b3d59 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Dec 28 14:15:59 2022 +0400 home: imp logs commit 4b06d089da835d6d187803bbb5ca1caf9973e2d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Dec 27 19:21:17 2022 +0400 all: fix update flag
2023-01-09 10:38:31 +00:00
if info.NewVersion == version.Version() {
log.Info("no updates available")
os.Exit(0)
}
Pull request: 5191-update-flag Merge in DNS/adguard-home from 5191-update-flag to master Updates #5191. Updates #4223. Squashed commit of the following: commit fbace4942844dc67f2467479385e06843c3abb6a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 9 12:05:16 2023 +0400 all: imp code, docs commit 8237dceb771ba95f545f79565d76cbb4ebd0d805 Merge: ca9518f2 bbdcc673 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Dec 30 14:45:55 2022 +0400 Merge branch 'master' into 5191-update-flag commit ca9518f20e5643572adf9734b93a5436ba30c865 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 20:36:33 2022 +0400 home: imp code commit 1dc6c7c3480df3df4a5f3f923f1feab7761a7945 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 18:26:08 2022 +0400 all: imp code, docs commit 7bbe893e98063b956482fd6f1c6be95a4f1956cf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:44:48 2022 +0400 home: restart service on update commit e0d3c287a7e1c05b1e397f4727c447a1fcd9f7f6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:22:49 2022 +0400 all: update on first run commit 0aa4e78f03bf3819425accb468ce59e747506ef3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 02:47:30 2022 +0400 all: move some code to init less commit 68aebfa050b9965afef26653e9b699ff4aaf5b8b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 00:36:00 2022 +0400 WIP commit 2c7fb97d701ac158613c5a3a4d4d35c5b79b3d59 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Dec 28 14:15:59 2022 +0400 home: imp logs commit 4b06d089da835d6d187803bbb5ca1caf9973e2d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Dec 27 19:21:17 2022 +0400 all: fix update flag
2023-01-09 10:38:31 +00:00
err = updater.Update(Context.firstRun)
fatalOnError(err)
Pull request: 5191-update-flag Merge in DNS/adguard-home from 5191-update-flag to master Updates #5191. Updates #4223. Squashed commit of the following: commit fbace4942844dc67f2467479385e06843c3abb6a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 9 12:05:16 2023 +0400 all: imp code, docs commit 8237dceb771ba95f545f79565d76cbb4ebd0d805 Merge: ca9518f2 bbdcc673 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Dec 30 14:45:55 2022 +0400 Merge branch 'master' into 5191-update-flag commit ca9518f20e5643572adf9734b93a5436ba30c865 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 20:36:33 2022 +0400 home: imp code commit 1dc6c7c3480df3df4a5f3f923f1feab7761a7945 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 18:26:08 2022 +0400 all: imp code, docs commit 7bbe893e98063b956482fd6f1c6be95a4f1956cf Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:44:48 2022 +0400 home: restart service on update commit e0d3c287a7e1c05b1e397f4727c447a1fcd9f7f6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 03:22:49 2022 +0400 all: update on first run commit 0aa4e78f03bf3819425accb468ce59e747506ef3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 02:47:30 2022 +0400 all: move some code to init less commit 68aebfa050b9965afef26653e9b699ff4aaf5b8b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Dec 29 00:36:00 2022 +0400 WIP commit 2c7fb97d701ac158613c5a3a4d4d35c5b79b3d59 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Dec 28 14:15:59 2022 +0400 home: imp logs commit 4b06d089da835d6d187803bbb5ca1caf9973e2d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Dec 27 19:21:17 2022 +0400 all: fix update flag
2023-01-09 10:38:31 +00:00
err = restartService()
if err != nil {
log.Debug("restarting service: %s", err)
log.Info("AdGuard Home was not installed as a service. " +
"Please restart running instances of AdGuardHome manually.")
}
os.Exit(0)
}