Commit Graph

1255 Commits

Author SHA1 Message Date
Simon Zolin f23507a554 * dnsfilter: parental/safebrowsing: add setting to switch between HTTP and HTTPS 2019-05-27 18:11:05 +03:00
Simon Zolin b9df476c5d Merge: dnsforward: support IPv6
Close #735

* commit 'e2579c72bdcafed41d5be1250fb38aeda0a8184e':
  * dnsfilter: fix tests
  + dnsforward: support IPv6 (AAAA response)
  * dnsfilter: return the correct IP address (host rules)
2019-05-27 12:35:31 +03:00
Simon Zolin e2579c72bd * dnsfilter: fix tests 2019-05-24 18:08:08 +03:00
Simon Zolin ac8f703407 + dnsforward: support IPv6 (AAAA response)
If question type is AAAA:
 Before this patch we responded with NXDOMAIN.
 Now we send an empty response if host rule is IPv4;
 or we send an AAAA answer if host rule is IPv6.

+ block ipv6 if rule is "0.0.0.0 blockdomain"
2019-05-24 18:08:08 +03:00
Simon Zolin 9ad4bba9ab * dnsfilter: return the correct IP address (host rules) 2019-05-24 18:08:08 +03:00
Simon Zolin 452c930dd0 Merge: * dnsfilter: use 'https' for safe-browsing and parental control
Close #646

* commit '00e1b6ca089705e7fdb4764133058e04111e36df':
  * dnsfilter: use 'https' for safe-browsing and parental control
2019-05-24 18:03:00 +03:00
Simon Zolin fdd0f594fb Merge: - control: allow requests to "/favicon.ico" while we are in install mode
Close #766

* commit 'dece393d6acfa21f588505e494eb1225adc8376a':
  - control: allow requests to "/favicon.ico" while we are in install mode
2019-05-24 18:02:07 +03:00
Simon Zolin 00e1b6ca08 * dnsfilter: use 'https' for safe-browsing and parental control 2019-05-23 17:26:50 +03:00
Simon Zolin dece393d6a - control: allow requests to "/favicon.ico" while we are in install mode 2019-05-23 16:28:20 +03:00
Simon Zolin aa2d942783 Merge: Update by command from UI
Close #428

* commit '70e329956776cc381fdb28805375d5b2f0e22dbf':
  * openapi: update
  * client: add link to the update error
  * client: add update timeout
  * client: add error message if update failed
  + client: handle update
  * go linter
  * control: /version.json: use new JSON format
  + set config.runningAsService
  * app: --help: more pretty help info
  + app: add --check-config command-line argument
  * app: optimize config file reading
  + /control/update handler
  * control: don't use custom resolver for tests
  + doc: Update algorithm
  - control: fix race in /control/version.json handler
2019-05-20 13:38:23 +03:00
Simon Zolin e3ee7a0c3e Merge: dnsfilter: use urlfilter package #714
* commit '096a95998749b673bc9be638bc9c8f6f0d13be41':
  * dnsforward: use new dnsfilter interface
  * dnsfilter: adapt tests to new interface
  * dnsfilter: use urlfilter package
  * dnsfilter: remove code for filtering rules
  * dns: rename dnsfilter.Filter.Rule -> dnsfilter.Filter.Data
  * dnsforward: use separate ServerConfig object
  * use urlfilter
2019-05-20 11:00:45 +03:00
Simon Zolin 70e3299567 * openapi: update 2019-05-20 10:57:07 +03:00
Ildar Kamalov 967517316f * client: add link to the update error 2019-05-17 18:33:34 +03:00
Ildar Kamalov 24f582d36d * client: add update timeout 2019-05-17 18:33:34 +03:00
Ildar Kamalov 9cffe865ec * client: add error message if update failed 2019-05-17 18:33:34 +03:00
Ildar Kamalov cb3f7f2834 + client: handle update 2019-05-17 18:33:34 +03:00
Simon Zolin 096a959987 * dnsforward: use new dnsfilter interface 2019-05-17 18:22:57 +03:00
Simon Zolin 5ec747b30b * dnsfilter: adapt tests to new interface 2019-05-17 18:22:57 +03:00
Simon Zolin 829415da5b * dnsfilter: use urlfilter package
+ new config setting 'filtering_temp_filename'

