AdGuardHome/internal/filtering/safesearch.go

55 lines
1.8 KiB
Go
Raw Normal View History

package filtering
2018-08-30 17:25:33 +03:00
import "context"
Pull request 1163 safesearch package vol.1 Merge in DNS/adguard-home from 1163-safesearch-1-1 to master Squashed commit of the following: commit ccc8393304441b0edbcd15598d29764fb5d5fc34 Merge: 7d3901b5 6b265c64 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 7 21:36:24 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-1 commit 7d3901b5753f6456192f3533c257de7ae3bef6ac Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Sat Mar 4 10:15:18 2023 +0700 all: safesearch imp code commit 94a50dc61d955f659cda123825389225d0ebfc3e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 3 13:22:41 2023 +0700 safesearch: imp code commit aa6e30fed8f67ffbc336f619f299fbd789c86ada Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 21:43:28 2023 +0700 safesearch: imp code commit 30e75b6fa85edfdf66b7ace68cad4cbc61b28ea6 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 21:38:14 2023 +0700 safesearch: imp code commit 7d95ec73392b20519eab0e869ccba0c30404ae6f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 21:24:49 2023 +0700 safesearch: imp code commit d6c0a0fbf9ad836606fbbfe31702e84773a2709d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 21:04:53 2023 +0700 safesearch: imp code commit fa179b767bf75ed931cd62f282220d1f7025c641 Merge: 7a43ca00 012e5beb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 20:52:01 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-1 commit 7a43ca001ccab4d53b059c0e7843f2fc5b7dcefc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 11:59:35 2023 +0700 safesearch: embed rules commit 2b1a83d6ffacc89a3e81a8327653018ed803f15b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 11:50:29 2023 +0700 safesearch: imp code commit 400d463d32490cde7b4f55f3bb5a68e022e1c762 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 11:30:57 2023 +0700 safesearch: imp code commit 60cce36bdef0cf0def28c760a3d767314a03f176 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 11:16:56 2023 +0700 all: imp code commit 4eee3237b736fd16870835458757da550bcef295 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 28 23:26:17 2023 +0700 all: safesearch package
2023-03-07 17:52:03 +03:00
// SafeSearch interface describes a service for search engines hosts rewrites.
type SafeSearch interface {
// CheckHost checks host with safe search filter. CheckHost must be safe
// for concurrent use. qtype must be either [dns.TypeA] or [dns.TypeAAAA].
CheckHost(ctx context.Context, host string, qtype uint16) (res Result, err error)
// Update updates the configuration of the safe search filter. Update must
// be safe for concurrent use. An implementation of Update may ignore some
// fields, but it must document which.
Update(ctx context.Context, conf SafeSearchConfig) (err error)
Pull request 1163 safesearch package vol.1 Merge in DNS/adguard-home from 1163-safesearch-1-1 to master Squashed commit of the following: commit ccc8393304441b0edbcd15598d29764fb5d5fc34 Merge: 7d3901b5 6b265c64 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 7 21:36:24 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-1 commit 7d3901b5753f6456192f3533c257de7ae3bef6ac Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Sat Mar 4 10:15:18 2023 +0700 all: safesearch imp code commit 94a50dc61d955f659cda123825389225d0ebfc3e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 3 13:22:41 2023 +0700 safesearch: imp code commit aa6e30fed8f67ffbc336f619f299fbd789c86ada Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 21:43:28 2023 +0700 safesearch: imp code commit 30e75b6fa85edfdf66b7ace68cad4cbc61b28ea6 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 21:38:14 2023 +0700 safesearch: imp code commit 7d95ec73392b20519eab0e869ccba0c30404ae6f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 21:24:49 2023 +0700 safesearch: imp code commit d6c0a0fbf9ad836606fbbfe31702e84773a2709d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 21:04:53 2023 +0700 safesearch: imp code commit fa179b767bf75ed931cd62f282220d1f7025c641 Merge: 7a43ca00 012e5beb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 20:52:01 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-1 commit 7a43ca001ccab4d53b059c0e7843f2fc5b7dcefc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 11:59:35 2023 +0700 safesearch: embed rules commit 2b1a83d6ffacc89a3e81a8327653018ed803f15b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 11:50:29 2023 +0700 safesearch: imp code commit 400d463d32490cde7b4f55f3bb5a68e022e1c762 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 11:30:57 2023 +0700 safesearch: imp code commit 60cce36bdef0cf0def28c760a3d767314a03f176 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 11:16:56 2023 +0700 all: imp code commit 4eee3237b736fd16870835458757da550bcef295 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 28 23:26:17 2023 +0700 all: safesearch package
2023-03-07 17:52:03 +03:00
}
// SafeSearchConfig is a struct with safe search related settings.
type SafeSearchConfig struct {
// Enabled indicates if safe search is enabled entirely.
Enabled bool `yaml:"enabled" json:"enabled"`
// Services flags. Each flag indicates if the corresponding service is
// enabled or disabled.
Bing bool `yaml:"bing" json:"bing"`
DuckDuckGo bool `yaml:"duckduckgo" json:"duckduckgo"`
Ecosia bool `yaml:"ecosia" json:"ecosia"`
Pull request 1163 safesearch package vol.1 Merge in DNS/adguard-home from 1163-safesearch-1-1 to master Squashed commit of the following: commit ccc8393304441b0edbcd15598d29764fb5d5fc34 Merge: 7d3901b5 6b265c64 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 7 21:36:24 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-1 commit 7d3901b5753f6456192f3533c257de7ae3bef6ac Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Sat Mar 4 10:15:18 2023 +0700 all: safesearch imp code commit 94a50dc61d955f659cda123825389225d0ebfc3e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 3 13:22:41 2023 +0700 safesearch: imp code commit aa6e30fed8f67ffbc336f619f299fbd789c86ada Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 21:43:28 2023 +0700 safesearch: imp code commit 30e75b6fa85edfdf66b7ace68cad4cbc61b28ea6 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 21:38:14 2023 +0700 safesearch: imp code commit 7d95ec73392b20519eab0e869ccba0c30404ae6f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 21:24:49 2023 +0700 safesearch: imp code commit d6c0a0fbf9ad836606fbbfe31702e84773a2709d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 21:04:53 2023 +0700 safesearch: imp code commit fa179b767bf75ed931cd62f282220d1f7025c641 Merge: 7a43ca00 012e5beb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 20:52:01 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-1 commit 7a43ca001ccab4d53b059c0e7843f2fc5b7dcefc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 11:59:35 2023 +0700 safesearch: embed rules commit 2b1a83d6ffacc89a3e81a8327653018ed803f15b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 11:50:29 2023 +0700 safesearch: imp code commit 400d463d32490cde7b4f55f3bb5a68e022e1c762 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 11:30:57 2023 +0700 safesearch: imp code commit 60cce36bdef0cf0def28c760a3d767314a03f176 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 11:16:56 2023 +0700 all: imp code commit 4eee3237b736fd16870835458757da550bcef295 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Feb 28 23:26:17 2023 +0700 all: safesearch package
2023-03-07 17:52:03 +03:00
Google bool `yaml:"google" json:"google"`
Pixabay bool `yaml:"pixabay" json:"pixabay"`
Yandex bool `yaml:"yandex" json:"yandex"`
YouTube bool `yaml:"youtube" json:"youtube"`
}
Pull request: 1163 safesearch vol.2 Merge in DNS/adguard-home from 1163-safesearch-1-2-1 to master Squashed commit of the following: commit d3a5ebef35210019842145074e898129b42f1f2c Merge: b85264ae c6706445 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 15 09:17:53 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 # Conflicts: # CHANGELOG.md commit b85264aefc5f191ac6cb194b519f03ba15829a4e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 14 00:16:07 2023 +0700 home: imp code commit ac2ed7a5ce8db40628e7d4d1c8634641e5f38b0b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 23:02:06 2023 +0700 all: changelog commit f0fccafcb01f50c7051df53bbe9b02cab75aa71e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:42:36 2023 +0700 all: changelog commit 37df29bf6372939644fb28e3d70365496e0cb4f6 Merge: b227b277 595484e0 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:38:57 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit b227b2775b4866d69241ad87acf99700715552cb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:56:01 2023 +0700 all: imp docs commit 6fd39fc3565c3f4bc7a7113d17733c20dfe24d8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:55:03 2023 +0700 home: imp code commit 3bb3bb7c7dcf97b2a5602a7d2b6770c08b4d863d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 12:16:53 2023 +0700 home: imp docs commit 5f573a56a9fd9942ad677fa0fae6b24228dab653 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 11:56:47 2023 +0700 home: imp code commit 23eeb5552cf2510596b2311cc3eda53ac678ffcc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 10 10:57:33 2023 +0700 home: imp code commit 643de2fca1b5917c61fe83e1e472222404f3cd21 Merge: dada6e63 a2053526 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 21:03:08 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit dada6e63ca5324d30775e2da1727da891743f654 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 17:09:03 2023 +0700 all: imp docs commit 81a180d99dd9a995440d5f4e2ebca34678e7d0c7 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 15:12:43 2023 +0700 all: imp code commit fa84877bc777004d246d71d0a9ae0bd9ee568a91 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:53:05 2023 +0700 all: imp code commit 6d7e02e745d72921a693d4f09eec7ce21c2aefd4 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:40:02 2023 +0700 all: imp docs commit 0a4332997070fb8d2fb3a34d32b92f57a325ff06 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 7 22:00:52 2023 +0700 safesearch: fix merge commit 145c2222ba4cf7f8909b816d83829d2217c94243 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 2 11:41:48 2023 +0700 safesearch: fix merge commit 14c6a8005fe15b5d5a39f91b17c96d8670975811 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:50:09 2023 +0700 all: docs commit 2a85c8831866bf1c34c423a289461fc1e32667b5 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:47:00 2023 +0700 all: use safesearch package
2023-03-15 14:31:07 +03:00
// checkSafeSearch checks host with safe search engine. Matches
// [hostChecker.check].
func (d *DNSFilter) checkSafeSearch(
host string,
qtype uint16,
setts *Settings,
) (res Result, err error) {
Pull request: AG-31778-fix-safesearch-https Squashed commit of the following: commit 85ea3d985e83209e3b49119959aedd330df24d23 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Apr 18 15:19:38 2024 +0200 all: imp docs commit b0695daddbcf191454c5e829ca4d19def8ddacbf Merge: a79f98f2f 48c6242a7 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Apr 17 11:06:49 2024 +0200 Merge remote-tracking branch 'origin/master' into AG-31778-fix-safesearch-https # Conflicts: # CHANGELOG.md commit a79f98f2f215a4a79ca4d186c0da33db936429dc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Apr 17 11:05:34 2024 +0200 dnsforward: imp code commit b901a1169cc78313298d70cce770cd1523ccbf9f Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Apr 16 11:03:52 2024 +0200 dnsforward: imp code commit fb6e66971b1b984147ec400ceaff856e7b5710c7 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Apr 16 10:08:51 2024 +0200 all: safesearch rewrites commit 88add21831fff7e04539f5dd299832883a6f3995 Merge: b78ad8f74 201ac73cf Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Apr 16 09:43:20 2024 +0200 Merge remote-tracking branch 'origin/master' into AG-31778-fix-safesearch-https # Conflicts: # CHANGELOG.md commit b78ad8f748c7fa52533e0541cae16bd51c201370 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Apr 12 13:34:39 2024 +0200 all: safesearch rewrites commit fb3efbb053242c537ca872542006917b8e8ac1ff Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Apr 11 13:15:37 2024 +0200 safesearch: imp code commit 1193c704f4d30be4a2cc66e84a31c9a6020ab269 Merge: 14e823d7c ff7c715c5 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Apr 11 13:13:44 2024 +0200 Merge remote-tracking branch 'origin/master' into AG-31778-fix-safesearch-https # Conflicts: # CHANGELOG.md commit 14e823d7cc13c275c2ed04704883a94b95e29963 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Apr 11 13:11:43 2024 +0200 all: safesearch https commit cd403a2897ae56a9059a78f24b104af5805d84ab Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Apr 11 12:09:27 2024 +0200 Revert "all: safesearch https" This reverts commit 1c9564b9b4db70f85b2f827cc06b65d2b67b08b1. commit 1c9564b9b4db70f85b2f827cc06b65d2b67b08b1 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Apr 10 12:41:47 2024 +0200 all: safesearch https commit 5f42688fbab566973acc8dc414a992819492a9ac Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Apr 10 09:22:30 2024 +0200 filtering: imp code commit eb9bd9f47cd71cafe8eee4698a8a0d5d25dea3d3 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Apr 10 09:19:22 2024 +0200 all: changelog commit 0c77c705a942fe83d3809a7efbc8a6baf5886762 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Apr 10 08:55:22 2024 +0200 safesearch: imp tests commit 492a93fbb5ff54678e22a15577f509b2327c2ebe Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Apr 9 14:45:16 2024 +0200 all: changelog commit a665e7246d11503c47d48ccc714e6862f764e930 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Apr 9 14:41:24 2024 +0200 safesearch: https req
2024-04-22 10:48:26 +03:00
if d.safeSearch == nil || !setts.ProtectionEnabled || !setts.SafeSearchEnabled {
return Result{}, nil
}
// TODO(s.chzhen): Pass context.
ctx := context.TODO()
Pull request: 1163 safesearch vol.2 Merge in DNS/adguard-home from 1163-safesearch-1-2-1 to master Squashed commit of the following: commit d3a5ebef35210019842145074e898129b42f1f2c Merge: b85264ae c6706445 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 15 09:17:53 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 # Conflicts: # CHANGELOG.md commit b85264aefc5f191ac6cb194b519f03ba15829a4e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 14 00:16:07 2023 +0700 home: imp code commit ac2ed7a5ce8db40628e7d4d1c8634641e5f38b0b Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 23:02:06 2023 +0700 all: changelog commit f0fccafcb01f50c7051df53bbe9b02cab75aa71e Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:42:36 2023 +0700 all: changelog commit 37df29bf6372939644fb28e3d70365496e0cb4f6 Merge: b227b277 595484e0 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 22:38:57 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit b227b2775b4866d69241ad87acf99700715552cb Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:56:01 2023 +0700 all: imp docs commit 6fd39fc3565c3f4bc7a7113d17733c20dfe24d8d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 16:55:03 2023 +0700 home: imp code commit 3bb3bb7c7dcf97b2a5602a7d2b6770c08b4d863d Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 12:16:53 2023 +0700 home: imp docs commit 5f573a56a9fd9942ad677fa0fae6b24228dab653 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Mon Mar 13 11:56:47 2023 +0700 home: imp code commit 23eeb5552cf2510596b2311cc3eda53ac678ffcc Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Fri Mar 10 10:57:33 2023 +0700 home: imp code commit 643de2fca1b5917c61fe83e1e472222404f3cd21 Merge: dada6e63 a2053526 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 21:03:08 2023 +0700 Merge remote-tracking branch 'origin/master' into 1163-safesearch-1-2-1 commit dada6e63ca5324d30775e2da1727da891743f654 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 17:09:03 2023 +0700 all: imp docs commit 81a180d99dd9a995440d5f4e2ebca34678e7d0c7 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 15:12:43 2023 +0700 all: imp code commit fa84877bc777004d246d71d0a9ae0bd9ee568a91 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:53:05 2023 +0700 all: imp code commit 6d7e02e745d72921a693d4f09eec7ce21c2aefd4 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 9 10:40:02 2023 +0700 all: imp docs commit 0a4332997070fb8d2fb3a34d32b92f57a325ff06 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Tue Mar 7 22:00:52 2023 +0700 safesearch: fix merge commit 145c2222ba4cf7f8909b816d83829d2217c94243 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Thu Mar 2 11:41:48 2023 +0700 safesearch: fix merge commit 14c6a8005fe15b5d5a39f91b17c96d8670975811 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:50:09 2023 +0700 all: docs commit 2a85c8831866bf1c34c423a289461fc1e32667b5 Author: Dimitry Kolyshev <dkolyshev@adguard.com> Date: Wed Mar 1 12:47:00 2023 +0700 all: use safesearch package
2023-03-15 14:31:07 +03:00
clientSafeSearch := setts.ClientSafeSearch
if clientSafeSearch != nil {
return clientSafeSearch.CheckHost(ctx, host, qtype)
}
return d.safeSearch.CheckHost(ctx, host, qtype)
2018-08-30 17:25:33 +03:00
}