AdGuardHome/internal/dnsforward/http.go

711 lines
21 KiB
Go
Raw Normal View History

package dnsforward
import (
"encoding/json"
"fmt"
"io"
"net/http"
"net/netip"
"slices"
Pull request: 2280 dns timeout Updates #2280. Squashed commit of the following: commit d8c6aacb664361a13dde8522de2470dd137bed00 Merge: 84df492b 12f1e4ed Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Jun 15 17:21:41 2021 +0300 Merge branch 'master' into 2280-dns-timeout commit 84df492b0134e88e031f586333437f503b90b7ae Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Jun 15 16:49:41 2021 +0300 home: fix docs & naming commit af44a86a60ea815ca7100edc34db8acbdcc2cccf Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Jun 15 15:55:12 2021 +0300 all: imp docs & tests commit 6ed6599fa0024cc7d14dc7c75ddda62e5179fe00 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Jun 15 15:26:22 2021 +0300 home: imp duration tests commit 8fe7cb099dccfce3f9329d7207ef48f488f07e83 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Jun 15 15:04:16 2021 +0300 all: imp code, docs & tests commit a989e8a5a6acede0063141cdbfc103b150b33d97 Author: Eugene Burkov <e.burkov@adguard.com> Date: Sat Jun 12 19:02:23 2021 +0300 WIP commit b0362e22040a1d38f81dcc775c5ef6f7d1e94eee Author: Eugene Burkov <e.burkov@adguard.com> Date: Sat Jun 12 18:58:09 2021 +0300 all: imp docs & tests commit 64b00fd0854f3ddcb0189f3c93f3ffa2a31a98be Author: Eugene Burkov <e.burkov@adguard.com> Date: Sat Jun 12 03:44:29 2021 +0300 home: introduce marshalable duration commit bfb1a5706c37fcd27bccce4a5aec37dca3cf238b Author: Eugene Burkov <e.burkov@adguard.com> Date: Sat Jun 12 01:56:10 2021 +0300 all: add upstream timeout setting
2021-06-15 15:36:49 +01:00
"time"
"github.com/AdguardTeam/AdGuardHome/internal/aghhttp"
Pull request 1979: AG-25263 filtering config Squashed commit of the following: commit a5607f811ab4642a0e34d3042240e3a9aafc3d84 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Aug 30 15:44:26 2023 +0300 home: upgrade yaml commit 0593e4da17613b8770c4567fdd5fbfde31631e6f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Aug 30 15:01:14 2023 +0300 home: upgrade yaml commit 59ec4ba0bbe59fb2e95290f4f8101891ce4ff959 Merge: 6555941f5 a325c9b6b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Aug 30 14:57:41 2023 +0300 Merge remote-tracking branch 'origin/master' into AG-25263-filtering-config # Conflicts: # internal/dnsforward/http.go # internal/dnsforward/http_test.go # internal/dnsforward/process.go # internal/dnsforward/process_internal_test.go commit 6555941f57e99aa8bc2473b8be9e4f096ce665e0 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Aug 30 14:38:01 2023 +0300 docs: changelog commit c66d14cecbb1f08869a90c46e58d08ec03e29de5 Merge: a50ff1622 aac36a2d2 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Aug 30 12:58:41 2023 +0300 Merge remote-tracking branch 'origin/master' into AG-25263-filtering-config commit a50ff162291f7953912c1bb195bd7b5d802d0ab3 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Aug 30 11:22:12 2023 +0300 home: imp code commit ef40d073e00d6acb164c0d680ed9971c4e75fbb7 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Aug 29 16:19:14 2023 +0300 home: imp code commit 5fa09a95e901a72dc5d2a90ba47c96842152587b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Aug 29 14:47:48 2023 +0300 home: imp code commit 52bb295120f468faf94c953d0e795d1d58696ef1 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Aug 29 13:33:01 2023 +0300 home: imp code commit 24cfccf071385d660aeba4ced744ebbacc819686 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Aug 29 12:24:20 2023 +0300 filtering: imp code commit 758242b69ee5f351b25407340f989ec6b90d3607 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Aug 29 10:32:51 2023 +0300 home: imp code commit 906deaa3bf86af5038fb05a54c34cc9511500ac9 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Aug 28 14:46:01 2023 +0300 dnsforward: imp code commit 978bb508349cd0b6a1a0bd3df5b879b6a4dd9e29 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Aug 28 14:40:31 2023 +0300 home: imp code commit d5b8dd5c930b0ccbe612f320a9908f2849370fd4 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Aug 28 12:34:32 2023 +0300 filtering: imp code commit d3e5726df6bc93112329ec81bc83932ccf64b8de Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Aug 28 11:57:33 2023 +0300 home: upgrade yaml commit 75d701553595786d5695540c001e6d46153351a9 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Aug 28 11:46:55 2023 +0300 home: upgrade yaml commit cd8cb623b0e6eb00fd05fb62b7445ca4315b94e0 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Aug 28 11:29:16 2023 +0300 docs: changelog commit 31c098d6f8d68a4afa30246c8d067a1ef4586de9 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Aug 28 11:08:48 2023 +0300 docs: changelog commit 24c88dd5d42b0168a13ea11b3f760eae1e804558 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Sun Aug 27 19:12:55 2023 +0300 home: imp code commit 94f2d386c9c1b6be5df06525078c90a3d068641f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Sun Aug 27 16:15:05 2023 +0300 home: upgrade yaml ... and 10 more commits
2023-08-30 16:26:02 +01:00
"github.com/AdguardTeam/AdGuardHome/internal/filtering"
Pull request 2107: AG-28327-upstream-config-parser Squashed commit of the following: commit e496653b10de52676826ed8e0c461e91405603a8 Merge: db2cd04e9 60a978c9a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Feb 1 18:23:50 2024 +0300 Merge branch 'master' into AG-28327-upstream-config-parser commit db2cd04e981dd24998d87f4935ff6590ea7854cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Jan 31 16:21:53 2024 +0300 all: upd proxy commit e8878179b6d094321d56fb2b75c16c1ba8cf637d Merge: ccbbae6d6 aa872dfe9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Jan 31 16:17:34 2024 +0300 Merge branch 'master' into AG-28327-upstream-config-parser commit ccbbae6d615e110d7d2d4c2a6b35954311153bcf Merge: d947d900e 8936c95ec Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 29 18:31:17 2024 +0300 Merge branch 'master' into AG-28327-upstream-config-parser commit d947d900e1f759159bc9068589ffe852483cfdd0 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 29 18:26:01 2024 +0300 dnsforward: imp docs commit cf9678c098951e2a4bebae7a3a5808d7de4c14c6 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Jan 25 14:18:04 2024 +0300 dnsforward: imp code commit 22792a9311cb93b2bb3b804293f87f091b9b81e2 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Jan 24 13:59:28 2024 +0300 dnsforward: imp code commit 57ddaaaaaf1009c65f0d9d6b2b1671211f194c85 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 22 20:19:44 2024 +0300 all: add tests commit d6732d13adae4ee46410252a33d092e67da3c34a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 22 18:44:57 2024 +0300 all: imp errors commit e14456571ce2ef43fb217f45445729ce6299daf6 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Jan 18 19:05:31 2024 +0300 dnsforward: imp code commit a5c106eae902fbc0a169ef9e4d7bf968f1e40bec Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 15 18:36:30 2024 +0300 dnsforward: imp logs commit 333b8561aa21d778007f808fb8e931ef3e95d721 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Dec 21 15:06:42 2023 +0300 all: imp tests commit 5b19d6b039755577e03ffcc03952724a36f21aa4 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Dec 15 14:21:58 2023 +0300 all: imp code commit 15fbd229de336425bde107a4f32175b8af41d876 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Dec 13 14:49:40 2023 +0300 all: upstream config parser
2024-02-05 13:12:27 +00:00
"github.com/AdguardTeam/dnsproxy/proxy"
"github.com/AdguardTeam/dnsproxy/upstream"
"github.com/AdguardTeam/golibs/errors"
"github.com/AdguardTeam/golibs/log"
"github.com/AdguardTeam/golibs/netutil"
"github.com/AdguardTeam/golibs/stringutil"
)
// jsonDNSConfig is the JSON representation of the DNS server configuration.
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
//
// TODO(s.chzhen): Split it into smaller pieces. Use aghalg.NullBool instead
// of *bool.
type jsonDNSConfig struct {
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
// Upstreams is the list of upstream DNS servers.
Upstreams *[]string `json:"upstream_dns"`
// UpstreamsFile is the file containing upstream DNS servers.
UpstreamsFile *string `json:"upstream_dns_file"`
// Bootstraps is the list of DNS servers resolving IP addresses of the
// upstream DoH/DoT resolvers.
Bootstraps *[]string `json:"bootstrap_dns"`
// Fallbacks is the list of fallback DNS servers used when upstream DNS
// servers are not responding.
Fallbacks *[]string `json:"fallback_dns"`
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
// ProtectionEnabled defines if protection is enabled.
ProtectionEnabled *bool `json:"protection_enabled"`
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
// Ratelimit is the number of requests per second allowed per client.
Ratelimit *uint32 `json:"ratelimit"`
// RatelimitSubnetLenIPv4 is a subnet length for IPv4 addresses used for
// rate limiting requests.
RatelimitSubnetLenIPv4 *int `json:"ratelimit_subnet_len_ipv4"`
// RatelimitSubnetLenIPv6 is a subnet length for IPv6 addresses used for
// rate limiting requests.
RatelimitSubnetLenIPv6 *int `json:"ratelimit_subnet_len_ipv6"`
// RatelimitWhitelist is a list of IP addresses excluded from rate limiting.
RatelimitWhitelist *[]netip.Addr `json:"ratelimit_whitelist"`
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
// BlockingMode defines the way blocked responses are constructed.
Pull request 1979: AG-25263 filtering config Squashed commit of the following: commit a5607f811ab4642a0e34d3042240e3a9aafc3d84 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Aug 30 15:44:26 2023 +0300 home: upgrade yaml commit 0593e4da17613b8770c4567fdd5fbfde31631e6f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Aug 30 15:01:14 2023 +0300 home: upgrade yaml commit 59ec4ba0bbe59fb2e95290f4f8101891ce4ff959 Merge: 6555941f5 a325c9b6b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Aug 30 14:57:41 2023 +0300 Merge remote-tracking branch 'origin/master' into AG-25263-filtering-config # Conflicts: # internal/dnsforward/http.go # internal/dnsforward/http_test.go # internal/dnsforward/process.go # internal/dnsforward/process_internal_test.go commit 6555941f57e99aa8bc2473b8be9e4f096ce665e0 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Aug 30 14:38:01 2023 +0300 docs: changelog commit c66d14cecbb1f08869a90c46e58d08ec03e29de5 Merge: a50ff1622 aac36a2d2 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Aug 30 12:58:41 2023 +0300 Merge remote-tracking branch 'origin/master' into AG-25263-filtering-config commit a50ff162291f7953912c1bb195bd7b5d802d0ab3 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Aug 30 11:22:12 2023 +0300 home: imp code commit ef40d073e00d6acb164c0d680ed9971c4e75fbb7 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Aug 29 16:19:14 2023 +0300 home: imp code commit 5fa09a95e901a72dc5d2a90ba47c96842152587b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Aug 29 14:47:48 2023 +0300 home: imp code commit 52bb295120f468faf94c953d0e795d1d58696ef1 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Aug 29 13:33:01 2023 +0300 home: imp code commit 24cfccf071385d660aeba4ced744ebbacc819686 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Aug 29 12:24:20 2023 +0300 filtering: imp code commit 758242b69ee5f351b25407340f989ec6b90d3607 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Aug 29 10:32:51 2023 +0300 home: imp code commit 906deaa3bf86af5038fb05a54c34cc9511500ac9 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Aug 28 14:46:01 2023 +0300 dnsforward: imp code commit 978bb508349cd0b6a1a0bd3df5b879b6a4dd9e29 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Aug 28 14:40:31 2023 +0300 home: imp code commit d5b8dd5c930b0ccbe612f320a9908f2849370fd4 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Aug 28 12:34:32 2023 +0300 filtering: imp code commit d3e5726df6bc93112329ec81bc83932ccf64b8de Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Aug 28 11:57:33 2023 +0300 home: upgrade yaml commit 75d701553595786d5695540c001e6d46153351a9 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Aug 28 11:46:55 2023 +0300 home: upgrade yaml commit cd8cb623b0e6eb00fd05fb62b7445ca4315b94e0 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Aug 28 11:29:16 2023 +0300 docs: changelog commit 31c098d6f8d68a4afa30246c8d067a1ef4586de9 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Aug 28 11:08:48 2023 +0300 docs: changelog commit 24c88dd5d42b0168a13ea11b3f760eae1e804558 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Sun Aug 27 19:12:55 2023 +0300 home: imp code commit 94f2d386c9c1b6be5df06525078c90a3d068641f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Sun Aug 27 16:15:05 2023 +0300 home: upgrade yaml ... and 10 more commits
2023-08-30 16:26:02 +01:00
BlockingMode *filtering.BlockingMode `json:"blocking_mode"`
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
// EDNSCSEnabled defines if EDNS Client Subnet is enabled.
EDNSCSEnabled *bool `json:"edns_cs_enabled"`
// EDNSCSUseCustom defines if EDNSCSCustomIP should be used.
EDNSCSUseCustom *bool `json:"edns_cs_use_custom"`
// DNSSECEnabled defines if DNSSEC is enabled.
DNSSECEnabled *bool `json:"dnssec_enabled"`
// DisableIPv6 defines if IPv6 addresses should be dropped.
DisableIPv6 *bool `json:"disable_ipv6"`
// UpstreamMode defines the way DNS requests are constructed.
Pull request: AG-28771 conf upstream mode Squashed commit of the following: commit afb5a0d8a499bccf7761baea40910f39c92b8a20 Merge: 09ac43c85 abf20c6de Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 25 12:55:45 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode commit 09ac43c859ef8cbd3bb0488d1a945589cd59ca19 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 14:36:07 2023 +0200 openapi: imp docs commit d0fbd4349e4bddde73c6e92f75854acfc481ac0d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:47:10 2023 +0200 all: changelog commit 105f9c50738733b0736a768fb9ee09d2e7fbf42e Merge: 62a2cf12d 4bc5c346a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:27:21 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode # Conflicts: # openapi/CHANGELOG.md commit 62a2cf12df694611888e840a5041a9c517cdfddb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 10:52:59 2023 +0200 openapi: imp docs commit 87956c49240da44b216489920feff69996e3502b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Dec 21 12:08:07 2023 +0200 dnsforward: imp code commit bf74d67ad112735d557be3d8fac75964cd99e375 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:46:38 2023 +0200 dnsforward: imp code commit 3a98dee88809a25118a14a1f07eeecbfccb14cd9 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:41:06 2023 +0200 dnsforward: imp code commit 1499da1fa0319ac3ad914171e807446f2c4d2fdb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:36:28 2023 +0200 dnsforward: imp code commit 228c61a5a0f73cc13655cef8bdaa1995b3f7fced Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:06:11 2023 +0200 dnsforward: imp code commit 069ee22c6d904db4e983135ce87a9fe8d12b7e9a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:39:25 2023 +0200 dnsforward: imp code commit 90919f99a975862dcb07ac82fb740e4404e48bae Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:10:43 2023 +0200 confmigrate: fix commit a8c329950423b59098d1f2b16d1da7100dd54f8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:08:05 2023 +0200 dnsforward: imp code commit 58b53ccd97d353fab0df29f13425b5e341c8fdeb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 18 15:10:01 2023 +0200 all: conf upstream mode
2023-12-25 11:16:48 +00:00
UpstreamMode *jsonUpstreamMode `json:"upstream_mode"`
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
// BlockedResponseTTL is the TTL for blocked responses.
BlockedResponseTTL *uint32 `json:"blocked_response_ttl"`
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
// CacheSize in bytes.
CacheSize *uint32 `json:"cache_size"`
// CacheMinTTL is custom minimum TTL for cached DNS responses.
CacheMinTTL *uint32 `json:"cache_ttl_min"`
// CacheMaxTTL is custom maximum TTL for cached DNS responses.
CacheMaxTTL *uint32 `json:"cache_ttl_max"`
// CacheOptimistic defines if expired entries should be served.
CacheOptimistic *bool `json:"cache_optimistic"`
// ResolveClients defines if clients IPs should be resolved into hostnames.
ResolveClients *bool `json:"resolve_clients"`
// UsePrivateRDNS defines if privates DNS resolvers should be used.
UsePrivateRDNS *bool `json:"use_private_ptr_resolvers"`
// LocalPTRUpstreams is the list of local private DNS resolvers.
LocalPTRUpstreams *[]string `json:"local_ptr_upstreams"`
// BlockingIPv4 is custom IPv4 address for blocked A requests.
Pull request 1966: 6050 upd urlfilter Merge in DNS/adguard-home from upd-urlfilter to master Updates #6050. Squashed commit of the following: commit 80337ab02d616e25fa455e46c9535c088b5c5ea5 Merge: fb2cfd1a5 31f7aaecc Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Aug 23 16:50:49 2023 +0300 Merge branch 'master' into upd-urlfilter commit fb2cfd1a5c94d92030fc8832615764f100d010e5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Aug 23 16:22:43 2023 +0300 dnsforward: imp code, docs commit 2900333bb85d4e064db9de27bd5bfe7c3ef00747 Merge: 977ed35e4 2bfc9fcb1 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Aug 22 18:06:05 2023 +0300 Merge branch 'master' into upd-urlfilter commit 977ed35e4ed377f1031721d58e0fcb58de1e74ac Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Aug 22 17:06:30 2023 +0300 all: log changes commit 1228a0770485799bf50bbe68005dbb0ba9a96a9c Merge: 78305eb2e 4b4036fa6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Aug 22 16:51:42 2023 +0300 Merge branch 'master' into upd-urlfilter commit 78305eb2ebc3854dd11ce35d6b4c7eecccd7cc78 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Aug 22 15:55:05 2023 +0300 all: upd urlfilter commit 63a29e18d5034e5f9433121ff7e7c45aebfa1f0f Merge: 748c53430 762e5be97 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Aug 21 20:12:49 2023 +0300 Merge branch 'master' into upd-urlfilter commit 748c5343020b0c6d4d4f16eb3d30b875c0a94e0f Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Aug 21 20:07:44 2023 +0300 all: imp code, docs commit 91975140f3305a6793e07142f7c9a75120a4ce8c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Aug 17 16:16:19 2023 +0300 all: upd urlfilter
2023-08-23 14:58:24 +01:00
BlockingIPv4 netip.Addr `json:"blocking_ipv4"`
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
// BlockingIPv6 is custom IPv6 address for blocked AAAA requests.
Pull request 1966: 6050 upd urlfilter Merge in DNS/adguard-home from upd-urlfilter to master Updates #6050. Squashed commit of the following: commit 80337ab02d616e25fa455e46c9535c088b5c5ea5 Merge: fb2cfd1a5 31f7aaecc Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Aug 23 16:50:49 2023 +0300 Merge branch 'master' into upd-urlfilter commit fb2cfd1a5c94d92030fc8832615764f100d010e5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Aug 23 16:22:43 2023 +0300 dnsforward: imp code, docs commit 2900333bb85d4e064db9de27bd5bfe7c3ef00747 Merge: 977ed35e4 2bfc9fcb1 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Aug 22 18:06:05 2023 +0300 Merge branch 'master' into upd-urlfilter commit 977ed35e4ed377f1031721d58e0fcb58de1e74ac Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Aug 22 17:06:30 2023 +0300 all: log changes commit 1228a0770485799bf50bbe68005dbb0ba9a96a9c Merge: 78305eb2e 4b4036fa6 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Aug 22 16:51:42 2023 +0300 Merge branch 'master' into upd-urlfilter commit 78305eb2ebc3854dd11ce35d6b4c7eecccd7cc78 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Aug 22 15:55:05 2023 +0300 all: upd urlfilter commit 63a29e18d5034e5f9433121ff7e7c45aebfa1f0f Merge: 748c53430 762e5be97 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Aug 21 20:12:49 2023 +0300 Merge branch 'master' into upd-urlfilter commit 748c5343020b0c6d4d4f16eb3d30b875c0a94e0f Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Aug 21 20:07:44 2023 +0300 all: imp code, docs commit 91975140f3305a6793e07142f7c9a75120a4ce8c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Aug 17 16:16:19 2023 +0300 all: upd urlfilter
2023-08-23 14:58:24 +01:00
BlockingIPv6 netip.Addr `json:"blocking_ipv6"`
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
Pull request: 1333-protection-pause vol.1 Merge in DNS/adguard-home from 1333-protection-pause-1 to master Squashed commit of the following: commit 5ff98385bc5ff66e214d80782eb4dc41e344aa38 Merge: 97f94a54 0bc3ef89 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 24 19:08:21 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 commit 97f94a5498ac221f88f2f7dfef4b255f4945329e Author: Arseny Lisin <a.lisin@adguard.com> Date: Fri Mar 24 13:03:20 2023 +0200 Fix protection timer bugs commit 1cc61af1996bd803f3fa638cb9e2388470072bf0 Merge: 5a144ea3 235ce458 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 22:27:47 2023 +0700 Merge remote-tracking branch 'origin/1333-protection-pause-1' into 1333-protection-pause-1 commit 5a144ea3a48c3d0d5e57dd14232ab7a8e77a8c1e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 22:25:08 2023 +0700 dnsforward: imp code commit 235ce458a62b3152f36e32580ed0226a56580ec6 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Mar 23 17:35:06 2023 +0300 dnsforward: imp locks commit 0ea3a0a176b810a2b3f0b307aa406fe1670c9219 Merge: 52f66810 df61741f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 19:30:41 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # openapi/CHANGELOG.md commit 52f668109673286a50909c042e6352cd803e8eed Merge: 9a7eb7b3 306c1983 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 11:23:50 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # internal/dnsforward/http.go commit 9a7eb7b3ab2b5f6ad321aa3245d33839c3aa6fbd Author: Arseny Lisin <a.lisin@adguard.com> Date: Wed Mar 22 06:56:55 2023 +0200 Review fix commit 5612d51252ba91842bd6811baec1c91136bb3bf2 Merge: c0a918a5 c3edab43 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 21 22:00:39 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # client/src/__locales/en.json commit c0a918a518ad9b37041aed159d215516258bc987 Author: Arseny Lisin <a.lisin@adguard.com> Date: Tue Mar 21 12:13:18 2023 +0200 Review fix commit 34faa61cc1e6210a612e7a2f4895a1504df37680 Author: Arseny Lisin <a.lisin@adguard.com> Date: Tue Mar 21 10:43:37 2023 +0200 Fix props to new api commit 158e582373863495f0e0ca177d7b365cc66ad671 Author: Arseny Lisin <a.lisin@adguard.com> Date: Mon Mar 20 18:44:34 2023 +0200 Review fix commit 9e8b8c3778b8e1dfad0d39e44f70886dfd3aeb9a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 20 22:31:28 2023 +0700 all: docs commit 761a203f53b535ca235cfe62f289bd0e02b90be2 Merge: d0b07231 48431f8b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 20 22:26:13 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 commit d0b07231b6f29b534930f1fcfc82b4934c295ff8 Merge: ea448760 a2053526 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 13:00:52 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # client/src/components/App/index.css # internal/dnsforward/config.go commit ea4487608a9c81d25f155ff63fee7c9dcf21f448 Merge: dfd0f33f a556ce8f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 21 11:54:27 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md commit dfd0f33fb474d497cbc9237ee466276728eea397 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 21 11:51:40 2023 +0700 all: docs commit d36df96fba8c6d923faef85c198b6bd0743b7ee8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Feb 20 12:41:49 2023 +0700 all: safesearch commit 60f2ceec563221337f34bb60baa96aa2b2429c40 Merge: 7c514427 6f6ced33 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Feb 20 12:30:42 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md commit 7c514427e77c5b09d8e148c78220a71046e68cd1 Merge: 0fa4ff99 4d295a38 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Feb 16 11:55:21 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md ... and 26 more commits
2023-03-24 12:11:47 +00:00
// DisabledUntil is a timestamp until when the protection is disabled.
DisabledUntil *time.Time `json:"protection_disabled_until"`
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
// EDNSCSCustomIP is custom IP for EDNS Client Subnet.
EDNSCSCustomIP netip.Addr `json:"edns_cs_custom_ip"`
// DefaultLocalPTRUpstreams is used to pass the addresses from
// systemResolvers to the front-end. It's not a pointer to the slice since
// there is no need to omit it while decoding from JSON.
DefaultLocalPTRUpstreams []string `json:"default_local_ptr_upstreams,omitempty"`
}
Pull request: AG-28771 conf upstream mode Squashed commit of the following: commit afb5a0d8a499bccf7761baea40910f39c92b8a20 Merge: 09ac43c85 abf20c6de Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 25 12:55:45 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode commit 09ac43c859ef8cbd3bb0488d1a945589cd59ca19 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 14:36:07 2023 +0200 openapi: imp docs commit d0fbd4349e4bddde73c6e92f75854acfc481ac0d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:47:10 2023 +0200 all: changelog commit 105f9c50738733b0736a768fb9ee09d2e7fbf42e Merge: 62a2cf12d 4bc5c346a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:27:21 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode # Conflicts: # openapi/CHANGELOG.md commit 62a2cf12df694611888e840a5041a9c517cdfddb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 10:52:59 2023 +0200 openapi: imp docs commit 87956c49240da44b216489920feff69996e3502b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Dec 21 12:08:07 2023 +0200 dnsforward: imp code commit bf74d67ad112735d557be3d8fac75964cd99e375 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:46:38 2023 +0200 dnsforward: imp code commit 3a98dee88809a25118a14a1f07eeecbfccb14cd9 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:41:06 2023 +0200 dnsforward: imp code commit 1499da1fa0319ac3ad914171e807446f2c4d2fdb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:36:28 2023 +0200 dnsforward: imp code commit 228c61a5a0f73cc13655cef8bdaa1995b3f7fced Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:06:11 2023 +0200 dnsforward: imp code commit 069ee22c6d904db4e983135ce87a9fe8d12b7e9a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:39:25 2023 +0200 dnsforward: imp code commit 90919f99a975862dcb07ac82fb740e4404e48bae Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:10:43 2023 +0200 confmigrate: fix commit a8c329950423b59098d1f2b16d1da7100dd54f8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:08:05 2023 +0200 dnsforward: imp code commit 58b53ccd97d353fab0df29f13425b5e341c8fdeb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 18 15:10:01 2023 +0200 all: conf upstream mode
2023-12-25 11:16:48 +00:00
// jsonUpstreamMode is a enumeration of upstream modes.
type jsonUpstreamMode string
const (
// jsonUpstreamModeEmpty is the default value on frontend, it is used as
// jsonUpstreamModeLoadBalance mode.
//
// Deprecated: Use jsonUpstreamModeLoadBalance instead.
jsonUpstreamModeEmpty jsonUpstreamMode = ""
jsonUpstreamModeLoadBalance jsonUpstreamMode = "load_balance"
jsonUpstreamModeParallel jsonUpstreamMode = "parallel"
jsonUpstreamModeFastestAddr jsonUpstreamMode = "fastest_addr"
)
func (s *Server) getDNSConfig() (c *jsonDNSConfig) {
protectionEnabled, protectionDisabledUntil := s.UpdatedProtectionStatus()
Pull request: 1333-protection-pause vol.1 Merge in DNS/adguard-home from 1333-protection-pause-1 to master Squashed commit of the following: commit 5ff98385bc5ff66e214d80782eb4dc41e344aa38 Merge: 97f94a54 0bc3ef89 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 24 19:08:21 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 commit 97f94a5498ac221f88f2f7dfef4b255f4945329e Author: Arseny Lisin <a.lisin@adguard.com> Date: Fri Mar 24 13:03:20 2023 +0200 Fix protection timer bugs commit 1cc61af1996bd803f3fa638cb9e2388470072bf0 Merge: 5a144ea3 235ce458 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 22:27:47 2023 +0700 Merge remote-tracking branch 'origin/1333-protection-pause-1' into 1333-protection-pause-1 commit 5a144ea3a48c3d0d5e57dd14232ab7a8e77a8c1e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 22:25:08 2023 +0700 dnsforward: imp code commit 235ce458a62b3152f36e32580ed0226a56580ec6 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Mar 23 17:35:06 2023 +0300 dnsforward: imp locks commit 0ea3a0a176b810a2b3f0b307aa406fe1670c9219 Merge: 52f66810 df61741f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 19:30:41 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # openapi/CHANGELOG.md commit 52f668109673286a50909c042e6352cd803e8eed Merge: 9a7eb7b3 306c1983 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 11:23:50 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # internal/dnsforward/http.go commit 9a7eb7b3ab2b5f6ad321aa3245d33839c3aa6fbd Author: Arseny Lisin <a.lisin@adguard.com> Date: Wed Mar 22 06:56:55 2023 +0200 Review fix commit 5612d51252ba91842bd6811baec1c91136bb3bf2 Merge: c0a918a5 c3edab43 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 21 22:00:39 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # client/src/__locales/en.json commit c0a918a518ad9b37041aed159d215516258bc987 Author: Arseny Lisin <a.lisin@adguard.com> Date: Tue Mar 21 12:13:18 2023 +0200 Review fix commit 34faa61cc1e6210a612e7a2f4895a1504df37680 Author: Arseny Lisin <a.lisin@adguard.com> Date: Tue Mar 21 10:43:37 2023 +0200 Fix props to new api commit 158e582373863495f0e0ca177d7b365cc66ad671 Author: Arseny Lisin <a.lisin@adguard.com> Date: Mon Mar 20 18:44:34 2023 +0200 Review fix commit 9e8b8c3778b8e1dfad0d39e44f70886dfd3aeb9a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 20 22:31:28 2023 +0700 all: docs commit 761a203f53b535ca235cfe62f289bd0e02b90be2 Merge: d0b07231 48431f8b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 20 22:26:13 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 commit d0b07231b6f29b534930f1fcfc82b4934c295ff8 Merge: ea448760 a2053526 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 13:00:52 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # client/src/components/App/index.css # internal/dnsforward/config.go commit ea4487608a9c81d25f155ff63fee7c9dcf21f448 Merge: dfd0f33f a556ce8f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 21 11:54:27 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md commit dfd0f33fb474d497cbc9237ee466276728eea397 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 21 11:51:40 2023 +0700 all: docs commit d36df96fba8c6d923faef85c198b6bd0743b7ee8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Feb 20 12:41:49 2023 +0700 all: safesearch commit 60f2ceec563221337f34bb60baa96aa2b2429c40 Merge: 7c514427 6f6ced33 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Feb 20 12:30:42 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md commit 7c514427e77c5b09d8e148c78220a71046e68cd1 Merge: 0fa4ff99 4d295a38 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Feb 16 11:55:21 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md ... and 26 more commits
2023-03-24 12:11:47 +00:00
s.serverLock.RLock()
defer s.serverLock.RUnlock()
Pull request: 2704 local addresses vol.3 Merge in DNS/adguard-home from 2704-local-addresses-vol.3 to master Updates #2704. Updates #2829. Updates #2928. Squashed commit of the following: commit 8c42355c0093a3ac6951f79a5211e7891800f93a Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:07:41 2021 +0300 dnsforward: rm errors pkg commit 7594a21a620239951039454dd5686a872e6f41a8 Merge: 830b0834 908452f8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:00:03 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 830b0834090510096061fed20b600195ab3773b8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 17:47:51 2021 +0300 dnsforward: reduce local upstream timeout commit 493e81d9e8bacdc690f88af29a38d211b9733c7e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 19:11:00 2021 +0300 client: private_upstream test commit a0194ac28f15114578359b8c2460cd9af621e912 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:36:23 2021 +0300 all: expand api, fix conflicts commit 0f4e06836fed958391aa597c8b02453564980ca3 Merge: 89cf93ad 8746005d Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:35:04 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 89cf93ad4f26c2bf4f1b18ecaa4d3a1e169f9b06 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 18:02:40 2021 +0300 client: add local ptr upstreams to upstream test commit e6dd869dddd4888474d625cbb005bad6390e4760 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 15:24:22 2021 +0300 client: add private DNS form commit b858057b9a957a416117f22b8bd0025f90e8c758 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 13:05:28 2021 +0300 aghstrings: mk cloning correct commit 8009ba60a6a7d6ceb7b6483a29f4e68d533af243 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 12:37:46 2021 +0300 aghstrings: fix lil bug commit 0dd19f2e7cc7c0de21517c37abd8336a907e1c0d Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:45:01 2021 +0300 all: log changes commit eb5558d96fffa6e7bca7e14d3740d26e47382e23 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:18:53 2021 +0300 dnsforward: keep the style commit d6d5fcbde40a633129c0e04887b81cf0b1ce6875 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:02:52 2021 +0300 dnsforward: disable redundant filtering for local ptr commit 4f864c32027d10db9bcb4a264d2338df8c20afac Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 17:53:17 2021 +0300 dnsforward: imp tests commit 7848e6f2341868f8ba0bb839956a0b7444cf02ca Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 14:52:12 2021 +0300 all: imp code commit 19ac30653800eebf8aaee499f65560ae2d458a5a Author: Eugene Burkov <e.burkov@adguard.com> Date: Sun Apr 4 16:28:05 2021 +0300 all: mv more logic to aghstrings commit fac892ec5f0d2e30d6d64def0609267bbae4a202 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:23:23 2021 +0300 dnsforward: use filepath commit 05a3aeef1181b914788d14c7519287d467ab301f Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:17:54 2021 +0300 aghstrings: introduce the pkg commit f24e1b63d6e1bf266a4ed063f46f86d7abf65663 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:01:23 2021 +0300 all: imp code commit 0217a0ebb341f99a90c9b68013bebf6ff73d08ae Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 18:04:13 2021 +0300 openapi: log changes ... and 3 more commits
2021-04-07 18:16:06 +01:00
upstreams := stringutil.CloneSliceOrEmpty(s.conf.UpstreamDNS)
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
upstreamFile := s.conf.UpstreamDNSFileName
bootstraps := stringutil.CloneSliceOrEmpty(s.conf.BootstrapDNS)
fallbacks := stringutil.CloneSliceOrEmpty(s.conf.FallbackDNS)
blockingMode, blockingIPv4, blockingIPv6 := s.dnsFilter.BlockingMode()
blockedResponseTTL := s.dnsFilter.BlockedResponseTTL()
Pull request: 2704 local addresses vol.3 Merge in DNS/adguard-home from 2704-local-addresses-vol.3 to master Updates #2704. Updates #2829. Updates #2928. Squashed commit of the following: commit 8c42355c0093a3ac6951f79a5211e7891800f93a Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:07:41 2021 +0300 dnsforward: rm errors pkg commit 7594a21a620239951039454dd5686a872e6f41a8 Merge: 830b0834 908452f8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:00:03 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 830b0834090510096061fed20b600195ab3773b8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 17:47:51 2021 +0300 dnsforward: reduce local upstream timeout commit 493e81d9e8bacdc690f88af29a38d211b9733c7e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 19:11:00 2021 +0300 client: private_upstream test commit a0194ac28f15114578359b8c2460cd9af621e912 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:36:23 2021 +0300 all: expand api, fix conflicts commit 0f4e06836fed958391aa597c8b02453564980ca3 Merge: 89cf93ad 8746005d Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:35:04 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 89cf93ad4f26c2bf4f1b18ecaa4d3a1e169f9b06 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 18:02:40 2021 +0300 client: add local ptr upstreams to upstream test commit e6dd869dddd4888474d625cbb005bad6390e4760 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 15:24:22 2021 +0300 client: add private DNS form commit b858057b9a957a416117f22b8bd0025f90e8c758 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 13:05:28 2021 +0300 aghstrings: mk cloning correct commit 8009ba60a6a7d6ceb7b6483a29f4e68d533af243 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 12:37:46 2021 +0300 aghstrings: fix lil bug commit 0dd19f2e7cc7c0de21517c37abd8336a907e1c0d Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:45:01 2021 +0300 all: log changes commit eb5558d96fffa6e7bca7e14d3740d26e47382e23 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:18:53 2021 +0300 dnsforward: keep the style commit d6d5fcbde40a633129c0e04887b81cf0b1ce6875 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:02:52 2021 +0300 dnsforward: disable redundant filtering for local ptr commit 4f864c32027d10db9bcb4a264d2338df8c20afac Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 17:53:17 2021 +0300 dnsforward: imp tests commit 7848e6f2341868f8ba0bb839956a0b7444cf02ca Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 14:52:12 2021 +0300 all: imp code commit 19ac30653800eebf8aaee499f65560ae2d458a5a Author: Eugene Burkov <e.burkov@adguard.com> Date: Sun Apr 4 16:28:05 2021 +0300 all: mv more logic to aghstrings commit fac892ec5f0d2e30d6d64def0609267bbae4a202 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:23:23 2021 +0300 dnsforward: use filepath commit 05a3aeef1181b914788d14c7519287d467ab301f Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:17:54 2021 +0300 aghstrings: introduce the pkg commit f24e1b63d6e1bf266a4ed063f46f86d7abf65663 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:01:23 2021 +0300 all: imp code commit 0217a0ebb341f99a90c9b68013bebf6ff73d08ae Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 18:04:13 2021 +0300 openapi: log changes ... and 3 more commits
2021-04-07 18:16:06 +01:00
ratelimit := s.conf.Ratelimit
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
ratelimitSubnetLenIPv4 := s.conf.RatelimitSubnetLenIPv4
ratelimitSubnetLenIPv6 := s.conf.RatelimitSubnetLenIPv6
ratelimitWhitelist := append([]netip.Addr{}, s.conf.RatelimitWhitelist...)
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
customIP := s.conf.EDNSClientSubnet.CustomIP
Pull request 1744: 1472-edns-custom-ip Merge in DNS/adguard-home from 1472-edns-custom-ip to master Updates #1472. Squashed commit of the following: commit 07460c3adf7747fd9ec1b4a3d04fb459dec44280 Merge: 65455430 ae653f16 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 1 15:38:46 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip commit 65455430993e4a62c49e1f45def909b0a135af3b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 1 15:37:17 2023 +0300 dnsforward: add todo commit e1978ad4b6051f29185ef32973d20bc70f2a6634 Merge: 6cd98f42 bb226434 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 1 11:32:23 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip commit 6cd98f4235b1b52d443c1950f2516af3cc4fb258 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 1 11:31:16 2023 +0300 all: fix chlog; fix field alignment commit defdec623919c23ab446324828d08839469669e1 Merge: 1130ebd5 a772212d Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Feb 28 12:17:23 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip commit 1130ebd509bf4f7ec25fbb53717576e273dbfff2 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Feb 28 12:13:30 2023 +0300 all: add use_custom field commit ec0cdc7af0f96f761ed85516bbcae2567fd6f7d2 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Feb 27 13:59:13 2023 +0300 all: fix chlog; imp code commit f8450cfcd6054f32d6ea0a5e26c551fe153a0b21 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Feb 27 11:28:16 2023 +0300 dnsforward: fix fmt commit 54a344e5bb17aae7ca213ed66b85f06ef6585316 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Feb 27 11:11:52 2023 +0300 all: fix chlog; add test case commit 47b5476f6621c6ea31aa496d4113445a8e8bceb4 Merge: 8724f374 304f2ba2 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Feb 22 16:33:07 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip commit 8724f3745ccc29849a4001f79b055c7ebeb19106 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Feb 22 16:31:40 2023 +0300 all: fix comments commit d2b1528ba333e7669795a3fb80355ff7d90cf4f5 Merge: 7898c23a 76a513cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Feb 22 11:53:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip commit 7898c23ab991bc516bcc2f41e47bed15582fd962 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Feb 22 11:52:37 2023 +0300 all: upd chlog commit 8763261dcb4187a93104955e7cb440965e2b6739 Merge: d28394b3 ff9b24ad Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Feb 21 17:12:03 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip commit d28394b3c980b10f28c6c38ce35f368edb11d314 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Feb 21 17:11:29 2023 +0300 home: fix default value commit 1a5da3f267706baa83eebe1923ea1b0b4e79fd6c Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Feb 21 13:37:04 2023 +0300 all: add custom ip for edns
2023-03-01 13:16:16 +00:00
enableEDNSClientSubnet := s.conf.EDNSClientSubnet.Enabled
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
useCustom := s.conf.EDNSClientSubnet.UseCustom
Pull request: 2704 local addresses vol.3 Merge in DNS/adguard-home from 2704-local-addresses-vol.3 to master Updates #2704. Updates #2829. Updates #2928. Squashed commit of the following: commit 8c42355c0093a3ac6951f79a5211e7891800f93a Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:07:41 2021 +0300 dnsforward: rm errors pkg commit 7594a21a620239951039454dd5686a872e6f41a8 Merge: 830b0834 908452f8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:00:03 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 830b0834090510096061fed20b600195ab3773b8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 17:47:51 2021 +0300 dnsforward: reduce local upstream timeout commit 493e81d9e8bacdc690f88af29a38d211b9733c7e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 19:11:00 2021 +0300 client: private_upstream test commit a0194ac28f15114578359b8c2460cd9af621e912 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:36:23 2021 +0300 all: expand api, fix conflicts commit 0f4e06836fed958391aa597c8b02453564980ca3 Merge: 89cf93ad 8746005d Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:35:04 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 89cf93ad4f26c2bf4f1b18ecaa4d3a1e169f9b06 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 18:02:40 2021 +0300 client: add local ptr upstreams to upstream test commit e6dd869dddd4888474d625cbb005bad6390e4760 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 15:24:22 2021 +0300 client: add private DNS form commit b858057b9a957a416117f22b8bd0025f90e8c758 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 13:05:28 2021 +0300 aghstrings: mk cloning correct commit 8009ba60a6a7d6ceb7b6483a29f4e68d533af243 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 12:37:46 2021 +0300 aghstrings: fix lil bug commit 0dd19f2e7cc7c0de21517c37abd8336a907e1c0d Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:45:01 2021 +0300 all: log changes commit eb5558d96fffa6e7bca7e14d3740d26e47382e23 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:18:53 2021 +0300 dnsforward: keep the style commit d6d5fcbde40a633129c0e04887b81cf0b1ce6875 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:02:52 2021 +0300 dnsforward: disable redundant filtering for local ptr commit 4f864c32027d10db9bcb4a264d2338df8c20afac Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 17:53:17 2021 +0300 dnsforward: imp tests commit 7848e6f2341868f8ba0bb839956a0b7444cf02ca Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 14:52:12 2021 +0300 all: imp code commit 19ac30653800eebf8aaee499f65560ae2d458a5a Author: Eugene Burkov <e.burkov@adguard.com> Date: Sun Apr 4 16:28:05 2021 +0300 all: mv more logic to aghstrings commit fac892ec5f0d2e30d6d64def0609267bbae4a202 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:23:23 2021 +0300 dnsforward: use filepath commit 05a3aeef1181b914788d14c7519287d467ab301f Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:17:54 2021 +0300 aghstrings: introduce the pkg commit f24e1b63d6e1bf266a4ed063f46f86d7abf65663 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:01:23 2021 +0300 all: imp code commit 0217a0ebb341f99a90c9b68013bebf6ff73d08ae Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 18:04:13 2021 +0300 openapi: log changes ... and 3 more commits
2021-04-07 18:16:06 +01:00
enableDNSSEC := s.conf.EnableDNSSEC
aaaaDisabled := s.conf.AAAADisabled
cacheSize := s.conf.CacheSize
cacheMinTTL := s.conf.CacheMinTTL
cacheMaxTTL := s.conf.CacheMaxTTL
cacheOptimistic := s.conf.CacheOptimistic
resolveClients := s.conf.AddrProcConf.UseRDNS
usePrivateRDNS := s.conf.UsePrivateRDNS
localPTRUpstreams := stringutil.CloneSliceOrEmpty(s.conf.LocalPTRResolvers)
Pull request: 1333-protection-pause vol.1 Merge in DNS/adguard-home from 1333-protection-pause-1 to master Squashed commit of the following: commit 5ff98385bc5ff66e214d80782eb4dc41e344aa38 Merge: 97f94a54 0bc3ef89 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 24 19:08:21 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 commit 97f94a5498ac221f88f2f7dfef4b255f4945329e Author: Arseny Lisin <a.lisin@adguard.com> Date: Fri Mar 24 13:03:20 2023 +0200 Fix protection timer bugs commit 1cc61af1996bd803f3fa638cb9e2388470072bf0 Merge: 5a144ea3 235ce458 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 22:27:47 2023 +0700 Merge remote-tracking branch 'origin/1333-protection-pause-1' into 1333-protection-pause-1 commit 5a144ea3a48c3d0d5e57dd14232ab7a8e77a8c1e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 22:25:08 2023 +0700 dnsforward: imp code commit 235ce458a62b3152f36e32580ed0226a56580ec6 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Mar 23 17:35:06 2023 +0300 dnsforward: imp locks commit 0ea3a0a176b810a2b3f0b307aa406fe1670c9219 Merge: 52f66810 df61741f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 19:30:41 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # openapi/CHANGELOG.md commit 52f668109673286a50909c042e6352cd803e8eed Merge: 9a7eb7b3 306c1983 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 11:23:50 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # internal/dnsforward/http.go commit 9a7eb7b3ab2b5f6ad321aa3245d33839c3aa6fbd Author: Arseny Lisin <a.lisin@adguard.com> Date: Wed Mar 22 06:56:55 2023 +0200 Review fix commit 5612d51252ba91842bd6811baec1c91136bb3bf2 Merge: c0a918a5 c3edab43 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 21 22:00:39 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # client/src/__locales/en.json commit c0a918a518ad9b37041aed159d215516258bc987 Author: Arseny Lisin <a.lisin@adguard.com> Date: Tue Mar 21 12:13:18 2023 +0200 Review fix commit 34faa61cc1e6210a612e7a2f4895a1504df37680 Author: Arseny Lisin <a.lisin@adguard.com> Date: Tue Mar 21 10:43:37 2023 +0200 Fix props to new api commit 158e582373863495f0e0ca177d7b365cc66ad671 Author: Arseny Lisin <a.lisin@adguard.com> Date: Mon Mar 20 18:44:34 2023 +0200 Review fix commit 9e8b8c3778b8e1dfad0d39e44f70886dfd3aeb9a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 20 22:31:28 2023 +0700 all: docs commit 761a203f53b535ca235cfe62f289bd0e02b90be2 Merge: d0b07231 48431f8b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 20 22:26:13 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 commit d0b07231b6f29b534930f1fcfc82b4934c295ff8 Merge: ea448760 a2053526 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 13:00:52 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # client/src/components/App/index.css # internal/dnsforward/config.go commit ea4487608a9c81d25f155ff63fee7c9dcf21f448 Merge: dfd0f33f a556ce8f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 21 11:54:27 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md commit dfd0f33fb474d497cbc9237ee466276728eea397 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 21 11:51:40 2023 +0700 all: docs commit d36df96fba8c6d923faef85c198b6bd0743b7ee8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Feb 20 12:41:49 2023 +0700 all: safesearch commit 60f2ceec563221337f34bb60baa96aa2b2429c40 Merge: 7c514427 6f6ced33 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Feb 20 12:30:42 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md commit 7c514427e77c5b09d8e148c78220a71046e68cd1 Merge: 0fa4ff99 4d295a38 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Feb 16 11:55:21 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md ... and 26 more commits
2023-03-24 12:11:47 +00:00
Pull request: AG-28771 conf upstream mode Squashed commit of the following: commit afb5a0d8a499bccf7761baea40910f39c92b8a20 Merge: 09ac43c85 abf20c6de Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 25 12:55:45 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode commit 09ac43c859ef8cbd3bb0488d1a945589cd59ca19 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 14:36:07 2023 +0200 openapi: imp docs commit d0fbd4349e4bddde73c6e92f75854acfc481ac0d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:47:10 2023 +0200 all: changelog commit 105f9c50738733b0736a768fb9ee09d2e7fbf42e Merge: 62a2cf12d 4bc5c346a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:27:21 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode # Conflicts: # openapi/CHANGELOG.md commit 62a2cf12df694611888e840a5041a9c517cdfddb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 10:52:59 2023 +0200 openapi: imp docs commit 87956c49240da44b216489920feff69996e3502b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Dec 21 12:08:07 2023 +0200 dnsforward: imp code commit bf74d67ad112735d557be3d8fac75964cd99e375 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:46:38 2023 +0200 dnsforward: imp code commit 3a98dee88809a25118a14a1f07eeecbfccb14cd9 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:41:06 2023 +0200 dnsforward: imp code commit 1499da1fa0319ac3ad914171e807446f2c4d2fdb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:36:28 2023 +0200 dnsforward: imp code commit 228c61a5a0f73cc13655cef8bdaa1995b3f7fced Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:06:11 2023 +0200 dnsforward: imp code commit 069ee22c6d904db4e983135ce87a9fe8d12b7e9a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:39:25 2023 +0200 dnsforward: imp code commit 90919f99a975862dcb07ac82fb740e4404e48bae Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:10:43 2023 +0200 confmigrate: fix commit a8c329950423b59098d1f2b16d1da7100dd54f8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:08:05 2023 +0200 dnsforward: imp code commit 58b53ccd97d353fab0df29f13425b5e341c8fdeb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 18 15:10:01 2023 +0200 all: conf upstream mode
2023-12-25 11:16:48 +00:00
var upstreamMode jsonUpstreamMode
switch s.conf.UpstreamMode {
case UpstreamModeLoadBalance:
// TODO(d.kolyshev): Support jsonUpstreamModeLoadBalance on frontend instead
// of jsonUpstreamModeEmpty.
upstreamMode = jsonUpstreamModeEmpty
case UpstreamModeParallel:
upstreamMode = jsonUpstreamModeParallel
case UpstreamModeFastestAddr:
upstreamMode = jsonUpstreamModeFastestAddr
}
Pull request: 2704 local addresses vol.3 Merge in DNS/adguard-home from 2704-local-addresses-vol.3 to master Updates #2704. Updates #2829. Updates #2928. Squashed commit of the following: commit 8c42355c0093a3ac6951f79a5211e7891800f93a Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:07:41 2021 +0300 dnsforward: rm errors pkg commit 7594a21a620239951039454dd5686a872e6f41a8 Merge: 830b0834 908452f8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:00:03 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 830b0834090510096061fed20b600195ab3773b8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 17:47:51 2021 +0300 dnsforward: reduce local upstream timeout commit 493e81d9e8bacdc690f88af29a38d211b9733c7e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 19:11:00 2021 +0300 client: private_upstream test commit a0194ac28f15114578359b8c2460cd9af621e912 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:36:23 2021 +0300 all: expand api, fix conflicts commit 0f4e06836fed958391aa597c8b02453564980ca3 Merge: 89cf93ad 8746005d Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:35:04 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 89cf93ad4f26c2bf4f1b18ecaa4d3a1e169f9b06 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 18:02:40 2021 +0300 client: add local ptr upstreams to upstream test commit e6dd869dddd4888474d625cbb005bad6390e4760 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 15:24:22 2021 +0300 client: add private DNS form commit b858057b9a957a416117f22b8bd0025f90e8c758 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 13:05:28 2021 +0300 aghstrings: mk cloning correct commit 8009ba60a6a7d6ceb7b6483a29f4e68d533af243 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 12:37:46 2021 +0300 aghstrings: fix lil bug commit 0dd19f2e7cc7c0de21517c37abd8336a907e1c0d Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:45:01 2021 +0300 all: log changes commit eb5558d96fffa6e7bca7e14d3740d26e47382e23 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:18:53 2021 +0300 dnsforward: keep the style commit d6d5fcbde40a633129c0e04887b81cf0b1ce6875 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:02:52 2021 +0300 dnsforward: disable redundant filtering for local ptr commit 4f864c32027d10db9bcb4a264d2338df8c20afac Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 17:53:17 2021 +0300 dnsforward: imp tests commit 7848e6f2341868f8ba0bb839956a0b7444cf02ca Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 14:52:12 2021 +0300 all: imp code commit 19ac30653800eebf8aaee499f65560ae2d458a5a Author: Eugene Burkov <e.burkov@adguard.com> Date: Sun Apr 4 16:28:05 2021 +0300 all: mv more logic to aghstrings commit fac892ec5f0d2e30d6d64def0609267bbae4a202 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:23:23 2021 +0300 dnsforward: use filepath commit 05a3aeef1181b914788d14c7519287d467ab301f Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:17:54 2021 +0300 aghstrings: introduce the pkg commit f24e1b63d6e1bf266a4ed063f46f86d7abf65663 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:01:23 2021 +0300 all: imp code commit 0217a0ebb341f99a90c9b68013bebf6ff73d08ae Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 18:04:13 2021 +0300 openapi: log changes ... and 3 more commits
2021-04-07 18:16:06 +01:00
Pull request 2018: 6231 filter local addrs Merge in DNS/adguard-home from 6231-filter-local-addrs to master Updates #6231. Squashed commit of the following: commit 9a60d4e33f25c7dd7eaa4366d8397389196156ac Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 28 18:59:51 2023 +0300 dnsforward: imp code commit f0c3452525c227b0ee6e761c4a6b68543900d5b5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 27 18:12:47 2023 +0300 all: don't match nets commit 572dc0f24e74560adaa4d89ddc921dfd7e1fed02 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 27 13:37:48 2023 +0300 dnsforward: move some code, rm dups commit 3af627ce9c7f6f4d2aa695a7660b8a0027fa241c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:21:05 2023 +0300 dnsforward: imp naming commit cad1e4e71662836d1dfc79bc2979599b7a29fea1 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:17:53 2023 +0300 dnsforward: imp code commit 23d69700789d5652bd25cc089f16afb8b38e51f8 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:08:48 2023 +0300 dnsforward: add upstream matcher commit 5819c594a2a8d8bf2cd42883133e21ca7ed2681a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 18:31:37 2023 +0300 all: imp code, docs commit d07ea96bb568161e029e22d69329a368d9eeb729 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 18:09:09 2023 +0300 all: imp code commit 38a912a62c63247c4c5bb61b67ccc9bfd255feff Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 15:48:25 2023 +0300 all: imp code commit 811212fa16bc231a8da990c075d7231c471c7e3b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 21 19:05:07 2023 +0300 all: imp addrs detection
2023-09-28 17:11:11 +01:00
defPTRUps, err := s.defaultLocalPTRUpstreams()
if err != nil {
Pull request 2018: 6231 filter local addrs Merge in DNS/adguard-home from 6231-filter-local-addrs to master Updates #6231. Squashed commit of the following: commit 9a60d4e33f25c7dd7eaa4366d8397389196156ac Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 28 18:59:51 2023 +0300 dnsforward: imp code commit f0c3452525c227b0ee6e761c4a6b68543900d5b5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 27 18:12:47 2023 +0300 all: don't match nets commit 572dc0f24e74560adaa4d89ddc921dfd7e1fed02 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 27 13:37:48 2023 +0300 dnsforward: move some code, rm dups commit 3af627ce9c7f6f4d2aa695a7660b8a0027fa241c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:21:05 2023 +0300 dnsforward: imp naming commit cad1e4e71662836d1dfc79bc2979599b7a29fea1 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:17:53 2023 +0300 dnsforward: imp code commit 23d69700789d5652bd25cc089f16afb8b38e51f8 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:08:48 2023 +0300 dnsforward: add upstream matcher commit 5819c594a2a8d8bf2cd42883133e21ca7ed2681a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 18:31:37 2023 +0300 all: imp code, docs commit d07ea96bb568161e029e22d69329a368d9eeb729 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 18:09:09 2023 +0300 all: imp code commit 38a912a62c63247c4c5bb61b67ccc9bfd255feff Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 15:48:25 2023 +0300 all: imp code commit 811212fa16bc231a8da990c075d7231c471c7e3b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 21 19:05:07 2023 +0300 all: imp addrs detection
2023-09-28 17:11:11 +01:00
log.Error("dnsforward: %s", err)
}
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
return &jsonDNSConfig{
Upstreams: &upstreams,
UpstreamsFile: &upstreamFile,
Bootstraps: &bootstraps,
Fallbacks: &fallbacks,
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
ProtectionEnabled: &protectionEnabled,
BlockingMode: &blockingMode,
BlockingIPv4: blockingIPv4,
BlockingIPv6: blockingIPv6,
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
Ratelimit: &ratelimit,
RatelimitSubnetLenIPv4: &ratelimitSubnetLenIPv4,
RatelimitSubnetLenIPv6: &ratelimitSubnetLenIPv6,
RatelimitWhitelist: &ratelimitWhitelist,
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
EDNSCSCustomIP: customIP,
EDNSCSEnabled: &enableEDNSClientSubnet,
EDNSCSUseCustom: &useCustom,
DNSSECEnabled: &enableDNSSEC,
DisableIPv6: &aaaaDisabled,
BlockedResponseTTL: &blockedResponseTTL,
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
CacheSize: &cacheSize,
CacheMinTTL: &cacheMinTTL,
CacheMaxTTL: &cacheMaxTTL,
CacheOptimistic: &cacheOptimistic,
UpstreamMode: &upstreamMode,
ResolveClients: &resolveClients,
UsePrivateRDNS: &usePrivateRDNS,
LocalPTRUpstreams: &localPTRUpstreams,
Pull request 2018: 6231 filter local addrs Merge in DNS/adguard-home from 6231-filter-local-addrs to master Updates #6231. Squashed commit of the following: commit 9a60d4e33f25c7dd7eaa4366d8397389196156ac Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 28 18:59:51 2023 +0300 dnsforward: imp code commit f0c3452525c227b0ee6e761c4a6b68543900d5b5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 27 18:12:47 2023 +0300 all: don't match nets commit 572dc0f24e74560adaa4d89ddc921dfd7e1fed02 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 27 13:37:48 2023 +0300 dnsforward: move some code, rm dups commit 3af627ce9c7f6f4d2aa695a7660b8a0027fa241c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:21:05 2023 +0300 dnsforward: imp naming commit cad1e4e71662836d1dfc79bc2979599b7a29fea1 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:17:53 2023 +0300 dnsforward: imp code commit 23d69700789d5652bd25cc089f16afb8b38e51f8 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:08:48 2023 +0300 dnsforward: add upstream matcher commit 5819c594a2a8d8bf2cd42883133e21ca7ed2681a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 18:31:37 2023 +0300 all: imp code, docs commit d07ea96bb568161e029e22d69329a368d9eeb729 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 18:09:09 2023 +0300 all: imp code commit 38a912a62c63247c4c5bb61b67ccc9bfd255feff Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 15:48:25 2023 +0300 all: imp code commit 811212fa16bc231a8da990c075d7231c471c7e3b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 21 19:05:07 2023 +0300 all: imp addrs detection
2023-09-28 17:11:11 +01:00
DefaultLocalPTRUpstreams: defPTRUps,
DisabledUntil: protectionDisabledUntil,
}
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
}
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 2018: 6231 filter local addrs Merge in DNS/adguard-home from 6231-filter-local-addrs to master Updates #6231. Squashed commit of the following: commit 9a60d4e33f25c7dd7eaa4366d8397389196156ac Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 28 18:59:51 2023 +0300 dnsforward: imp code commit f0c3452525c227b0ee6e761c4a6b68543900d5b5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 27 18:12:47 2023 +0300 all: don't match nets commit 572dc0f24e74560adaa4d89ddc921dfd7e1fed02 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 27 13:37:48 2023 +0300 dnsforward: move some code, rm dups commit 3af627ce9c7f6f4d2aa695a7660b8a0027fa241c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:21:05 2023 +0300 dnsforward: imp naming commit cad1e4e71662836d1dfc79bc2979599b7a29fea1 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:17:53 2023 +0300 dnsforward: imp code commit 23d69700789d5652bd25cc089f16afb8b38e51f8 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:08:48 2023 +0300 dnsforward: add upstream matcher commit 5819c594a2a8d8bf2cd42883133e21ca7ed2681a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 18:31:37 2023 +0300 all: imp code, docs commit d07ea96bb568161e029e22d69329a368d9eeb729 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 18:09:09 2023 +0300 all: imp code commit 38a912a62c63247c4c5bb61b67ccc9bfd255feff Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 15:48:25 2023 +0300 all: imp code commit 811212fa16bc231a8da990c075d7231c471c7e3b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 21 19:05:07 2023 +0300 all: imp addrs detection
2023-09-28 17:11:11 +01:00
// defaultLocalPTRUpstreams returns the list of default local PTR resolvers
// filtered of AdGuard Home's own DNS server addresses. It may appear empty.
func (s *Server) defaultLocalPTRUpstreams() (ups []string, err error) {
matcher, err := s.conf.ourAddrsSet()
Pull request 2018: 6231 filter local addrs Merge in DNS/adguard-home from 6231-filter-local-addrs to master Updates #6231. Squashed commit of the following: commit 9a60d4e33f25c7dd7eaa4366d8397389196156ac Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 28 18:59:51 2023 +0300 dnsforward: imp code commit f0c3452525c227b0ee6e761c4a6b68543900d5b5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 27 18:12:47 2023 +0300 all: don't match nets commit 572dc0f24e74560adaa4d89ddc921dfd7e1fed02 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 27 13:37:48 2023 +0300 dnsforward: move some code, rm dups commit 3af627ce9c7f6f4d2aa695a7660b8a0027fa241c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:21:05 2023 +0300 dnsforward: imp naming commit cad1e4e71662836d1dfc79bc2979599b7a29fea1 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:17:53 2023 +0300 dnsforward: imp code commit 23d69700789d5652bd25cc089f16afb8b38e51f8 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:08:48 2023 +0300 dnsforward: add upstream matcher commit 5819c594a2a8d8bf2cd42883133e21ca7ed2681a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 18:31:37 2023 +0300 all: imp code, docs commit d07ea96bb568161e029e22d69329a368d9eeb729 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 18:09:09 2023 +0300 all: imp code commit 38a912a62c63247c4c5bb61b67ccc9bfd255feff Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 15:48:25 2023 +0300 all: imp code commit 811212fa16bc231a8da990c075d7231c471c7e3b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 21 19:05:07 2023 +0300 all: imp addrs detection
2023-09-28 17:11:11 +01:00
if err != nil {
// Don't wrap the error because it's informative enough as is.
return nil, err
Pull request 2018: 6231 filter local addrs Merge in DNS/adguard-home from 6231-filter-local-addrs to master Updates #6231. Squashed commit of the following: commit 9a60d4e33f25c7dd7eaa4366d8397389196156ac Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 28 18:59:51 2023 +0300 dnsforward: imp code commit f0c3452525c227b0ee6e761c4a6b68543900d5b5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 27 18:12:47 2023 +0300 all: don't match nets commit 572dc0f24e74560adaa4d89ddc921dfd7e1fed02 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 27 13:37:48 2023 +0300 dnsforward: move some code, rm dups commit 3af627ce9c7f6f4d2aa695a7660b8a0027fa241c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:21:05 2023 +0300 dnsforward: imp naming commit cad1e4e71662836d1dfc79bc2979599b7a29fea1 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:17:53 2023 +0300 dnsforward: imp code commit 23d69700789d5652bd25cc089f16afb8b38e51f8 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:08:48 2023 +0300 dnsforward: add upstream matcher commit 5819c594a2a8d8bf2cd42883133e21ca7ed2681a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 18:31:37 2023 +0300 all: imp code, docs commit d07ea96bb568161e029e22d69329a368d9eeb729 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 18:09:09 2023 +0300 all: imp code commit 38a912a62c63247c4c5bb61b67ccc9bfd255feff Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 15:48:25 2023 +0300 all: imp code commit 811212fa16bc231a8da990c075d7231c471c7e3b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 21 19:05:07 2023 +0300 all: imp addrs detection
2023-09-28 17:11:11 +01:00
}
sysResolvers := slices.DeleteFunc(slices.Clone(s.sysResolvers.Addrs()), matcher.Has)
ups = make([]string, 0, len(sysResolvers))
for _, r := range sysResolvers {
ups = append(ups, r.String())
Pull request 2018: 6231 filter local addrs Merge in DNS/adguard-home from 6231-filter-local-addrs to master Updates #6231. Squashed commit of the following: commit 9a60d4e33f25c7dd7eaa4366d8397389196156ac Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 28 18:59:51 2023 +0300 dnsforward: imp code commit f0c3452525c227b0ee6e761c4a6b68543900d5b5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 27 18:12:47 2023 +0300 all: don't match nets commit 572dc0f24e74560adaa4d89ddc921dfd7e1fed02 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Sep 27 13:37:48 2023 +0300 dnsforward: move some code, rm dups commit 3af627ce9c7f6f4d2aa695a7660b8a0027fa241c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:21:05 2023 +0300 dnsforward: imp naming commit cad1e4e71662836d1dfc79bc2979599b7a29fea1 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:17:53 2023 +0300 dnsforward: imp code commit 23d69700789d5652bd25cc089f16afb8b38e51f8 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Sep 25 19:08:48 2023 +0300 dnsforward: add upstream matcher commit 5819c594a2a8d8bf2cd42883133e21ca7ed2681a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 18:31:37 2023 +0300 all: imp code, docs commit d07ea96bb568161e029e22d69329a368d9eeb729 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 18:09:09 2023 +0300 all: imp code commit 38a912a62c63247c4c5bb61b67ccc9bfd255feff Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Sep 22 15:48:25 2023 +0300 all: imp code commit 811212fa16bc231a8da990c075d7231c471c7e3b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Sep 21 19:05:07 2023 +0300 all: imp addrs detection
2023-09-28 17:11:11 +01:00
}
return ups, nil
}
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
// handleGetConfig handles requests to the GET /control/dns_info endpoint.
func (s *Server) handleGetConfig(w http.ResponseWriter, r *http.Request) {
resp := s.getDNSConfig()
Pull request 1907: 951-blocked-services-schedule-api Updates #951. Squashed commit of the following: commit 6b840fd516f5a87fde0420e3aceb9c239b22c974 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Aug 29 19:53:03 2023 +0300 client: imp docs more commit 7fc8f0363fbe4c4266cb0f67428fe4d18c351d2d Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Aug 29 19:40:00 2023 +0300 client: imp docs commit 00bc14d5760614f2797714cdc2c4c19b1a94b86e Author: Ildar Kamalov <ik@adguard.com> Date: Mon Aug 28 18:43:49 2023 +0300 try to fix lock file commit d749df74b576091e0b58928d86ea8b3b49f919da Merge: c69f9230b e1f6229e5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Aug 28 18:14:02 2023 +0300 Merge branch 'master' into 951-blocked-services-schedule-api commit c69f9230b12f7c983db06b74324b3df77d74b32b Author: Ildar Kamalov <ik@adguard.com> Date: Mon Aug 28 17:16:20 2023 +0300 revert eslintrc commit b37916c2dff0ddea5293d87570bb58e3443d2d21 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Aug 28 12:02:39 2023 +0300 fix translations commit f5bb67d81506c687d0abd580049a3eee0af808e0 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Aug 28 11:43:57 2023 +0300 fix helpers commit 13ec6a8b3a0acfb62762ae7e46c6e98eb7c82212 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Aug 28 11:24:57 2023 +0300 remove todo commit 23724ec2fd683ed17b9f1cee841ad9aaf4c9d04f Author: Ildar Kamalov <ik@adguard.com> Date: Mon Aug 28 09:56:56 2023 +0300 add clients schedule form commit 84d29e558a329068e64e7a95ee183946aa4515b5 Author: Ildar Kamalov <ik@adguard.com> Date: Fri Aug 25 17:44:40 2023 +0300 fix schedule form commit 83e4017688082e9eb670091d5a24d98157050502 Author: Ildar Kamalov <ik@adguard.com> Date: Fri Aug 18 12:58:16 2023 +0300 remove unused commit ef2b68e138da382e3cf42586ae604e12d9493504 Author: Ildar Kamalov <ik@adguard.com> Date: Fri Aug 18 12:57:37 2023 +0300 client: fix translation string commit 32ea80c968f52f18adbc811b2f06874644cdfe20 Author: Ildar Kamalov <ik@adguard.com> Date: Fri Aug 18 12:26:26 2023 +0300 wip schedule commit 9b770873859186c9424c8d108812e32ddff33bad Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Jul 21 14:29:50 2023 +0300 all: imp naming commit ea4e9514ea3b264bcce7f2a301db817de4e87059 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Jul 19 18:09:27 2023 +0300 all: imp code commit 98a705bdaa5c1e79394c73e5d75af2416fe9f297 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Jul 18 18:23:26 2023 +0300 all: imp naming commit 4f84b55c7bfc9f7b680feac0ec45f5ea9189299a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Jul 14 15:01:17 2023 +0300 all: add global schedule api commit 87cf1646869ee9138964b47a27b7493674c8854a Merge: cabb80ac1 2adc8624c Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Jul 14 12:09:29 2023 +0300 Merge branch 'master' into 951-blocked-services-schedule-api commit cabb80ac16de437a8118bb0166479574379c97a3 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Jul 13 13:37:23 2023 +0300 openapi: fix typo commit 2279b03acbcfc3d76216f8aaf30ae1c7894127bc Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Jul 13 12:26:19 2023 +0300 all: imp docs ... and 3 more commits
2023-08-29 18:03:40 +01:00
aghhttp.WriteJSONResponseOK(w, r, resp)
}
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
// checkBlockingMode returns an error if blocking mode is invalid.
func (req *jsonDNSConfig) checkBlockingMode() (err error) {
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
if req.BlockingMode == nil {
return nil
2019-11-08 13:19:56 +00:00
}
return validateBlockingMode(*req.BlockingMode, req.BlockingIPv4, req.BlockingIPv6)
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: AG-28771 conf upstream mode Squashed commit of the following: commit afb5a0d8a499bccf7761baea40910f39c92b8a20 Merge: 09ac43c85 abf20c6de Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 25 12:55:45 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode commit 09ac43c859ef8cbd3bb0488d1a945589cd59ca19 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 14:36:07 2023 +0200 openapi: imp docs commit d0fbd4349e4bddde73c6e92f75854acfc481ac0d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:47:10 2023 +0200 all: changelog commit 105f9c50738733b0736a768fb9ee09d2e7fbf42e Merge: 62a2cf12d 4bc5c346a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:27:21 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode # Conflicts: # openapi/CHANGELOG.md commit 62a2cf12df694611888e840a5041a9c517cdfddb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 10:52:59 2023 +0200 openapi: imp docs commit 87956c49240da44b216489920feff69996e3502b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Dec 21 12:08:07 2023 +0200 dnsforward: imp code commit bf74d67ad112735d557be3d8fac75964cd99e375 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:46:38 2023 +0200 dnsforward: imp code commit 3a98dee88809a25118a14a1f07eeecbfccb14cd9 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:41:06 2023 +0200 dnsforward: imp code commit 1499da1fa0319ac3ad914171e807446f2c4d2fdb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:36:28 2023 +0200 dnsforward: imp code commit 228c61a5a0f73cc13655cef8bdaa1995b3f7fced Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:06:11 2023 +0200 dnsforward: imp code commit 069ee22c6d904db4e983135ce87a9fe8d12b7e9a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:39:25 2023 +0200 dnsforward: imp code commit 90919f99a975862dcb07ac82fb740e4404e48bae Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:10:43 2023 +0200 confmigrate: fix commit a8c329950423b59098d1f2b16d1da7100dd54f8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:08:05 2023 +0200 dnsforward: imp code commit 58b53ccd97d353fab0df29f13425b5e341c8fdeb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 18 15:10:01 2023 +0200 all: conf upstream mode
2023-12-25 11:16:48 +00:00
// checkUpstreamMode returns an error if the upstream mode is invalid.
func (req *jsonDNSConfig) checkUpstreamMode() (err error) {
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
if req.UpstreamMode == nil {
return nil
}
Pull request: AG-28771 conf upstream mode Squashed commit of the following: commit afb5a0d8a499bccf7761baea40910f39c92b8a20 Merge: 09ac43c85 abf20c6de Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 25 12:55:45 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode commit 09ac43c859ef8cbd3bb0488d1a945589cd59ca19 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 14:36:07 2023 +0200 openapi: imp docs commit d0fbd4349e4bddde73c6e92f75854acfc481ac0d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:47:10 2023 +0200 all: changelog commit 105f9c50738733b0736a768fb9ee09d2e7fbf42e Merge: 62a2cf12d 4bc5c346a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:27:21 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode # Conflicts: # openapi/CHANGELOG.md commit 62a2cf12df694611888e840a5041a9c517cdfddb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 10:52:59 2023 +0200 openapi: imp docs commit 87956c49240da44b216489920feff69996e3502b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Dec 21 12:08:07 2023 +0200 dnsforward: imp code commit bf74d67ad112735d557be3d8fac75964cd99e375 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:46:38 2023 +0200 dnsforward: imp code commit 3a98dee88809a25118a14a1f07eeecbfccb14cd9 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:41:06 2023 +0200 dnsforward: imp code commit 1499da1fa0319ac3ad914171e807446f2c4d2fdb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:36:28 2023 +0200 dnsforward: imp code commit 228c61a5a0f73cc13655cef8bdaa1995b3f7fced Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:06:11 2023 +0200 dnsforward: imp code commit 069ee22c6d904db4e983135ce87a9fe8d12b7e9a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:39:25 2023 +0200 dnsforward: imp code commit 90919f99a975862dcb07ac82fb740e4404e48bae Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:10:43 2023 +0200 confmigrate: fix commit a8c329950423b59098d1f2b16d1da7100dd54f8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:08:05 2023 +0200 dnsforward: imp code commit 58b53ccd97d353fab0df29f13425b5e341c8fdeb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 18 15:10:01 2023 +0200 all: conf upstream mode
2023-12-25 11:16:48 +00:00
switch um := *req.UpstreamMode; um {
case
jsonUpstreamModeEmpty,
jsonUpstreamModeLoadBalance,
jsonUpstreamModeParallel,
jsonUpstreamModeFastestAddr:
return nil
default:
return fmt.Errorf("upstream_mode: incorrect value %q", um)
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
}
}
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
// checkBootstrap returns an error if any bootstrap address is invalid.
func (req *jsonDNSConfig) checkBootstrap() (err error) {
if req.Bootstraps == nil {
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
}
var b string
defer func() { err = errors.Annotate(err, "checking bootstrap %s: %w", b) }()
for _, b = range *req.Bootstraps {
if b == "" {
return errors.Error("empty")
}
var resolver *upstream.UpstreamResolver
if resolver, err = upstream.NewUpstreamResolver(b, nil); err != nil {
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
// Don't wrap the error because it's informative enough as is.
return 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
}
if err = resolver.Close(); err != nil {
return fmt.Errorf("closing %s: %w", b, 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
}
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
}
// checkFallbacks returns an error if any fallback address is invalid.
func (req *jsonDNSConfig) checkFallbacks() (err error) {
if req.Fallbacks == nil {
return nil
}
Pull request 2107: AG-28327-upstream-config-parser Squashed commit of the following: commit e496653b10de52676826ed8e0c461e91405603a8 Merge: db2cd04e9 60a978c9a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Feb 1 18:23:50 2024 +0300 Merge branch 'master' into AG-28327-upstream-config-parser commit db2cd04e981dd24998d87f4935ff6590ea7854cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Jan 31 16:21:53 2024 +0300 all: upd proxy commit e8878179b6d094321d56fb2b75c16c1ba8cf637d Merge: ccbbae6d6 aa872dfe9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Jan 31 16:17:34 2024 +0300 Merge branch 'master' into AG-28327-upstream-config-parser commit ccbbae6d615e110d7d2d4c2a6b35954311153bcf Merge: d947d900e 8936c95ec Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 29 18:31:17 2024 +0300 Merge branch 'master' into AG-28327-upstream-config-parser commit d947d900e1f759159bc9068589ffe852483cfdd0 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 29 18:26:01 2024 +0300 dnsforward: imp docs commit cf9678c098951e2a4bebae7a3a5808d7de4c14c6 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Jan 25 14:18:04 2024 +0300 dnsforward: imp code commit 22792a9311cb93b2bb3b804293f87f091b9b81e2 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Jan 24 13:59:28 2024 +0300 dnsforward: imp code commit 57ddaaaaaf1009c65f0d9d6b2b1671211f194c85 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 22 20:19:44 2024 +0300 all: add tests commit d6732d13adae4ee46410252a33d092e67da3c34a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 22 18:44:57 2024 +0300 all: imp errors commit e14456571ce2ef43fb217f45445729ce6299daf6 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Jan 18 19:05:31 2024 +0300 dnsforward: imp code commit a5c106eae902fbc0a169ef9e4d7bf968f1e40bec Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 15 18:36:30 2024 +0300 dnsforward: imp logs commit 333b8561aa21d778007f808fb8e931ef3e95d721 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Dec 21 15:06:42 2023 +0300 all: imp tests commit 5b19d6b039755577e03ffcc03952724a36f21aa4 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Dec 15 14:21:58 2023 +0300 all: imp code commit 15fbd229de336425bde107a4f32175b8af41d876 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Dec 13 14:49:40 2023 +0300 all: upstream config parser
2024-02-05 13:12:27 +00:00
_, err = proxy.ParseUpstreamsConfig(*req.Fallbacks, &upstream.Options{})
if err != nil {
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
return fmt.Errorf("fallback servers: %w", err)
}
return nil
}
// validate returns an error if any field of req is invalid.
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
//
// TODO(s.chzhen): Parse, don't validate.
func (req *jsonDNSConfig) validate(privateNets netutil.SubnetSet) (err error) {
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
defer func() { err = errors.Annotate(err, "validating dns config: %w") }()
err = req.validateUpstreamDNSServers(privateNets)
if err != nil {
// Don't wrap the error since it's informative enough as is.
return err
}
err = req.checkRatelimitSubnetMaskLen()
if err != nil {
// Don't wrap the error since it's informative enough as is.
return err
}
err = req.checkBlockingMode()
if err != nil {
// Don't wrap the error since it's informative enough as is.
return err
}
Pull request: AG-28771 conf upstream mode Squashed commit of the following: commit afb5a0d8a499bccf7761baea40910f39c92b8a20 Merge: 09ac43c85 abf20c6de Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 25 12:55:45 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode commit 09ac43c859ef8cbd3bb0488d1a945589cd59ca19 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 14:36:07 2023 +0200 openapi: imp docs commit d0fbd4349e4bddde73c6e92f75854acfc481ac0d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:47:10 2023 +0200 all: changelog commit 105f9c50738733b0736a768fb9ee09d2e7fbf42e Merge: 62a2cf12d 4bc5c346a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:27:21 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode # Conflicts: # openapi/CHANGELOG.md commit 62a2cf12df694611888e840a5041a9c517cdfddb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 10:52:59 2023 +0200 openapi: imp docs commit 87956c49240da44b216489920feff69996e3502b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Dec 21 12:08:07 2023 +0200 dnsforward: imp code commit bf74d67ad112735d557be3d8fac75964cd99e375 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:46:38 2023 +0200 dnsforward: imp code commit 3a98dee88809a25118a14a1f07eeecbfccb14cd9 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:41:06 2023 +0200 dnsforward: imp code commit 1499da1fa0319ac3ad914171e807446f2c4d2fdb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:36:28 2023 +0200 dnsforward: imp code commit 228c61a5a0f73cc13655cef8bdaa1995b3f7fced Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:06:11 2023 +0200 dnsforward: imp code commit 069ee22c6d904db4e983135ce87a9fe8d12b7e9a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:39:25 2023 +0200 dnsforward: imp code commit 90919f99a975862dcb07ac82fb740e4404e48bae Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:10:43 2023 +0200 confmigrate: fix commit a8c329950423b59098d1f2b16d1da7100dd54f8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:08:05 2023 +0200 dnsforward: imp code commit 58b53ccd97d353fab0df29f13425b5e341c8fdeb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 18 15:10:01 2023 +0200 all: conf upstream mode
2023-12-25 11:16:48 +00:00
err = req.checkUpstreamMode()
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
if err != nil {
// Don't wrap the error since it's informative enough as is.
return err
}
err = req.checkCacheTTL()
if err != nil {
// Don't wrap the error since it's informative enough as is.
return err
}
return nil
}
// validateUpstreamDNSServers returns an error if any field of req is invalid.
func (req *jsonDNSConfig) validateUpstreamDNSServers(privateNets netutil.SubnetSet) (err error) {
if req.Upstreams != nil {
Pull request 2107: AG-28327-upstream-config-parser Squashed commit of the following: commit e496653b10de52676826ed8e0c461e91405603a8 Merge: db2cd04e9 60a978c9a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Feb 1 18:23:50 2024 +0300 Merge branch 'master' into AG-28327-upstream-config-parser commit db2cd04e981dd24998d87f4935ff6590ea7854cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Jan 31 16:21:53 2024 +0300 all: upd proxy commit e8878179b6d094321d56fb2b75c16c1ba8cf637d Merge: ccbbae6d6 aa872dfe9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Jan 31 16:17:34 2024 +0300 Merge branch 'master' into AG-28327-upstream-config-parser commit ccbbae6d615e110d7d2d4c2a6b35954311153bcf Merge: d947d900e 8936c95ec Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 29 18:31:17 2024 +0300 Merge branch 'master' into AG-28327-upstream-config-parser commit d947d900e1f759159bc9068589ffe852483cfdd0 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 29 18:26:01 2024 +0300 dnsforward: imp docs commit cf9678c098951e2a4bebae7a3a5808d7de4c14c6 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Jan 25 14:18:04 2024 +0300 dnsforward: imp code commit 22792a9311cb93b2bb3b804293f87f091b9b81e2 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Jan 24 13:59:28 2024 +0300 dnsforward: imp code commit 57ddaaaaaf1009c65f0d9d6b2b1671211f194c85 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 22 20:19:44 2024 +0300 all: add tests commit d6732d13adae4ee46410252a33d092e67da3c34a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 22 18:44:57 2024 +0300 all: imp errors commit e14456571ce2ef43fb217f45445729ce6299daf6 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Jan 18 19:05:31 2024 +0300 dnsforward: imp code commit a5c106eae902fbc0a169ef9e4d7bf968f1e40bec Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Jan 15 18:36:30 2024 +0300 dnsforward: imp logs commit 333b8561aa21d778007f808fb8e931ef3e95d721 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Thu Dec 21 15:06:42 2023 +0300 all: imp tests commit 5b19d6b039755577e03ffcc03952724a36f21aa4 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Dec 15 14:21:58 2023 +0300 all: imp code commit 15fbd229de336425bde107a4f32175b8af41d876 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Dec 13 14:49:40 2023 +0300 all: upstream config parser
2024-02-05 13:12:27 +00:00
_, err = proxy.ParseUpstreamsConfig(*req.Upstreams, &upstream.Options{})
if err != nil {
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
return fmt.Errorf("upstream servers: %w", 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
}
if req.LocalPTRUpstreams != nil {
err = ValidateUpstreamsPrivate(*req.LocalPTRUpstreams, privateNets)
if err != nil {
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
return fmt.Errorf("private upstream servers: %w", 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: 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
err = req.checkBootstrap()
if err != nil {
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
// Don't wrap the error since it's informative enough as is.
return err
2019-11-08 13:19:56 +00:00
}
err = req.checkFallbacks()
if err != nil {
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
// Don't wrap the error since it's informative enough as is.
return err
}
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
return nil
}
// checkCacheTTL returns an error if the configuration of the cache TTL is
// invalid.
func (req *jsonDNSConfig) checkCacheTTL() (err error) {
if req.CacheMinTTL == nil && req.CacheMaxTTL == nil {
return nil
}
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
var minTTL, maxTTL uint32
if req.CacheMinTTL != nil {
minTTL = *req.CacheMinTTL
}
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
if req.CacheMaxTTL != nil {
maxTTL = *req.CacheMaxTTL
}
return validateCacheTTL(minTTL, maxTTL)
2019-11-08 13:19:56 +00:00
}
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
// checkRatelimitSubnetMaskLen returns an error if the length of the subnet mask
// for IPv4 or IPv6 addresses is invalid.
func (req *jsonDNSConfig) checkRatelimitSubnetMaskLen() (err error) {
err = checkInclusion(req.RatelimitSubnetLenIPv4, 0, netutil.IPv4BitLen)
if err != nil {
return fmt.Errorf("ratelimit_subnet_len_ipv4 is invalid: %w", 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 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
err = checkInclusion(req.RatelimitSubnetLenIPv6, 0, netutil.IPv6BitLen)
if err != nil {
return fmt.Errorf("ratelimit_subnet_len_ipv6 is invalid: %w", err)
}
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
return nil
}
// checkInclusion returns an error if a ptr is not nil and points to value,
// that not in the inclusive range between minN and maxN.
func checkInclusion(ptr *int, minN, maxN int) (err error) {
if ptr == nil {
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 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
n := *ptr
switch {
case n < minN:
return fmt.Errorf("value %d less than min %d", n, minN)
case n > maxN:
return fmt.Errorf("value %d greater than max %d", n, maxN)
}
return nil
}
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
// handleSetConfig handles requests to the POST /control/dns_config endpoint.
func (s *Server) handleSetConfig(w http.ResponseWriter, r *http.Request) {
req := &jsonDNSConfig{}
err := json.NewDecoder(r.Body).Decode(req)
if err != nil {
aghhttp.Error(r, w, http.StatusBadRequest, "decoding request: %s", err)
return
}
err = req.validate(s.privateNets)
if err != nil {
aghhttp.Error(r, w, http.StatusBadRequest, "%s", err)
return
}
restart := s.setConfig(req)
s.conf.ConfigModified()
if restart {
err = s.Reconfigure(nil)
if err != nil {
aghhttp.Error(r, w, http.StatusInternalServerError, "%s", 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 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
// setConfig sets the server parameters. shouldRestart is true if the server
// should be restarted to apply changes.
func (s *Server) setConfig(dc *jsonDNSConfig) (shouldRestart bool) {
s.serverLock.Lock()
defer s.serverLock.Unlock()
if dc.BlockingMode != nil {
s.dnsFilter.SetBlockingMode(*dc.BlockingMode, dc.BlockingIPv4, dc.BlockingIPv6)
}
if dc.BlockedResponseTTL != nil {
s.dnsFilter.SetBlockedResponseTTL(*dc.BlockedResponseTTL)
}
if dc.ProtectionEnabled != nil {
s.dnsFilter.SetProtectionEnabled(*dc.ProtectionEnabled)
+ DNS: add fastest_addr setting * API: /dns_info, /dns_config: add "parallel_requests" instead of "all_servers" from /set_upstreams_config * API: /status: removed fields #715 Squashed commit of the following: commit 7dd913bd336ecbaa7419b998d0bf913d89702fe6 Merge: 43706970 8170955a Author: Simon Zolin <s.zolin@adguard.com> Date: Wed Apr 22 19:09:36 2020 +0300 Merge remote-tracking branch 'origin/master' into 715-fastest-addr commit 437069702a3e91e0b066e4b22b08cdc02ff19eaf Author: Simon Zolin <s.zolin@adguard.com> Date: Wed Apr 22 19:08:55 2020 +0300 minor commit 9e713df80c5bf113c98794c0a20915c756a76938 Merge: e3bf4037 9b7c1181 Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Apr 21 16:02:03 2020 +0300 Merge remote-tracking branch 'origin/master' into 715-fastest-addr commit e3bf4037f49198e42bde55305d6f9077341b556a Author: Simon Zolin <s.zolin@adguard.com> Date: Tue Apr 21 15:40:49 2020 +0300 minor commit d6e6a823c5e51acc061b2850d362772efcb827e1 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Apr 17 17:56:24 2020 +0300 * API changes . removed POST /set_upstreams_config . removed fields from GET /status: bootstrap_dns, upstream_dns, all_servers . added new fields to /dns_config and /dns_info commit 237a452d09cc48ff8f00e81c7fd35e7828bea835 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Apr 17 16:43:13 2020 +0300 * API: /dns_info, /dns_config: add "parallel_requests" instead of "all_servers" from /set_upstreams_config commit 9976723b9725ed19e0cce152d1d1198b13c4acc1 Author: Simon Zolin <s.zolin@adguard.com> Date: Mon Mar 23 10:28:25 2020 +0300 openapi commit 6f8ea16c6332606f29095b0094d71e8a91798f82 Merge: 36e4d4e8 c8285c41 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Mar 20 19:18:48 2020 +0300 Merge remote-tracking branch 'origin/master' into 715-fastest-addr commit 36e4d4e82cadeaba5a11313f0d69d66a0924c342 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Mar 20 18:13:43 2020 +0300 + DNS: add fastest_addr setting
2020-04-22 17:14:04 +01:00
}
if dc.UpstreamMode != nil {
Pull request: AG-28771 conf upstream mode Squashed commit of the following: commit afb5a0d8a499bccf7761baea40910f39c92b8a20 Merge: 09ac43c85 abf20c6de Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 25 12:55:45 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode commit 09ac43c859ef8cbd3bb0488d1a945589cd59ca19 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 14:36:07 2023 +0200 openapi: imp docs commit d0fbd4349e4bddde73c6e92f75854acfc481ac0d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:47:10 2023 +0200 all: changelog commit 105f9c50738733b0736a768fb9ee09d2e7fbf42e Merge: 62a2cf12d 4bc5c346a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:27:21 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode # Conflicts: # openapi/CHANGELOG.md commit 62a2cf12df694611888e840a5041a9c517cdfddb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 10:52:59 2023 +0200 openapi: imp docs commit 87956c49240da44b216489920feff69996e3502b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Dec 21 12:08:07 2023 +0200 dnsforward: imp code commit bf74d67ad112735d557be3d8fac75964cd99e375 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:46:38 2023 +0200 dnsforward: imp code commit 3a98dee88809a25118a14a1f07eeecbfccb14cd9 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:41:06 2023 +0200 dnsforward: imp code commit 1499da1fa0319ac3ad914171e807446f2c4d2fdb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:36:28 2023 +0200 dnsforward: imp code commit 228c61a5a0f73cc13655cef8bdaa1995b3f7fced Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:06:11 2023 +0200 dnsforward: imp code commit 069ee22c6d904db4e983135ce87a9fe8d12b7e9a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:39:25 2023 +0200 dnsforward: imp code commit 90919f99a975862dcb07ac82fb740e4404e48bae Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:10:43 2023 +0200 confmigrate: fix commit a8c329950423b59098d1f2b16d1da7100dd54f8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:08:05 2023 +0200 dnsforward: imp code commit 58b53ccd97d353fab0df29f13425b5e341c8fdeb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 18 15:10:01 2023 +0200 all: conf upstream mode
2023-12-25 11:16:48 +00:00
s.conf.UpstreamMode = mustParseUpstreamMode(*dc.UpstreamMode)
} else {
s.conf.UpstreamMode = UpstreamModeLoadBalance
}
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
if dc.EDNSCSUseCustom != nil && *dc.EDNSCSUseCustom {
s.conf.EDNSClientSubnet.CustomIP = dc.EDNSCSCustomIP
}
setIfNotNil(&s.conf.EnableDNSSEC, dc.DNSSECEnabled)
setIfNotNil(&s.conf.AAAADisabled, dc.DisableIPv6)
return s.setConfigRestartable(dc)
}
Pull request: AG-28771 conf upstream mode Squashed commit of the following: commit afb5a0d8a499bccf7761baea40910f39c92b8a20 Merge: 09ac43c85 abf20c6de Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 25 12:55:45 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode commit 09ac43c859ef8cbd3bb0488d1a945589cd59ca19 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 14:36:07 2023 +0200 openapi: imp docs commit d0fbd4349e4bddde73c6e92f75854acfc481ac0d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:47:10 2023 +0200 all: changelog commit 105f9c50738733b0736a768fb9ee09d2e7fbf42e Merge: 62a2cf12d 4bc5c346a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 11:27:21 2023 +0200 Merge remote-tracking branch 'origin/master' into conf-ups-mode # Conflicts: # openapi/CHANGELOG.md commit 62a2cf12df694611888e840a5041a9c517cdfddb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Dec 22 10:52:59 2023 +0200 openapi: imp docs commit 87956c49240da44b216489920feff69996e3502b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Dec 21 12:08:07 2023 +0200 dnsforward: imp code commit bf74d67ad112735d557be3d8fac75964cd99e375 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:46:38 2023 +0200 dnsforward: imp code commit 3a98dee88809a25118a14a1f07eeecbfccb14cd9 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 15:41:06 2023 +0200 dnsforward: imp code commit 1499da1fa0319ac3ad914171e807446f2c4d2fdb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:36:28 2023 +0200 dnsforward: imp code commit 228c61a5a0f73cc13655cef8bdaa1995b3f7fced Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Dec 20 13:06:11 2023 +0200 dnsforward: imp code commit 069ee22c6d904db4e983135ce87a9fe8d12b7e9a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:39:25 2023 +0200 dnsforward: imp code commit 90919f99a975862dcb07ac82fb740e4404e48bae Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:10:43 2023 +0200 confmigrate: fix commit a8c329950423b59098d1f2b16d1da7100dd54f8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Dec 19 12:08:05 2023 +0200 dnsforward: imp code commit 58b53ccd97d353fab0df29f13425b5e341c8fdeb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Dec 18 15:10:01 2023 +0200 all: conf upstream mode
2023-12-25 11:16:48 +00:00
// mustParseUpstreamMode returns an upstream mode parsed from jsonUpstreamMode.
// Panics in case of invalid value.
func mustParseUpstreamMode(mode jsonUpstreamMode) (um UpstreamMode) {
switch mode {
case jsonUpstreamModeEmpty, jsonUpstreamModeLoadBalance:
return UpstreamModeLoadBalance
case jsonUpstreamModeParallel:
return UpstreamModeParallel
case jsonUpstreamModeFastestAddr:
return UpstreamModeFastestAddr
default:
// Should never happen, since the value should be validated.
panic(fmt.Errorf("unexpected upstream mode: %q", mode))
}
}
// setIfNotNil sets the value pointed at by currentPtr to the value pointed at
// by newPtr if newPtr is not nil. currentPtr must not be nil.
func setIfNotNil[T any](currentPtr, newPtr *T) (hasSet bool) {
if newPtr == nil {
return false
}
*currentPtr = *newPtr
return true
}
// setConfigRestartable sets the parameters which trigger a restart.
// shouldRestart is true if the server should be restarted to apply changes.
// s.serverLock is expected to be locked.
//
// TODO(a.garipov): Some of these could probably be updated without a restart.
// Inspect and consider refactoring.
func (s *Server) setConfigRestartable(dc *jsonDNSConfig) (shouldRestart bool) {
for _, hasSet := range []bool{
setIfNotNil(&s.conf.UpstreamDNS, dc.Upstreams),
setIfNotNil(&s.conf.LocalPTRResolvers, dc.LocalPTRUpstreams),
setIfNotNil(&s.conf.UpstreamDNSFileName, dc.UpstreamsFile),
setIfNotNil(&s.conf.BootstrapDNS, dc.Bootstraps),
setIfNotNil(&s.conf.FallbackDNS, dc.Fallbacks),
Pull request 1744: 1472-edns-custom-ip Merge in DNS/adguard-home from 1472-edns-custom-ip to master Updates #1472. Squashed commit of the following: commit 07460c3adf7747fd9ec1b4a3d04fb459dec44280 Merge: 65455430 ae653f16 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 1 15:38:46 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip commit 65455430993e4a62c49e1f45def909b0a135af3b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 1 15:37:17 2023 +0300 dnsforward: add todo commit e1978ad4b6051f29185ef32973d20bc70f2a6634 Merge: 6cd98f42 bb226434 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 1 11:32:23 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip commit 6cd98f4235b1b52d443c1950f2516af3cc4fb258 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 1 11:31:16 2023 +0300 all: fix chlog; fix field alignment commit defdec623919c23ab446324828d08839469669e1 Merge: 1130ebd5 a772212d Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Feb 28 12:17:23 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip commit 1130ebd509bf4f7ec25fbb53717576e273dbfff2 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Feb 28 12:13:30 2023 +0300 all: add use_custom field commit ec0cdc7af0f96f761ed85516bbcae2567fd6f7d2 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Feb 27 13:59:13 2023 +0300 all: fix chlog; imp code commit f8450cfcd6054f32d6ea0a5e26c551fe153a0b21 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Feb 27 11:28:16 2023 +0300 dnsforward: fix fmt commit 54a344e5bb17aae7ca213ed66b85f06ef6585316 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Feb 27 11:11:52 2023 +0300 all: fix chlog; add test case commit 47b5476f6621c6ea31aa496d4113445a8e8bceb4 Merge: 8724f374 304f2ba2 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Feb 22 16:33:07 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip commit 8724f3745ccc29849a4001f79b055c7ebeb19106 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Feb 22 16:31:40 2023 +0300 all: fix comments commit d2b1528ba333e7669795a3fb80355ff7d90cf4f5 Merge: 7898c23a 76a513cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Feb 22 11:53:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip commit 7898c23ab991bc516bcc2f41e47bed15582fd962 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Feb 22 11:52:37 2023 +0300 all: upd chlog commit 8763261dcb4187a93104955e7cb440965e2b6739 Merge: d28394b3 ff9b24ad Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Feb 21 17:12:03 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip commit d28394b3c980b10f28c6c38ce35f368edb11d314 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Feb 21 17:11:29 2023 +0300 home: fix default value commit 1a5da3f267706baa83eebe1923ea1b0b4e79fd6c Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Feb 21 13:37:04 2023 +0300 all: add custom ip for edns
2023-03-01 13:16:16 +00:00
setIfNotNil(&s.conf.EDNSClientSubnet.Enabled, dc.EDNSCSEnabled),
Pull request 1758: 1472-edns-custom-ip-api Merge in DNS/adguard-home from 1472-edns-custom-ip-api to master Updates #1472 Squashed commit of the following: commit 7605ec5bd5467ddd28a650385193eb2332653bb6 Merge: 8b2ac227 194ead34 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Mar 22 13:39:25 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 8b2ac22793a51d2555d32c1f5b5c118118807d1f Merge: d5ca8b6e c3edab43 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:55 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit d5ca8b6e1d87480d4ee4afd346e6bf04907fca95 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 18:26:24 2023 +0300 dnsforward: imp tests commit 1302586d22812c22755ea1c7e7fcd32330d707c5 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:47:56 2023 +0200 client: change validation for custom edns ip commit 44e4dc6d1e47de6597ed9ee328db9639e38b4868 Author: Vladislav Abdulmyanov <v.abdulmyanov@adguard.com> Date: Tue Mar 21 16:31:42 2023 +0200 client: implement edns custom ip commit 8a3e7ad8ebf16262818821340da23baa5f004bff Merge: 04ac1112 f736d85e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:04:40 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 04ac1112dda2e778243555b2f54819e5ba586e05 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 21 15:03:39 2023 +0300 dnsforward: imp tests commit b44f6d0ccb3ba7b7a5be07c9cf293dad9c83c794 Merge: 19c6851e 48431f8b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 20 17:55:49 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 19c6851e30f30b0572334822e8639e03760de986 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:40:15 2023 +0300 all: fix chlog commit 6dcdcbd666ebf3a56a38251e8ead09c605068ce3 Merge: a7f1bf71 a2053526 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 10 10:23:37 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit a7f1bf715e3557c710b700b9bd923868eb07715b Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:24:18 2023 +0300 home: fix default value commit 0311a9bb6571975963d747ef4ef427b59dca03bc Merge: 7e0bb3df 1011b8f9 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:04:18 2023 +0300 Merge branch 'master' into 1472-edns-custom-ip-api commit 7e0bb3df78f10f4b4ae0fd49681d1aa0040521c5 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 19:03:24 2023 +0300 all: fix chlog commit 202d7ccf4721ccf39726da01d237e07317bfaa58 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:35:41 2023 +0300 dnsforward: fix typo commit fe95e003a0c3b316a44b5ec0b848a60ddd4c85cf Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 11:28:21 2023 +0300 all: fix docs commit 66835a9aa22b3015f9238c1d6f5aa9bd6067db8a Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Mar 7 10:48:08 2023 +0300 dnsforward: add todo commit b58255e1e6660a8229bb9c40f2acddebb3dbdc66 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Mon Mar 6 15:40:02 2023 +0300 all: upd chlog commit 9b2be7facba30c815144e08a7835353cad14c405 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Mar 3 11:22:19 2023 +0300 dnsforward: edns custom ip api
2023-03-22 10:42:20 +00:00
setIfNotNil(&s.conf.EDNSClientSubnet.UseCustom, dc.EDNSCSUseCustom),
setIfNotNil(&s.conf.CacheSize, dc.CacheSize),
setIfNotNil(&s.conf.CacheMinTTL, dc.CacheMinTTL),
setIfNotNil(&s.conf.CacheMaxTTL, dc.CacheMaxTTL),
setIfNotNil(&s.conf.CacheOptimistic, dc.CacheOptimistic),
setIfNotNil(&s.conf.AddrProcConf.UseRDNS, dc.ResolveClients),
setIfNotNil(&s.conf.UsePrivateRDNS, dc.UsePrivateRDNS),
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
setIfNotNil(&s.conf.RatelimitSubnetLenIPv4, dc.RatelimitSubnetLenIPv4),
setIfNotNil(&s.conf.RatelimitSubnetLenIPv6, dc.RatelimitSubnetLenIPv6),
setIfNotNil(&s.conf.RatelimitWhitelist, dc.RatelimitWhitelist),
} {
shouldRestart = shouldRestart || hasSet
if shouldRestart {
break
}
Pull request: 2704 local addresses vol.3 Merge in DNS/adguard-home from 2704-local-addresses-vol.3 to master Updates #2704. Updates #2829. Updates #2928. Squashed commit of the following: commit 8c42355c0093a3ac6951f79a5211e7891800f93a Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:07:41 2021 +0300 dnsforward: rm errors pkg commit 7594a21a620239951039454dd5686a872e6f41a8 Merge: 830b0834 908452f8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:00:03 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 830b0834090510096061fed20b600195ab3773b8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 17:47:51 2021 +0300 dnsforward: reduce local upstream timeout commit 493e81d9e8bacdc690f88af29a38d211b9733c7e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 19:11:00 2021 +0300 client: private_upstream test commit a0194ac28f15114578359b8c2460cd9af621e912 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:36:23 2021 +0300 all: expand api, fix conflicts commit 0f4e06836fed958391aa597c8b02453564980ca3 Merge: 89cf93ad 8746005d Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:35:04 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 89cf93ad4f26c2bf4f1b18ecaa4d3a1e169f9b06 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 18:02:40 2021 +0300 client: add local ptr upstreams to upstream test commit e6dd869dddd4888474d625cbb005bad6390e4760 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 15:24:22 2021 +0300 client: add private DNS form commit b858057b9a957a416117f22b8bd0025f90e8c758 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 13:05:28 2021 +0300 aghstrings: mk cloning correct commit 8009ba60a6a7d6ceb7b6483a29f4e68d533af243 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 12:37:46 2021 +0300 aghstrings: fix lil bug commit 0dd19f2e7cc7c0de21517c37abd8336a907e1c0d Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:45:01 2021 +0300 all: log changes commit eb5558d96fffa6e7bca7e14d3740d26e47382e23 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:18:53 2021 +0300 dnsforward: keep the style commit d6d5fcbde40a633129c0e04887b81cf0b1ce6875 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:02:52 2021 +0300 dnsforward: disable redundant filtering for local ptr commit 4f864c32027d10db9bcb4a264d2338df8c20afac Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 17:53:17 2021 +0300 dnsforward: imp tests commit 7848e6f2341868f8ba0bb839956a0b7444cf02ca Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 14:52:12 2021 +0300 all: imp code commit 19ac30653800eebf8aaee499f65560ae2d458a5a Author: Eugene Burkov <e.burkov@adguard.com> Date: Sun Apr 4 16:28:05 2021 +0300 all: mv more logic to aghstrings commit fac892ec5f0d2e30d6d64def0609267bbae4a202 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:23:23 2021 +0300 dnsforward: use filepath commit 05a3aeef1181b914788d14c7519287d467ab301f Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:17:54 2021 +0300 aghstrings: introduce the pkg commit f24e1b63d6e1bf266a4ed063f46f86d7abf65663 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:01:23 2021 +0300 all: imp code commit 0217a0ebb341f99a90c9b68013bebf6ff73d08ae Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 18:04:13 2021 +0300 openapi: log changes ... and 3 more commits
2021-04-07 18:16:06 +01:00
}
Pull request 2065: 6369-ratelimit-settings-ui Closes #6369. Co-authored-by: IldarKamalov <ik@adguard.com> Squashed commit of the following: commit efc824667a88765d5a16984fd17ecda2559f2b1e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 19:10:47 2023 +0300 all: imp docs commit 9ec59b59000f005006ea231071329a586d9889ac Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 17:21:03 2023 +0300 dnsforward: imp err msg commit d9710dfc1dcf74d5ee8386b053d7180316f21bce Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:33:59 2023 +0300 all: upd chlog commit 29e868b93b15cfce5faed4d0c07b16decbce52f9 Merge: 1c3aec9f1 ebb06a583 Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Wed Nov 15 15:26:32 2023 +0300 Merge branch 'master' into 6369-ratelimit-settings-ui commit 1c3aec9f1478f71afa4d0aa9ba1c454e9d98b8db Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Tue Nov 14 21:21:22 2023 +0300 dnsforward: imp docs commit 486bf86e5a2b51b6014a231386337a2d1e945c23 Author: Ildar Kamalov <ik@adguard.com> Date: Mon Nov 13 09:57:21 2023 +0300 fix linter commit aec088f233737fdfa0e7086148ceb79df0d2e39a Author: Ildar Kamalov <ik@adguard.com> Date: Sun Nov 12 16:13:46 2023 +0300 client: validate rate limit subnets commit d4ca4d3a604295cdfaae54e6e461981233eabf3e Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 20:08:44 2023 +0300 dnsforward: imp code commit 5c11a1ef5c6fcc786d8496b14b9b16d1de1708cd Author: Stanislav Chzhen <s.chzhen@adguard.com> Date: Fri Nov 10 15:07:56 2023 +0300 all: ratelimit settings
2023-11-15 16:27:13 +00:00
if dc.Ratelimit != nil && s.conf.Ratelimit != *dc.Ratelimit {
s.conf.Ratelimit = *dc.Ratelimit
shouldRestart = true
}
return shouldRestart
}
Pull request: 2704 local addresses vol.3 Merge in DNS/adguard-home from 2704-local-addresses-vol.3 to master Updates #2704. Updates #2829. Updates #2928. Squashed commit of the following: commit 8c42355c0093a3ac6951f79a5211e7891800f93a Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:07:41 2021 +0300 dnsforward: rm errors pkg commit 7594a21a620239951039454dd5686a872e6f41a8 Merge: 830b0834 908452f8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:00:03 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 830b0834090510096061fed20b600195ab3773b8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 17:47:51 2021 +0300 dnsforward: reduce local upstream timeout commit 493e81d9e8bacdc690f88af29a38d211b9733c7e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 19:11:00 2021 +0300 client: private_upstream test commit a0194ac28f15114578359b8c2460cd9af621e912 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:36:23 2021 +0300 all: expand api, fix conflicts commit 0f4e06836fed958391aa597c8b02453564980ca3 Merge: 89cf93ad 8746005d Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:35:04 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 89cf93ad4f26c2bf4f1b18ecaa4d3a1e169f9b06 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 18:02:40 2021 +0300 client: add local ptr upstreams to upstream test commit e6dd869dddd4888474d625cbb005bad6390e4760 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 15:24:22 2021 +0300 client: add private DNS form commit b858057b9a957a416117f22b8bd0025f90e8c758 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 13:05:28 2021 +0300 aghstrings: mk cloning correct commit 8009ba60a6a7d6ceb7b6483a29f4e68d533af243 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 12:37:46 2021 +0300 aghstrings: fix lil bug commit 0dd19f2e7cc7c0de21517c37abd8336a907e1c0d Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:45:01 2021 +0300 all: log changes commit eb5558d96fffa6e7bca7e14d3740d26e47382e23 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:18:53 2021 +0300 dnsforward: keep the style commit d6d5fcbde40a633129c0e04887b81cf0b1ce6875 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:02:52 2021 +0300 dnsforward: disable redundant filtering for local ptr commit 4f864c32027d10db9bcb4a264d2338df8c20afac Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 17:53:17 2021 +0300 dnsforward: imp tests commit 7848e6f2341868f8ba0bb839956a0b7444cf02ca Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 14:52:12 2021 +0300 all: imp code commit 19ac30653800eebf8aaee499f65560ae2d458a5a Author: Eugene Burkov <e.burkov@adguard.com> Date: Sun Apr 4 16:28:05 2021 +0300 all: mv more logic to aghstrings commit fac892ec5f0d2e30d6d64def0609267bbae4a202 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:23:23 2021 +0300 dnsforward: use filepath commit 05a3aeef1181b914788d14c7519287d467ab301f Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:17:54 2021 +0300 aghstrings: introduce the pkg commit f24e1b63d6e1bf266a4ed063f46f86d7abf65663 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:01:23 2021 +0300 all: imp code commit 0217a0ebb341f99a90c9b68013bebf6ff73d08ae Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 18:04:13 2021 +0300 openapi: log changes ... and 3 more commits
2021-04-07 18:16:06 +01:00
// upstreamJSON is a request body for handleTestUpstreamDNS endpoint.
type upstreamJSON struct {
Pull request: 2704 local addresses vol.3 Merge in DNS/adguard-home from 2704-local-addresses-vol.3 to master Updates #2704. Updates #2829. Updates #2928. Squashed commit of the following: commit 8c42355c0093a3ac6951f79a5211e7891800f93a Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:07:41 2021 +0300 dnsforward: rm errors pkg commit 7594a21a620239951039454dd5686a872e6f41a8 Merge: 830b0834 908452f8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:00:03 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 830b0834090510096061fed20b600195ab3773b8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 17:47:51 2021 +0300 dnsforward: reduce local upstream timeout commit 493e81d9e8bacdc690f88af29a38d211b9733c7e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 19:11:00 2021 +0300 client: private_upstream test commit a0194ac28f15114578359b8c2460cd9af621e912 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:36:23 2021 +0300 all: expand api, fix conflicts commit 0f4e06836fed958391aa597c8b02453564980ca3 Merge: 89cf93ad 8746005d Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:35:04 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 89cf93ad4f26c2bf4f1b18ecaa4d3a1e169f9b06 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 18:02:40 2021 +0300 client: add local ptr upstreams to upstream test commit e6dd869dddd4888474d625cbb005bad6390e4760 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 15:24:22 2021 +0300 client: add private DNS form commit b858057b9a957a416117f22b8bd0025f90e8c758 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 13:05:28 2021 +0300 aghstrings: mk cloning correct commit 8009ba60a6a7d6ceb7b6483a29f4e68d533af243 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 12:37:46 2021 +0300 aghstrings: fix lil bug commit 0dd19f2e7cc7c0de21517c37abd8336a907e1c0d Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:45:01 2021 +0300 all: log changes commit eb5558d96fffa6e7bca7e14d3740d26e47382e23 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:18:53 2021 +0300 dnsforward: keep the style commit d6d5fcbde40a633129c0e04887b81cf0b1ce6875 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:02:52 2021 +0300 dnsforward: disable redundant filtering for local ptr commit 4f864c32027d10db9bcb4a264d2338df8c20afac Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 17:53:17 2021 +0300 dnsforward: imp tests commit 7848e6f2341868f8ba0bb839956a0b7444cf02ca Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 14:52:12 2021 +0300 all: imp code commit 19ac30653800eebf8aaee499f65560ae2d458a5a Author: Eugene Burkov <e.burkov@adguard.com> Date: Sun Apr 4 16:28:05 2021 +0300 all: mv more logic to aghstrings commit fac892ec5f0d2e30d6d64def0609267bbae4a202 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:23:23 2021 +0300 dnsforward: use filepath commit 05a3aeef1181b914788d14c7519287d467ab301f Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:17:54 2021 +0300 aghstrings: introduce the pkg commit f24e1b63d6e1bf266a4ed063f46f86d7abf65663 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:01:23 2021 +0300 all: imp code commit 0217a0ebb341f99a90c9b68013bebf6ff73d08ae Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 18:04:13 2021 +0300 openapi: log changes ... and 3 more commits
2021-04-07 18:16:06 +01:00
Upstreams []string `json:"upstream_dns"`
BootstrapDNS []string `json:"bootstrap_dns"`
FallbackDNS []string `json:"fallback_dns"`
Pull request: 2704 local addresses vol.3 Merge in DNS/adguard-home from 2704-local-addresses-vol.3 to master Updates #2704. Updates #2829. Updates #2928. Squashed commit of the following: commit 8c42355c0093a3ac6951f79a5211e7891800f93a Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:07:41 2021 +0300 dnsforward: rm errors pkg commit 7594a21a620239951039454dd5686a872e6f41a8 Merge: 830b0834 908452f8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:00:03 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 830b0834090510096061fed20b600195ab3773b8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 17:47:51 2021 +0300 dnsforward: reduce local upstream timeout commit 493e81d9e8bacdc690f88af29a38d211b9733c7e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 19:11:00 2021 +0300 client: private_upstream test commit a0194ac28f15114578359b8c2460cd9af621e912 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:36:23 2021 +0300 all: expand api, fix conflicts commit 0f4e06836fed958391aa597c8b02453564980ca3 Merge: 89cf93ad 8746005d Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:35:04 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 89cf93ad4f26c2bf4f1b18ecaa4d3a1e169f9b06 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 18:02:40 2021 +0300 client: add local ptr upstreams to upstream test commit e6dd869dddd4888474d625cbb005bad6390e4760 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 15:24:22 2021 +0300 client: add private DNS form commit b858057b9a957a416117f22b8bd0025f90e8c758 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 13:05:28 2021 +0300 aghstrings: mk cloning correct commit 8009ba60a6a7d6ceb7b6483a29f4e68d533af243 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 12:37:46 2021 +0300 aghstrings: fix lil bug commit 0dd19f2e7cc7c0de21517c37abd8336a907e1c0d Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:45:01 2021 +0300 all: log changes commit eb5558d96fffa6e7bca7e14d3740d26e47382e23 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:18:53 2021 +0300 dnsforward: keep the style commit d6d5fcbde40a633129c0e04887b81cf0b1ce6875 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:02:52 2021 +0300 dnsforward: disable redundant filtering for local ptr commit 4f864c32027d10db9bcb4a264d2338df8c20afac Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 17:53:17 2021 +0300 dnsforward: imp tests commit 7848e6f2341868f8ba0bb839956a0b7444cf02ca Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 14:52:12 2021 +0300 all: imp code commit 19ac30653800eebf8aaee499f65560ae2d458a5a Author: Eugene Burkov <e.burkov@adguard.com> Date: Sun Apr 4 16:28:05 2021 +0300 all: mv more logic to aghstrings commit fac892ec5f0d2e30d6d64def0609267bbae4a202 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:23:23 2021 +0300 dnsforward: use filepath commit 05a3aeef1181b914788d14c7519287d467ab301f Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:17:54 2021 +0300 aghstrings: introduce the pkg commit f24e1b63d6e1bf266a4ed063f46f86d7abf65663 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:01:23 2021 +0300 all: imp code commit 0217a0ebb341f99a90c9b68013bebf6ff73d08ae Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 18:04:13 2021 +0300 openapi: log changes ... and 3 more commits
2021-04-07 18:16:06 +01:00
PrivateUpstreams []string `json:"private_upstream"`
}
// closeBoots closes all the provided bootstrap servers and logs errors if any.
func closeBoots(boots []*upstream.UpstreamResolver) {
for _, c := range boots {
logCloserErr(c, "dnsforward: closing bootstrap %s: %s", c.Address())
}
}
// handleTestUpstreamDNS handles requests to the POST /control/test_upstream_dns
// endpoint.
Pull request: 2704 local addresses vol.3 Merge in DNS/adguard-home from 2704-local-addresses-vol.3 to master Updates #2704. Updates #2829. Updates #2928. Squashed commit of the following: commit 8c42355c0093a3ac6951f79a5211e7891800f93a Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:07:41 2021 +0300 dnsforward: rm errors pkg commit 7594a21a620239951039454dd5686a872e6f41a8 Merge: 830b0834 908452f8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:00:03 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 830b0834090510096061fed20b600195ab3773b8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 17:47:51 2021 +0300 dnsforward: reduce local upstream timeout commit 493e81d9e8bacdc690f88af29a38d211b9733c7e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 19:11:00 2021 +0300 client: private_upstream test commit a0194ac28f15114578359b8c2460cd9af621e912 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:36:23 2021 +0300 all: expand api, fix conflicts commit 0f4e06836fed958391aa597c8b02453564980ca3 Merge: 89cf93ad 8746005d Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:35:04 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 89cf93ad4f26c2bf4f1b18ecaa4d3a1e169f9b06 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 18:02:40 2021 +0300 client: add local ptr upstreams to upstream test commit e6dd869dddd4888474d625cbb005bad6390e4760 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 15:24:22 2021 +0300 client: add private DNS form commit b858057b9a957a416117f22b8bd0025f90e8c758 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 13:05:28 2021 +0300 aghstrings: mk cloning correct commit 8009ba60a6a7d6ceb7b6483a29f4e68d533af243 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 12:37:46 2021 +0300 aghstrings: fix lil bug commit 0dd19f2e7cc7c0de21517c37abd8336a907e1c0d Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:45:01 2021 +0300 all: log changes commit eb5558d96fffa6e7bca7e14d3740d26e47382e23 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:18:53 2021 +0300 dnsforward: keep the style commit d6d5fcbde40a633129c0e04887b81cf0b1ce6875 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:02:52 2021 +0300 dnsforward: disable redundant filtering for local ptr commit 4f864c32027d10db9bcb4a264d2338df8c20afac Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 17:53:17 2021 +0300 dnsforward: imp tests commit 7848e6f2341868f8ba0bb839956a0b7444cf02ca Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 14:52:12 2021 +0300 all: imp code commit 19ac30653800eebf8aaee499f65560ae2d458a5a Author: Eugene Burkov <e.burkov@adguard.com> Date: Sun Apr 4 16:28:05 2021 +0300 all: mv more logic to aghstrings commit fac892ec5f0d2e30d6d64def0609267bbae4a202 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:23:23 2021 +0300 dnsforward: use filepath commit 05a3aeef1181b914788d14c7519287d467ab301f Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:17:54 2021 +0300 aghstrings: introduce the pkg commit f24e1b63d6e1bf266a4ed063f46f86d7abf65663 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:01:23 2021 +0300 all: imp code commit 0217a0ebb341f99a90c9b68013bebf6ff73d08ae Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 18:04:13 2021 +0300 openapi: log changes ... and 3 more commits
2021-04-07 18:16:06 +01:00
func (s *Server) handleTestUpstreamDNS(w http.ResponseWriter, r *http.Request) {
req := &upstreamJSON{}
err := json.NewDecoder(r.Body).Decode(req)
if err != nil {
aghhttp.Error(r, w, http.StatusBadRequest, "Failed to read request body: %s", err)
Pull request: 2704 local addresses vol.3 Merge in DNS/adguard-home from 2704-local-addresses-vol.3 to master Updates #2704. Updates #2829. Updates #2928. Squashed commit of the following: commit 8c42355c0093a3ac6951f79a5211e7891800f93a Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:07:41 2021 +0300 dnsforward: rm errors pkg commit 7594a21a620239951039454dd5686a872e6f41a8 Merge: 830b0834 908452f8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:00:03 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 830b0834090510096061fed20b600195ab3773b8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 17:47:51 2021 +0300 dnsforward: reduce local upstream timeout commit 493e81d9e8bacdc690f88af29a38d211b9733c7e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 19:11:00 2021 +0300 client: private_upstream test commit a0194ac28f15114578359b8c2460cd9af621e912 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:36:23 2021 +0300 all: expand api, fix conflicts commit 0f4e06836fed958391aa597c8b02453564980ca3 Merge: 89cf93ad 8746005d Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:35:04 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 89cf93ad4f26c2bf4f1b18ecaa4d3a1e169f9b06 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 18:02:40 2021 +0300 client: add local ptr upstreams to upstream test commit e6dd869dddd4888474d625cbb005bad6390e4760 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 15:24:22 2021 +0300 client: add private DNS form commit b858057b9a957a416117f22b8bd0025f90e8c758 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 13:05:28 2021 +0300 aghstrings: mk cloning correct commit 8009ba60a6a7d6ceb7b6483a29f4e68d533af243 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 12:37:46 2021 +0300 aghstrings: fix lil bug commit 0dd19f2e7cc7c0de21517c37abd8336a907e1c0d Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:45:01 2021 +0300 all: log changes commit eb5558d96fffa6e7bca7e14d3740d26e47382e23 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:18:53 2021 +0300 dnsforward: keep the style commit d6d5fcbde40a633129c0e04887b81cf0b1ce6875 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:02:52 2021 +0300 dnsforward: disable redundant filtering for local ptr commit 4f864c32027d10db9bcb4a264d2338df8c20afac Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 17:53:17 2021 +0300 dnsforward: imp tests commit 7848e6f2341868f8ba0bb839956a0b7444cf02ca Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 14:52:12 2021 +0300 all: imp code commit 19ac30653800eebf8aaee499f65560ae2d458a5a Author: Eugene Burkov <e.burkov@adguard.com> Date: Sun Apr 4 16:28:05 2021 +0300 all: mv more logic to aghstrings commit fac892ec5f0d2e30d6d64def0609267bbae4a202 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:23:23 2021 +0300 dnsforward: use filepath commit 05a3aeef1181b914788d14c7519287d467ab301f Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:17:54 2021 +0300 aghstrings: introduce the pkg commit f24e1b63d6e1bf266a4ed063f46f86d7abf65663 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:01:23 2021 +0300 all: imp code commit 0217a0ebb341f99a90c9b68013bebf6ff73d08ae Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 18:04:13 2021 +0300 openapi: log changes ... and 3 more commits
2021-04-07 18:16:06 +01:00
return
}
Pull request: 2704 local addresses vol.3 Merge in DNS/adguard-home from 2704-local-addresses-vol.3 to master Updates #2704. Updates #2829. Updates #2928. Squashed commit of the following: commit 8c42355c0093a3ac6951f79a5211e7891800f93a Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:07:41 2021 +0300 dnsforward: rm errors pkg commit 7594a21a620239951039454dd5686a872e6f41a8 Merge: 830b0834 908452f8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:00:03 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 830b0834090510096061fed20b600195ab3773b8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 17:47:51 2021 +0300 dnsforward: reduce local upstream timeout commit 493e81d9e8bacdc690f88af29a38d211b9733c7e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 19:11:00 2021 +0300 client: private_upstream test commit a0194ac28f15114578359b8c2460cd9af621e912 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:36:23 2021 +0300 all: expand api, fix conflicts commit 0f4e06836fed958391aa597c8b02453564980ca3 Merge: 89cf93ad 8746005d Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:35:04 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 89cf93ad4f26c2bf4f1b18ecaa4d3a1e169f9b06 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 18:02:40 2021 +0300 client: add local ptr upstreams to upstream test commit e6dd869dddd4888474d625cbb005bad6390e4760 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 15:24:22 2021 +0300 client: add private DNS form commit b858057b9a957a416117f22b8bd0025f90e8c758 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 13:05:28 2021 +0300 aghstrings: mk cloning correct commit 8009ba60a6a7d6ceb7b6483a29f4e68d533af243 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 12:37:46 2021 +0300 aghstrings: fix lil bug commit 0dd19f2e7cc7c0de21517c37abd8336a907e1c0d Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:45:01 2021 +0300 all: log changes commit eb5558d96fffa6e7bca7e14d3740d26e47382e23 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:18:53 2021 +0300 dnsforward: keep the style commit d6d5fcbde40a633129c0e04887b81cf0b1ce6875 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:02:52 2021 +0300 dnsforward: disable redundant filtering for local ptr commit 4f864c32027d10db9bcb4a264d2338df8c20afac Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 17:53:17 2021 +0300 dnsforward: imp tests commit 7848e6f2341868f8ba0bb839956a0b7444cf02ca Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 14:52:12 2021 +0300 all: imp code commit 19ac30653800eebf8aaee499f65560ae2d458a5a Author: Eugene Burkov <e.burkov@adguard.com> Date: Sun Apr 4 16:28:05 2021 +0300 all: mv more logic to aghstrings commit fac892ec5f0d2e30d6d64def0609267bbae4a202 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:23:23 2021 +0300 dnsforward: use filepath commit 05a3aeef1181b914788d14c7519287d467ab301f Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:17:54 2021 +0300 aghstrings: introduce the pkg commit f24e1b63d6e1bf266a4ed063f46f86d7abf65663 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:01:23 2021 +0300 all: imp code commit 0217a0ebb341f99a90c9b68013bebf6ff73d08ae Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 18:04:13 2021 +0300 openapi: log changes ... and 3 more commits
2021-04-07 18:16:06 +01:00
req.BootstrapDNS = stringutil.FilterOut(req.BootstrapDNS, IsCommentOrEmpty)
Pull request 1891: 5902-bootstrap-hosts Merge in DNS/adguard-home from 5902-bootstrap-hosts to master Updates #5902. Squashed commit of the following: commit fcc65d3a8d7566acc361f54b18d1af85045225e2 Merge: 0c336af07 1fd6cf1a2 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Jun 30 12:29:06 2023 +0300 Merge branch 'master' into 5902-bootstrap-hosts commit 0c336af07d2864533e1f10029b4321d7cd210a47 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Jun 29 15:40:28 2023 +0300 all: imp & simplify commit 45aae90035b98b30199cc7fc92991528f4e968c0 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Jun 28 20:24:43 2023 +0300 all: imp code, docs commit e3dbb5bfe5dfbde7af00f39adcc15e9711e5feb0 Merge: a33a8e93c 2069eddf9 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Jun 28 18:27:36 2023 +0300 Merge branch 'master' into 5902-bootstrap-hosts commit a33a8e93cb36f7d0c4472e524e44de6ff0ab6653 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Jun 28 13:27:11 2023 +0300 aghos: add type check commit 781a3a248871df2ea37a936c8d6b0b11e2d2f3a4 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Jun 28 13:09:37 2023 +0300 all: log changes commit 4575368655356f84992fad2bfb78cbc1c88da25a Merge: 636c440fc cf7c12c97 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Jun 28 13:08:11 2023 +0300 Merge branch 'master' into 5902-bootstrap-hosts commit 636c440fca9cbdfd5c12b7f89432fb9323e01d86 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Jun 28 13:06:32 2023 +0300 all: imp tests commit 0eff7a747e32216d78abf9db9460cb9d48f31f96 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jun 26 18:40:22 2023 +0300 dnsforward: imp code commit 7489a30971e3c76b8f62fd4ca11a977eeabe2cf5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jun 26 17:04:10 2023 +0300 all: resolve upstreams with hosts
2023-06-30 10:41:10 +01:00
opts := &upstream.Options{
Timeout: s.conf.UpstreamTimeout,
PreferIPv6: s.conf.BootstrapPreferIPv6,
}
var boots []*upstream.UpstreamResolver
opts.Bootstrap, boots, err = s.createBootstrap(req.BootstrapDNS, opts)
if err != nil {
aghhttp.Error(r, w, http.StatusBadRequest, "Failed to parse bootstrap servers: %s", err)
return
Pull request 1891: 5902-bootstrap-hosts Merge in DNS/adguard-home from 5902-bootstrap-hosts to master Updates #5902. Squashed commit of the following: commit fcc65d3a8d7566acc361f54b18d1af85045225e2 Merge: 0c336af07 1fd6cf1a2 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Jun 30 12:29:06 2023 +0300 Merge branch 'master' into 5902-bootstrap-hosts commit 0c336af07d2864533e1f10029b4321d7cd210a47 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Jun 29 15:40:28 2023 +0300 all: imp & simplify commit 45aae90035b98b30199cc7fc92991528f4e968c0 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Jun 28 20:24:43 2023 +0300 all: imp code, docs commit e3dbb5bfe5dfbde7af00f39adcc15e9711e5feb0 Merge: a33a8e93c 2069eddf9 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Jun 28 18:27:36 2023 +0300 Merge branch 'master' into 5902-bootstrap-hosts commit a33a8e93cb36f7d0c4472e524e44de6ff0ab6653 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Jun 28 13:27:11 2023 +0300 aghos: add type check commit 781a3a248871df2ea37a936c8d6b0b11e2d2f3a4 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Jun 28 13:09:37 2023 +0300 all: log changes commit 4575368655356f84992fad2bfb78cbc1c88da25a Merge: 636c440fc cf7c12c97 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Jun 28 13:08:11 2023 +0300 Merge branch 'master' into 5902-bootstrap-hosts commit 636c440fca9cbdfd5c12b7f89432fb9323e01d86 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Jun 28 13:06:32 2023 +0300 all: imp tests commit 0eff7a747e32216d78abf9db9460cb9d48f31f96 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jun 26 18:40:22 2023 +0300 dnsforward: imp code commit 7489a30971e3c76b8f62fd4ca11a977eeabe2cf5 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jun 26 17:04:10 2023 +0300 all: resolve upstreams with hosts
2023-06-30 10:41:10 +01:00
}
defer closeBoots(boots)
Pull request: 2704 local addresses vol.3 Merge in DNS/adguard-home from 2704-local-addresses-vol.3 to master Updates #2704. Updates #2829. Updates #2928. Squashed commit of the following: commit 8c42355c0093a3ac6951f79a5211e7891800f93a Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:07:41 2021 +0300 dnsforward: rm errors pkg commit 7594a21a620239951039454dd5686a872e6f41a8 Merge: 830b0834 908452f8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 18:00:03 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 830b0834090510096061fed20b600195ab3773b8 Author: Eugene Burkov <e.burkov@adguard.com> Date: Wed Apr 7 17:47:51 2021 +0300 dnsforward: reduce local upstream timeout commit 493e81d9e8bacdc690f88af29a38d211b9733c7e Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 19:11:00 2021 +0300 client: private_upstream test commit a0194ac28f15114578359b8c2460cd9af621e912 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:36:23 2021 +0300 all: expand api, fix conflicts commit 0f4e06836fed958391aa597c8b02453564980ca3 Merge: 89cf93ad 8746005d Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 18:35:04 2021 +0300 Merge branch 'master' into 2704-local-addresses-vol.3 commit 89cf93ad4f26c2bf4f1b18ecaa4d3a1e169f9b06 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 18:02:40 2021 +0300 client: add local ptr upstreams to upstream test commit e6dd869dddd4888474d625cbb005bad6390e4760 Author: Ildar Kamalov <ik@adguard.com> Date: Tue Apr 6 15:24:22 2021 +0300 client: add private DNS form commit b858057b9a957a416117f22b8bd0025f90e8c758 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 13:05:28 2021 +0300 aghstrings: mk cloning correct commit 8009ba60a6a7d6ceb7b6483a29f4e68d533af243 Author: Eugene Burkov <e.burkov@adguard.com> Date: Tue Apr 6 12:37:46 2021 +0300 aghstrings: fix lil bug commit 0dd19f2e7cc7c0de21517c37abd8336a907e1c0d Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:45:01 2021 +0300 all: log changes commit eb5558d96fffa6e7bca7e14d3740d26e47382e23 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:18:53 2021 +0300 dnsforward: keep the style commit d6d5fcbde40a633129c0e04887b81cf0b1ce6875 Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 20:02:52 2021 +0300 dnsforward: disable redundant filtering for local ptr commit 4f864c32027d10db9bcb4a264d2338df8c20afac Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 17:53:17 2021 +0300 dnsforward: imp tests commit 7848e6f2341868f8ba0bb839956a0b7444cf02ca Author: Eugene Burkov <e.burkov@adguard.com> Date: Mon Apr 5 14:52:12 2021 +0300 all: imp code commit 19ac30653800eebf8aaee499f65560ae2d458a5a Author: Eugene Burkov <e.burkov@adguard.com> Date: Sun Apr 4 16:28:05 2021 +0300 all: mv more logic to aghstrings commit fac892ec5f0d2e30d6d64def0609267bbae4a202 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:23:23 2021 +0300 dnsforward: use filepath commit 05a3aeef1181b914788d14c7519287d467ab301f Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:17:54 2021 +0300 aghstrings: introduce the pkg commit f24e1b63d6e1bf266a4ed063f46f86d7abf65663 Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 20:01:23 2021 +0300 all: imp code commit 0217a0ebb341f99a90c9b68013bebf6ff73d08ae Author: Eugene Burkov <e.burkov@adguard.com> Date: Fri Apr 2 18:04:13 2021 +0300 openapi: log changes ... and 3 more commits
2021-04-07 18:16:06 +01:00
Pull request 2080: AG-27539 imp upstream test Squashed commit of the following: commit 5a9e8c0c2e4b68c0ff6508c47fbd8abde0d05e95 Merge: 85820c173 c4e69cd96 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Nov 28 16:09:53 2023 +0300 Merge branch 'master' into AG-27539-imp-upstream-test commit 85820c173dddb6391dabe9615b821b585b1ecdef Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Nov 28 15:48:53 2023 +0300 dnsforward: split code commit dac0148a4d4780bea19fb7622b46ac08fbf1ee74 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Nov 24 15:47:05 2023 +0300 dnsforward: fix docs commit 9f0015b255d547f31d34513aa6bb2faf65a39e0e Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Nov 24 14:45:43 2023 +0300 dnsforward: imp code commit 49fefc373972b7c8991abcb46d7730288b92c24c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Nov 23 14:12:02 2023 +0300 dnsforward: imp code commit 120ba4b1f727bba537471c4a8aa4b412eac30f85 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Nov 22 17:02:01 2023 +0300 dnsforward: add tests commit 70775975ced46191a6ba64504c7bac0e3d1eed7f Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Nov 22 15:48:05 2023 +0300 dnsforward: imp code commit 9487f1fd62b821efb242267d9972f3ae3785ad19 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Nov 21 18:06:00 2023 +0300 dnsforward: imp code commit e2612e0e6fd1c9116872939edd0e86f2e9af07d7 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Nov 21 16:12:20 2023 +0300 dnsforward: add ups checker commit 09db7d2a604809669affbeef2f0536fa6605a39b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Nov 14 17:31:04 2023 +0300 dnsforward: separate upstream code
2023-11-28 13:40:52 +00:00
cv := newUpstreamConfigValidator(req.Upstreams, req.FallbackDNS, req.PrivateUpstreams, opts)
cv.check()
cv.close()
Pull request 2080: AG-27539 imp upstream test Squashed commit of the following: commit 5a9e8c0c2e4b68c0ff6508c47fbd8abde0d05e95 Merge: 85820c173 c4e69cd96 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Nov 28 16:09:53 2023 +0300 Merge branch 'master' into AG-27539-imp-upstream-test commit 85820c173dddb6391dabe9615b821b585b1ecdef Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Nov 28 15:48:53 2023 +0300 dnsforward: split code commit dac0148a4d4780bea19fb7622b46ac08fbf1ee74 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Nov 24 15:47:05 2023 +0300 dnsforward: fix docs commit 9f0015b255d547f31d34513aa6bb2faf65a39e0e Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Nov 24 14:45:43 2023 +0300 dnsforward: imp code commit 49fefc373972b7c8991abcb46d7730288b92c24c Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Thu Nov 23 14:12:02 2023 +0300 dnsforward: imp code commit 120ba4b1f727bba537471c4a8aa4b412eac30f85 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Nov 22 17:02:01 2023 +0300 dnsforward: add tests commit 70775975ced46191a6ba64504c7bac0e3d1eed7f Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Nov 22 15:48:05 2023 +0300 dnsforward: imp code commit 9487f1fd62b821efb242267d9972f3ae3785ad19 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Nov 21 18:06:00 2023 +0300 dnsforward: imp code commit e2612e0e6fd1c9116872939edd0e86f2e9af07d7 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Nov 21 16:12:20 2023 +0300 dnsforward: add ups checker commit 09db7d2a604809669affbeef2f0536fa6605a39b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Nov 14 17:31:04 2023 +0300 dnsforward: separate upstream code
2023-11-28 13:40:52 +00:00
aghhttp.WriteJSONResponseOK(w, r, cv.status())
}
// handleCacheClear is the handler for the POST /control/cache_clear HTTP API.
func (s *Server) handleCacheClear(w http.ResponseWriter, _ *http.Request) {
s.dnsProxy.ClearCache()
_, _ = io.WriteString(w, "OK")
}
Pull request: 1333-protection-pause vol.1 Merge in DNS/adguard-home from 1333-protection-pause-1 to master Squashed commit of the following: commit 5ff98385bc5ff66e214d80782eb4dc41e344aa38 Merge: 97f94a54 0bc3ef89 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 24 19:08:21 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 commit 97f94a5498ac221f88f2f7dfef4b255f4945329e Author: Arseny Lisin <a.lisin@adguard.com> Date: Fri Mar 24 13:03:20 2023 +0200 Fix protection timer bugs commit 1cc61af1996bd803f3fa638cb9e2388470072bf0 Merge: 5a144ea3 235ce458 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 22:27:47 2023 +0700 Merge remote-tracking branch 'origin/1333-protection-pause-1' into 1333-protection-pause-1 commit 5a144ea3a48c3d0d5e57dd14232ab7a8e77a8c1e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 22:25:08 2023 +0700 dnsforward: imp code commit 235ce458a62b3152f36e32580ed0226a56580ec6 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Mar 23 17:35:06 2023 +0300 dnsforward: imp locks commit 0ea3a0a176b810a2b3f0b307aa406fe1670c9219 Merge: 52f66810 df61741f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 19:30:41 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # openapi/CHANGELOG.md commit 52f668109673286a50909c042e6352cd803e8eed Merge: 9a7eb7b3 306c1983 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 11:23:50 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # internal/dnsforward/http.go commit 9a7eb7b3ab2b5f6ad321aa3245d33839c3aa6fbd Author: Arseny Lisin <a.lisin@adguard.com> Date: Wed Mar 22 06:56:55 2023 +0200 Review fix commit 5612d51252ba91842bd6811baec1c91136bb3bf2 Merge: c0a918a5 c3edab43 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 21 22:00:39 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # client/src/__locales/en.json commit c0a918a518ad9b37041aed159d215516258bc987 Author: Arseny Lisin <a.lisin@adguard.com> Date: Tue Mar 21 12:13:18 2023 +0200 Review fix commit 34faa61cc1e6210a612e7a2f4895a1504df37680 Author: Arseny Lisin <a.lisin@adguard.com> Date: Tue Mar 21 10:43:37 2023 +0200 Fix props to new api commit 158e582373863495f0e0ca177d7b365cc66ad671 Author: Arseny Lisin <a.lisin@adguard.com> Date: Mon Mar 20 18:44:34 2023 +0200 Review fix commit 9e8b8c3778b8e1dfad0d39e44f70886dfd3aeb9a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 20 22:31:28 2023 +0700 all: docs commit 761a203f53b535ca235cfe62f289bd0e02b90be2 Merge: d0b07231 48431f8b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 20 22:26:13 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 commit d0b07231b6f29b534930f1fcfc82b4934c295ff8 Merge: ea448760 a2053526 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 13:00:52 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # client/src/components/App/index.css # internal/dnsforward/config.go commit ea4487608a9c81d25f155ff63fee7c9dcf21f448 Merge: dfd0f33f a556ce8f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 21 11:54:27 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md commit dfd0f33fb474d497cbc9237ee466276728eea397 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 21 11:51:40 2023 +0700 all: docs commit d36df96fba8c6d923faef85c198b6bd0743b7ee8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Feb 20 12:41:49 2023 +0700 all: safesearch commit 60f2ceec563221337f34bb60baa96aa2b2429c40 Merge: 7c514427 6f6ced33 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Feb 20 12:30:42 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md commit 7c514427e77c5b09d8e148c78220a71046e68cd1 Merge: 0fa4ff99 4d295a38 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Feb 16 11:55:21 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md ... and 26 more commits
2023-03-24 12:11:47 +00:00
// protectionJSON is an object for /control/protection endpoint.
type protectionJSON struct {
Enabled bool `json:"enabled"`
Duration uint `json:"duration"`
}
// handleSetProtection is a handler for the POST /control/protection HTTP API.
func (s *Server) handleSetProtection(w http.ResponseWriter, r *http.Request) {
protectionReq := &protectionJSON{}
err := json.NewDecoder(r.Body).Decode(protectionReq)
if err != nil {
aghhttp.Error(r, w, http.StatusBadRequest, "reading req: %s", err)
return
}
var disabledUntil *time.Time
if protectionReq.Duration > 0 {
if protectionReq.Enabled {
aghhttp.Error(
r,
w,
http.StatusBadRequest,
"Setting a duration is only allowed with protection disabling",
)
return
}
calcTime := time.Now().Add(time.Duration(protectionReq.Duration) * time.Millisecond)
disabledUntil = &calcTime
}
func() {
s.serverLock.Lock()
defer s.serverLock.Unlock()
s.dnsFilter.SetProtectionStatus(protectionReq.Enabled, disabledUntil)
Pull request: 1333-protection-pause vol.1 Merge in DNS/adguard-home from 1333-protection-pause-1 to master Squashed commit of the following: commit 5ff98385bc5ff66e214d80782eb4dc41e344aa38 Merge: 97f94a54 0bc3ef89 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 24 19:08:21 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 commit 97f94a5498ac221f88f2f7dfef4b255f4945329e Author: Arseny Lisin <a.lisin@adguard.com> Date: Fri Mar 24 13:03:20 2023 +0200 Fix protection timer bugs commit 1cc61af1996bd803f3fa638cb9e2388470072bf0 Merge: 5a144ea3 235ce458 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 22:27:47 2023 +0700 Merge remote-tracking branch 'origin/1333-protection-pause-1' into 1333-protection-pause-1 commit 5a144ea3a48c3d0d5e57dd14232ab7a8e77a8c1e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 22:25:08 2023 +0700 dnsforward: imp code commit 235ce458a62b3152f36e32580ed0226a56580ec6 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Mar 23 17:35:06 2023 +0300 dnsforward: imp locks commit 0ea3a0a176b810a2b3f0b307aa406fe1670c9219 Merge: 52f66810 df61741f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 19:30:41 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # openapi/CHANGELOG.md commit 52f668109673286a50909c042e6352cd803e8eed Merge: 9a7eb7b3 306c1983 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 11:23:50 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # internal/dnsforward/http.go commit 9a7eb7b3ab2b5f6ad321aa3245d33839c3aa6fbd Author: Arseny Lisin <a.lisin@adguard.com> Date: Wed Mar 22 06:56:55 2023 +0200 Review fix commit 5612d51252ba91842bd6811baec1c91136bb3bf2 Merge: c0a918a5 c3edab43 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 21 22:00:39 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # client/src/__locales/en.json commit c0a918a518ad9b37041aed159d215516258bc987 Author: Arseny Lisin <a.lisin@adguard.com> Date: Tue Mar 21 12:13:18 2023 +0200 Review fix commit 34faa61cc1e6210a612e7a2f4895a1504df37680 Author: Arseny Lisin <a.lisin@adguard.com> Date: Tue Mar 21 10:43:37 2023 +0200 Fix props to new api commit 158e582373863495f0e0ca177d7b365cc66ad671 Author: Arseny Lisin <a.lisin@adguard.com> Date: Mon Mar 20 18:44:34 2023 +0200 Review fix commit 9e8b8c3778b8e1dfad0d39e44f70886dfd3aeb9a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 20 22:31:28 2023 +0700 all: docs commit 761a203f53b535ca235cfe62f289bd0e02b90be2 Merge: d0b07231 48431f8b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 20 22:26:13 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 commit d0b07231b6f29b534930f1fcfc82b4934c295ff8 Merge: ea448760 a2053526 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 13:00:52 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # client/src/components/App/index.css # internal/dnsforward/config.go commit ea4487608a9c81d25f155ff63fee7c9dcf21f448 Merge: dfd0f33f a556ce8f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 21 11:54:27 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md commit dfd0f33fb474d497cbc9237ee466276728eea397 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 21 11:51:40 2023 +0700 all: docs commit d36df96fba8c6d923faef85c198b6bd0743b7ee8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Feb 20 12:41:49 2023 +0700 all: safesearch commit 60f2ceec563221337f34bb60baa96aa2b2429c40 Merge: 7c514427 6f6ced33 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Feb 20 12:30:42 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md commit 7c514427e77c5b09d8e148c78220a71046e68cd1 Merge: 0fa4ff99 4d295a38 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Feb 16 11:55:21 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md ... and 26 more commits
2023-03-24 12:11:47 +00:00
}()
s.conf.ConfigModified()
aghhttp.OK(w)
}
2022-08-29 13:54:41 +01:00
// handleDoH is the DNS-over-HTTPs handler.
//
2020-05-29 09:15:31 +01:00
// Control flow:
2022-08-29 13:54:41 +01:00
//
// HTTP server
// -> dnsforward.handleDoH
// -> dnsforward.ServeHTTP
// -> proxy.ServeHTTP
// -> proxy.handleDNSRequest
// -> dnsforward.handleDNSRequest
func (s *Server) handleDoH(w http.ResponseWriter, r *http.Request) {
if !s.conf.TLSAllowUnencryptedDoH && r.TLS == nil {
aghhttp.Error(r, w, http.StatusNotFound, "Not Found")
return
}
if !s.IsRunning() {
aghhttp.Error(r, w, http.StatusInternalServerError, "dns server is not running")
return
}
s.ServeHTTP(w, r)
}
func (s *Server) registerHandlers() {
Pull request: 5117-dns64 Merge in DNS/adguard-home from 5117-dns64 to master Updates #5117. Squashed commit of the following: commit 757d689134b85bdac9a6f5e43249866ec09ab7e3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 23 19:06:18 2023 +0300 all: imp fmt commit b7a73c68c0b40bd3bda520c045c8110975c1827a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 23 17:49:21 2023 +0300 all: rm unused, imp code commit 548feb6bd27b9774a9453d0570d37cdf557d4c3a Merge: de3e84b5 54a141ab Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 23 14:08:12 2023 +0300 Merge branch 'master' into 5117-dns64 commit de3e84b52b8dbff70df3ca0ac3315c3d33576334 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 23 12:04:48 2023 +0300 dnsforward: imp code commit a580e92119e3dbadc8b1a6572dbecc679f69db40 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Jan 20 18:24:33 2023 +0400 dnsforward: try again commit 67b7a365194939fe15e4907a3dc2fee44b019d08 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Jan 20 18:08:23 2023 +0400 dnsforward: fix test on linux commit ca83e4178a3383e326bf528d209d8766fb3c60d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Jan 20 17:37:48 2023 +0400 dnsforward: imp naming commit c4e477c7a12af4966cbcd4e5f003a72966dc5d61 Merge: 42aa42a8 6e803375 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Jan 20 17:30:03 2023 +0400 Merge branch 'master' into 5117-dns64 commit 42aa42a8149b6bb42eb0da6e88ede4b5065bbf2f Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Jan 20 17:26:54 2023 +0400 dnsforward: imp test commit 4e91c675703f1453456ef9eea08157009ce6237a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Jan 18 12:32:55 2023 +0400 dnsforward: imp code, docs, add test commit 766ef757f61e7a555b8151b4783fa7aba5f566f7 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Jan 17 16:36:35 2023 +0400 dnsforward: imp docs commit 6825f372389988597d1879cf66342c410f3cfd47 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Jan 17 14:33:33 2023 +0400 internal: imp code, docs commit 1215316a338496b5bea2b20d697c7451bfbcc84b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Jan 13 21:24:50 2023 +0400 all: add dns64 support
2023-01-23 16:10:56 +00:00
if webRegistered || s.conf.HTTPRegister == nil {
return
}
s.conf.HTTPRegister(http.MethodGet, "/control/dns_info", s.handleGetConfig)
s.conf.HTTPRegister(http.MethodPost, "/control/dns_config", s.handleSetConfig)
s.conf.HTTPRegister(http.MethodPost, "/control/test_upstream_dns", s.handleTestUpstreamDNS)
Pull request: 1333-protection-pause vol.1 Merge in DNS/adguard-home from 1333-protection-pause-1 to master Squashed commit of the following: commit 5ff98385bc5ff66e214d80782eb4dc41e344aa38 Merge: 97f94a54 0bc3ef89 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 24 19:08:21 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 commit 97f94a5498ac221f88f2f7dfef4b255f4945329e Author: Arseny Lisin <a.lisin@adguard.com> Date: Fri Mar 24 13:03:20 2023 +0200 Fix protection timer bugs commit 1cc61af1996bd803f3fa638cb9e2388470072bf0 Merge: 5a144ea3 235ce458 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 22:27:47 2023 +0700 Merge remote-tracking branch 'origin/1333-protection-pause-1' into 1333-protection-pause-1 commit 5a144ea3a48c3d0d5e57dd14232ab7a8e77a8c1e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 22:25:08 2023 +0700 dnsforward: imp code commit 235ce458a62b3152f36e32580ed0226a56580ec6 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Thu Mar 23 17:35:06 2023 +0300 dnsforward: imp locks commit 0ea3a0a176b810a2b3f0b307aa406fe1670c9219 Merge: 52f66810 df61741f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 19:30:41 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # openapi/CHANGELOG.md commit 52f668109673286a50909c042e6352cd803e8eed Merge: 9a7eb7b3 306c1983 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 23 11:23:50 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # internal/dnsforward/http.go commit 9a7eb7b3ab2b5f6ad321aa3245d33839c3aa6fbd Author: Arseny Lisin <a.lisin@adguard.com> Date: Wed Mar 22 06:56:55 2023 +0200 Review fix commit 5612d51252ba91842bd6811baec1c91136bb3bf2 Merge: c0a918a5 c3edab43 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 21 22:00:39 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # client/src/__locales/en.json commit c0a918a518ad9b37041aed159d215516258bc987 Author: Arseny Lisin <a.lisin@adguard.com> Date: Tue Mar 21 12:13:18 2023 +0200 Review fix commit 34faa61cc1e6210a612e7a2f4895a1504df37680 Author: Arseny Lisin <a.lisin@adguard.com> Date: Tue Mar 21 10:43:37 2023 +0200 Fix props to new api commit 158e582373863495f0e0ca177d7b365cc66ad671 Author: Arseny Lisin <a.lisin@adguard.com> Date: Mon Mar 20 18:44:34 2023 +0200 Review fix commit 9e8b8c3778b8e1dfad0d39e44f70886dfd3aeb9a Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 20 22:31:28 2023 +0700 all: docs commit 761a203f53b535ca235cfe62f289bd0e02b90be2 Merge: d0b07231 48431f8b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 20 22:26:13 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 commit d0b07231b6f29b534930f1fcfc82b4934c295ff8 Merge: ea448760 a2053526 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 13:00:52 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md # client/src/components/App/index.css # internal/dnsforward/config.go commit ea4487608a9c81d25f155ff63fee7c9dcf21f448 Merge: dfd0f33f a556ce8f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 21 11:54:27 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md commit dfd0f33fb474d497cbc9237ee466276728eea397 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 21 11:51:40 2023 +0700 all: docs commit d36df96fba8c6d923faef85c198b6bd0743b7ee8 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Feb 20 12:41:49 2023 +0700 all: safesearch commit 60f2ceec563221337f34bb60baa96aa2b2429c40 Merge: 7c514427 6f6ced33 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Feb 20 12:30:42 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md commit 7c514427e77c5b09d8e148c78220a71046e68cd1 Merge: 0fa4ff99 4d295a38 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Feb 16 11:55:21 2023 +0700 Merge remote-tracking branch 'origin/master' into 1333-protection-pause-1 # Conflicts: # CHANGELOG.md ... and 26 more commits
2023-03-24 12:11:47 +00:00
s.conf.HTTPRegister(http.MethodPost, "/control/protection", s.handleSetProtection)
s.conf.HTTPRegister(http.MethodGet, "/control/access/list", s.handleAccessList)
s.conf.HTTPRegister(http.MethodPost, "/control/access/set", s.handleAccessSet)
s.conf.HTTPRegister(http.MethodPost, "/control/cache_clear", s.handleCacheClear)
// Register both versions, with and without the trailing slash, to
// prevent a 301 Moved Permanently redirect when clients request the
// path without the trailing slash. Those redirects break some clients.
//
// See go doc net/http.ServeMux.
//
// See also https://github.com/AdguardTeam/AdGuardHome/issues/2628.
s.conf.HTTPRegister("", "/dns-query", s.handleDoH)
s.conf.HTTPRegister("", "/dns-query/", s.handleDoH)
Pull request: 5117-dns64 Merge in DNS/adguard-home from 5117-dns64 to master Updates #5117. Squashed commit of the following: commit 757d689134b85bdac9a6f5e43249866ec09ab7e3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 23 19:06:18 2023 +0300 all: imp fmt commit b7a73c68c0b40bd3bda520c045c8110975c1827a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 23 17:49:21 2023 +0300 all: rm unused, imp code commit 548feb6bd27b9774a9453d0570d37cdf557d4c3a Merge: de3e84b5 54a141ab Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 23 14:08:12 2023 +0300 Merge branch 'master' into 5117-dns64 commit de3e84b52b8dbff70df3ca0ac3315c3d33576334 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Mon Jan 23 12:04:48 2023 +0300 dnsforward: imp code commit a580e92119e3dbadc8b1a6572dbecc679f69db40 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Jan 20 18:24:33 2023 +0400 dnsforward: try again commit 67b7a365194939fe15e4907a3dc2fee44b019d08 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Jan 20 18:08:23 2023 +0400 dnsforward: fix test on linux commit ca83e4178a3383e326bf528d209d8766fb3c60d3 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Jan 20 17:37:48 2023 +0400 dnsforward: imp naming commit c4e477c7a12af4966cbcd4e5f003a72966dc5d61 Merge: 42aa42a8 6e803375 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Jan 20 17:30:03 2023 +0400 Merge branch 'master' into 5117-dns64 commit 42aa42a8149b6bb42eb0da6e88ede4b5065bbf2f Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Jan 20 17:26:54 2023 +0400 dnsforward: imp test commit 4e91c675703f1453456ef9eea08157009ce6237a Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Wed Jan 18 12:32:55 2023 +0400 dnsforward: imp code, docs, add test commit 766ef757f61e7a555b8151b4783fa7aba5f566f7 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Jan 17 16:36:35 2023 +0400 dnsforward: imp docs commit 6825f372389988597d1879cf66342c410f3cfd47 Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Tue Jan 17 14:33:33 2023 +0400 internal: imp code, docs commit 1215316a338496b5bea2b20d697c7451bfbcc84b Author: Eugene Burkov <E.Burkov@AdGuard.COM> Date: Fri Jan 13 21:24:50 2023 +0400 all: add dns64 support
2023-01-23 16:10:56 +00:00
webRegistered = true
}