* remove AddRules(), modify New()
2019-05-17 18:22:57 +03:00
Simon Zolin 3396d68019 * dnsfilter: remove code for filtering rules 2019-05-17 18:22:57 +03:00
Simon Zolin bd68bf2e25 * dns: rename dnsfilter.Filter.Rule -> dnsfilter.Filter.Data 2019-05-17 18:22:57 +03:00
Simon Zolin 9644f79a03 * dnsforward: use separate ServerConfig object 2019-05-17 18:22:57 +03:00
Simon Zolin 36e273dfd5 * use urlfilter 2019-05-17 18:22:57 +03:00
Simon Zolin 068072bc5a * go linter 2019-05-17 15:39:56 +03:00
Simon Zolin b72ca4d127 * control: /version.json: use new JSON format 2019-05-17 15:37:38 +03:00
Simon Zolin 28440fc3ac + set config.runningAsService 2019-05-17 15:37:38 +03:00
Simon Zolin 6d14ec18ac * app: --help: more pretty help info 2019-05-17 15:37:38 +03:00
Simon Zolin 5fd35254a8 + app: add --check-config command-line argument 2019-05-17 15:37:38 +03:00
Simon Zolin 3ee8051e97 * app: optimize config file reading
* read config file just once (even when upgrading)
* don't call os.Stat()
2019-05-17 15:37:38 +03:00
Simon Zolin 2dd6ea5161 + /control/update handler 2019-05-17 15:37:38 +03:00
Simon Zolin 788e91a51e * control: don't use custom resolver for tests 2019-05-17 15:34:55 +03:00
Simon Zolin d4fcef8d04 + doc: Update algorithm 2019-05-17 15:34:55 +03:00
Simon Zolin 392c7b6ee1 - control: fix race in /control/version.json handler 2019-05-17 10:20:41 +03:00
Simon Zolin 7bb40bca0f Merge: dns query log: robust file flushing mechanism #708
* commit 'd5f6dd1a46446ebb440811691a6ee8ce2443320d':
  - dns query log: robust file flushing mechanism
  * improve logging
2019-05-15 14:08:01 +03:00
Simon Zolin f20cb65189 Merge: + dnsfilter: cache IP addresses of safebrowsing and parental control servers
Close #745

* commit 'd918e5b418de232d95ba1e3d642dca00664f0304':
  use maxDialCacheSize constant
  rename functions and container
  + dnsfilter: cache IP addresses of safebrowsing and parental control servers
2019-05-15 14:01:01 +03:00
Simon Zolin d5f6dd1a46 - dns query log: robust file flushing mechanism
Before this patch we could exit the process without waiting for
 file writing task to complete.
As a result a file could become corrupted or a large chunk of data
 could be missing.

Now the main thread either waits until file writing task completes
 or it writes log buffer to file itself.
2019-05-15 13:12:03 +03:00
Simon Zolin 0f28a989e9 * improve logging 2019-05-15 13:12:03 +03:00
Simon Zolin d918e5b418 use maxDialCacheSize constant 2019-05-15 12:03:20 +03:00
Simon Zolin 3a0f608402 Merge: dnsforward, config: add unspecified IP blocking option
Close #742, #743

* commit 'cd2dd00da300c24a88a51082ee9622a332a5b72b':
  * dnsforward_test: add test for null filter
  * dnsforward, config: add unspecified IP blocking option
2019-05-15 11:58:40 +03:00
Alexander Turcic cd2dd00da3 * dnsforward_test: add test for null filter 2019-05-14 16:53:09 +03:00
Alexander Turcic 07ffcbec3d * dnsforward, config: add unspecified IP blocking option
* dnsforward: prioritize host files over null filter

* dnsforward, config: adjust setting variable to blocking_mode

* dnsforward: use net.IPv4zero for null IP
2019-05-14 16:53:06 +03:00
Simon Zolin b3461d37ca rename functions and container 2019-05-13 14:47:55 +03:00
Simon Zolin 2178546e7b Merge: docker: Run as non-root user
Close #720

* commit '68f9ec70fb0f8ff2a73bf382bc15257c367b7967':
  Optimize Docker image layers; comment out runtime user; add sample docker-compose.yml
  Run as non-root user
2019-05-13 14:42:50 +03:00
Simon Zolin 24ae61de3e + dnsfilter: cache IP addresses of safebrowsing and parental control servers 2019-05-13 14:16:07 +03:00
Simon Zolin 68f9ec70fb Merge branch 'docker-improvements' of git://github.com/javabean/AdGuardHome into javabean-docker-improvements 2019-05-13 11:12:21 +03:00
Cédrik LIME 17aa46c4d2 Optimize Docker image layers; comment out runtime user; add sample docker-compose.yml 2019-05-08 21:17:14 +02:00
Ildar Kamalov a45f0c519e Merge pull request #209 in DNS/adguard-dns from feature/734 to master
* commit '6ac9509d64e82e48bc22ccd23ac3a25776d05565':
  + client: Add a link to the list of known DNS providers to Upstream DNS settings
2019-05-06 09:35:51 +03:00
Ildar Kamalov 2cb2b3585f Merge pull request #208 in DNS/adguard-dns from fix/729 to master
* commit 'd24f208f98c08155282eb3061fd28e2e149e296b':
  - client: fixed values for settings validation
2019-05-06 09:35:42 +03:00
Ildar Kamalov d24f208f98 - client: fixed values for settings validation
Closes #729
2019-04-28 11:43:15 +03:00
Ildar Kamalov 6ac9509d64 + client: Add a link to the list of known DNS providers to Upstream DNS settings
Closes #734
2019-04-28 11:18:56 +03:00