docstring_tokens
stringlengths 18
16.9k
| code_tokens
stringlengths 75
1.81M
| html_url
stringlengths 74
116
| file_name
stringlengths 3
311
|
---|---|---|---|
keep keep keep keep replace keep keep keep keep keep
|
<mask> // package. It's a noop for other GOOS values.
<mask> chooseSystem()
<mask>
<mask> action := opts.serviceControlAction
<mask> log.Printf("service: control action: %s", action)
<mask>
<mask> if action == "reload" {
<mask> sendSigReload()
<mask>
<mask> return
</s> Pull request: HOFTIX-csrf
Merge in DNS/adguard-home from HOFTIX-csrf to master
Squashed commit of the following:
commit 75ab27bf6c52b80ab4e7347d7c254fa659eac244
Author: Ainar Garipov <[email protected]>
Date: Thu Sep 29 18:45:54 2022 +0300
all: imp cookie security; rm plain-text apis </s> remove for _, u := range a.users {
</s> add for _, u = range a.users { </s> remove for _, u := range a.users {
</s> add for _, u = range a.users { </s> remove return User{}
</s> add return webUser{} </s> remove // cookieTimeFormat is the format to be used in (time.Time).Format for cookie's
// expiry field.
const cookieTimeFormat = "Mon, 02 Jan 2006 15:04:05 GMT"
// cookieExpiryFormat returns the formatted exp to be used in cookie string.
// It's quite simple for now, but probably will be expanded in the future.
func cookieExpiryFormat(exp time.Time) (formatted string) {
return exp.Format(cookieTimeFormat)
}
func (a *Auth) httpCookie(req loginJSON, addr string) (cookie string, err error) {
blocker := a.blocker
u := a.UserFind(req.Name, req.Password)
if len(u.Name) == 0 {
if blocker != nil {
blocker.inc(addr)
</s> add // newCookie creates a new authentication cookie.
func (a *Auth) newCookie(req loginJSON, addr string) (c *http.Cookie, err error) {
rateLimiter := a.raleLimiter
u, ok := a.findUser(req.Name, req.Password)
if !ok {
if rateLimiter != nil {
rateLimiter.inc(addr) </s> remove // UserFind - find a user
func (a *Auth) UserFind(login, password string) User {
</s> add // findUser returns a user if there is one.
func (a *Auth) findUser(login, password string) (u webUser, ok bool) { </s> remove return u
</s> add return u, true
|
https://github.com/AdguardTeam/AdGuardHome/commit/756b14a61de138889130c239406dae43f1f115cb
|
internal/home/service.go
|
keep keep keep keep replace replace keep keep keep keep keep
|
<mask> return data, nil
<mask> }
<mask>
<mask> func marshalTLS(w http.ResponseWriter, r *http.Request, data tlsConfig) {
<mask> w.Header().Set("Content-Type", "application/json")
<mask>
<mask> if data.CertificateChain != "" {
<mask> encoded := base64.StdEncoding.EncodeToString([]byte(data.CertificateChain))
<mask> data.CertificateChain = encoded
<mask> }
<mask>
</s> Pull request: HOFTIX-csrf
Merge in DNS/adguard-home from HOFTIX-csrf to master
Squashed commit of the following:
commit 75ab27bf6c52b80ab4e7347d7c254fa659eac244
Author: Ainar Garipov <[email protected]>
Date: Thu Sep 29 18:45:54 2022 +0300
all: imp cookie security; rm plain-text apis </s> remove w.Header().Set("Content-Type", "application/json")
</s> add </s> remove
w.Header().Set("Content-Type", "application/json")
err = json.NewEncoder(w).Encode(result)
if err != nil {
aghhttp.Error(
r,
w,
http.StatusInternalServerError,
"Failed to marshal DHCP found json: %s",
err,
)
}
</s> add </s> remove func optionalAuthThird(w http.ResponseWriter, r *http.Request) (authFirst bool) {
authFirst = false
</s> add func optionalAuthThird(w http.ResponseWriter, r *http.Request) (mustAuth bool) {
if glProcessCookie(r) {
log.Debug("auth: authentication is handled by GL-Inet submodule")
return false
} </s> remove // This use of ReadAll is safe, because request's body is now limited.
body, err := io.ReadAll(r.Body)
if err != nil {
msg := fmt.Sprintf("failed to read request body: %s", err)
log.Println(msg)
http.Error(w, msg, http.StatusBadRequest)
</s> add if aghhttp.WriteTextPlainDeprecated(w, r) { </s> remove func parseCookie(cookie string) string {
pairs := strings.Split(cookie, ";")
for _, pair := range pairs {
pair = strings.TrimSpace(pair)
kv := strings.SplitN(pair, "=", 2)
if len(kv) != 2 {
continue
}
if kv[0] == sessionCookieName {
return kv[1]
}
}
return ""
}
</s> add </s> remove w.Header().Set("Content-Type", "application/json")
err = json.NewEncoder(w).Encode(resp)
if err != nil {
aghhttp.Error(r, w, http.StatusInternalServerError, "Unable to write response json: %s", err)
return
}
</s> add _ = aghhttp.WriteJSONResponse(w, r, resp)
|
https://github.com/AdguardTeam/AdGuardHome/commit/756b14a61de138889130c239406dae43f1f115cb
|
internal/home/tls.go
|
keep keep keep keep replace replace replace replace replace replace replace replace replace replace keep keep keep keep keep
|
<mask> data.PrivateKeySaved = true
<mask> data.PrivateKey = ""
<mask> }
<mask>
<mask> err := json.NewEncoder(w).Encode(data)
<mask> if err != nil {
<mask> aghhttp.Error(
<mask> r,
<mask> w,
<mask> http.StatusInternalServerError,
<mask> "Failed to marshal json with TLS status: %s",
<mask> err,
<mask> )
<mask> }
<mask> }
<mask>
<mask> // registerWebHandlers registers HTTP handlers for TLS configuration
<mask> func (t *TLSMod) registerWebHandlers() {
<mask> httpRegister(http.MethodGet, "/control/tls/status", t.handleTLSStatus)
</s> Pull request: HOFTIX-csrf
Merge in DNS/adguard-home from HOFTIX-csrf to master
Squashed commit of the following:
commit 75ab27bf6c52b80ab4e7347d7c254fa659eac244
Author: Ainar Garipov <[email protected]>
Date: Thu Sep 29 18:45:54 2022 +0300
all: imp cookie security; rm plain-text apis </s> remove w.Header().Set("Content-Type", "application/json")
err = json.NewEncoder(w).Encode(data)
if err != nil {
aghhttp.Error(
r,
w,
http.StatusInternalServerError,
"Unable to marshal default addresses to json: %s",
err,
)
return
}
</s> add _ = aghhttp.WriteJSONResponse(w, r, data) </s> remove
w.Header().Set("Content-Type", "application/json")
err = json.NewEncoder(w).Encode(result)
if err != nil {
aghhttp.Error(
r,
w,
http.StatusInternalServerError,
"Failed to marshal DHCP found json: %s",
err,
)
}
</s> add </s> remove w.Header().Set("Content-Type", "application/json")
err = json.NewEncoder(w).Encode(data)
if err != nil {
aghhttp.Error(
r,
w,
http.StatusInternalServerError,
"Unable to marshal default addresses to json: %s",
err,
)
return
}
</s> add _ = aghhttp.WriteJSONResponse(w, r, data) </s> remove language := strings.TrimSpace(string(body))
if language == "" {
msg := "empty language specified"
log.Println(msg)
http.Error(w, msg, http.StatusBadRequest)
</s> add langReq := &languageJSON{}
err := json.NewDecoder(r.Body).Decode(langReq)
if err != nil {
aghhttp.Error(r, w, http.StatusInternalServerError, "reading req: %s", err) </s> remove w.Header().Set("Content-Type", "application/json")
err = json.NewEncoder(w).Encode(resp)
if err != nil {
aghhttp.Error(r, w, http.StatusInternalServerError, "Unable to write response json: %s", err)
return
}
</s> add _ = aghhttp.WriteJSONResponse(w, r, resp) </s> remove w.Header().Set("Content-Type", "application/json")
e := json.NewEncoder(w).Encode(data)
if e != nil {
aghhttp.Error(r, w, http.StatusInternalServerError, "failed to encode to json: %v", e)
return
}
</s> add _ = aghhttp.WriteJSONResponse(w, r, data)
|
https://github.com/AdguardTeam/AdGuardHome/commit/756b14a61de138889130c239406dae43f1f115cb
|
internal/home/tls.go
|
keep keep keep replace keep keep keep replace keep
|
<mask> log.Fatalf("Can't use password \"%s\": bcrypt.GenerateFromPassword: %s", passStr, err)
<mask> return nil
<mask> }
<mask> u := User{
<mask> Name: nameStr,
<mask> PasswordHash: string(hash),
<mask> }
<mask> users := []User{u}
<mask> diskConf["users"] = users
</s> Pull request: HOFTIX-csrf
Merge in DNS/adguard-home from HOFTIX-csrf to master
Squashed commit of the following:
commit 75ab27bf6c52b80ab4e7347d7c254fa659eac244
Author: Ainar Garipov <[email protected]>
Date: Thu Sep 29 18:45:54 2022 +0300
all: imp cookie security; rm plain-text apis </s> remove users := []User{{
</s> add users := []webUser{{ </s> remove users := []User{
</s> add users := []webUser{ </s> remove u := &User{
</s> add u := &webUser{ </s> remove func (a *Auth) GetUsers() []User {
</s> add func (a *Auth) GetUsers() []webUser { </s> remove return User{}
</s> add return webUser{}
|
https://github.com/AdguardTeam/AdGuardHome/commit/756b14a61de138889130c239406dae43f1f115cb
|
internal/home/upgrade.go
|
keep keep keep add keep keep keep keep keep keep
|
<mask> 'tags':
<mask> - 'dhcp'
<mask> 'operationId': 'checkActiveDhcp'
<mask> 'summary': 'Searches for an active DHCP server on the network'
<mask> 'responses':
<mask> '200':
<mask> 'description': 'OK.'
<mask> 'content':
<mask> 'application/json':
<mask> 'schema':
</s> Pull request: HOFTIX-csrf
Merge in DNS/adguard-home from HOFTIX-csrf to master
Squashed commit of the following:
commit 75ab27bf6c52b80ab4e7347d7c254fa659eac244
Author: Ainar Garipov <[email protected]>
Date: Thu Sep 29 18:45:54 2022 +0300
all: imp cookie security; rm plain-text apis </s> remove 'text/plain':
'examples':
'response':
'value': 'en'
</s> add 'application/json':
'schema':
'$ref': '#/components/schemas/LanguageSettings' </s> remove 'requestBody':
'content':
'text/plain':
'schema':
'type': 'string'
'enum':
- 'EARLY_CHILDHOOD'
- 'YOUNG'
- 'TEEN'
- 'MATURE'
'example': 'sensitivity=TEEN'
'description': |
Age sensitivity for parental filtering,
EARLY_CHILDHOOD is 3
YOUNG is 10
TEEN is 13
MATURE is 17
'required': true
</s> add </s> remove 'type': 'string'
'example': 'en'
</s> add '$ref': '#/components/schemas/LanguageSettings' </s> remove 'text/plain':
</s> add 'application/json': </s> add 'DhcpFindActiveReq':
'description': >
Request for checking for other DHCP servers in the network.
'properties':
'interface':
'description': 'The name of the network interface'
'example': 'eth0'
'type': 'string'
'type': 'object'
</s> remove // Perform the following tasks:
// . Search for another DHCP server running
// . Check if a static IP is configured for the network interface
// Respond with results
</s> add // findActiveServerReq is the JSON structure for the request to find active DHCP
// servers.
type findActiveServerReq struct {
Interface string `json:"interface"`
}
// handleDHCPFindActiveServer performs the following tasks:
// 1. searches for another DHCP server in the network;
// 2. check if a static IP is configured for the network interface;
// 3. responds with the results.
|
https://github.com/AdguardTeam/AdGuardHome/commit/756b14a61de138889130c239406dae43f1f115cb
|
openapi/openapi.yaml
|
keep keep keep keep replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace keep keep keep keep keep
|
<mask> 'tags':
<mask> - 'parental'
<mask> 'operationId': 'parentalEnable'
<mask> 'summary': 'Enable parental filtering'
<mask> 'requestBody':
<mask> 'content':
<mask> 'text/plain':
<mask> 'schema':
<mask> 'type': 'string'
<mask> 'enum':
<mask> - 'EARLY_CHILDHOOD'
<mask> - 'YOUNG'
<mask> - 'TEEN'
<mask> - 'MATURE'
<mask> 'example': 'sensitivity=TEEN'
<mask> 'description': |
<mask> Age sensitivity for parental filtering,
<mask> EARLY_CHILDHOOD is 3
<mask> YOUNG is 10
<mask> TEEN is 13
<mask> MATURE is 17
<mask> 'required': true
<mask> 'responses':
<mask> '200':
<mask> 'description': 'OK.'
<mask> '/parental/disable':
<mask> 'post':
</s> Pull request: HOFTIX-csrf
Merge in DNS/adguard-home from HOFTIX-csrf to master
Squashed commit of the following:
commit 75ab27bf6c52b80ab4e7347d7c254fa659eac244
Author: Ainar Garipov <[email protected]>
Date: Thu Sep 29 18:45:54 2022 +0300
all: imp cookie security; rm plain-text apis </s> add 'requestBody':
'content':
'application/json':
'schema':
'$ref': '#/components/schemas/DhcpFindActiveReq' </s> remove 'text/plain':
'examples':
'response':
'value': 'en'
</s> add 'application/json':
'schema':
'$ref': '#/components/schemas/LanguageSettings' </s> remove 'type': 'string'
'example': 'en'
</s> add '$ref': '#/components/schemas/LanguageSettings' </s> add 'LanguageSettings':
'description': 'Language settings object.'
'properties':
'language':
'description': 'The current language or the language to set.'
'type': 'string'
'required':
- 'language'
'type': 'object' </s> remove 'text/plain':
</s> add 'application/json': </s> add 'DhcpFindActiveReq':
'description': >
Request for checking for other DHCP servers in the network.
'properties':
'interface':
'description': 'The name of the network interface'
'example': 'eth0'
'type': 'string'
'type': 'object'
|
https://github.com/AdguardTeam/AdGuardHome/commit/756b14a61de138889130c239406dae43f1f115cb
|
openapi/openapi.yaml
|
keep keep replace keep replace replace keep keep
|
<mask> 'requestBody':
<mask> 'content':
<mask> 'text/plain':
<mask> 'schema':
<mask> 'type': 'string'
<mask> 'example': 'en'
<mask> 'description': >
<mask> New language. It must be known to the server and must be an ISO 639-1
</s> Pull request: HOFTIX-csrf
Merge in DNS/adguard-home from HOFTIX-csrf to master
Squashed commit of the following:
commit 75ab27bf6c52b80ab4e7347d7c254fa659eac244
Author: Ainar Garipov <[email protected]>
Date: Thu Sep 29 18:45:54 2022 +0300
all: imp cookie security; rm plain-text apis </s> add 'requestBody':
'content':
'application/json':
'schema':
'$ref': '#/components/schemas/DhcpFindActiveReq' </s> add 'DhcpFindActiveReq':
'description': >
Request for checking for other DHCP servers in the network.
'properties':
'interface':
'description': 'The name of the network interface'
'example': 'eth0'
'type': 'string'
'type': 'object'
</s> remove 'requestBody':
'content':
'text/plain':
'schema':
'type': 'string'
'enum':
- 'EARLY_CHILDHOOD'
- 'YOUNG'
- 'TEEN'
- 'MATURE'
'example': 'sensitivity=TEEN'
'description': |
Age sensitivity for parental filtering,
EARLY_CHILDHOOD is 3
YOUNG is 10
TEEN is 13
MATURE is 17
'required': true
</s> add </s> remove 'text/plain':
'examples':
'response':
'value': 'en'
</s> add 'application/json':
'schema':
'$ref': '#/components/schemas/LanguageSettings' </s> add 'LanguageSettings':
'description': 'Language settings object.'
'properties':
'language':
'description': 'The current language or the language to set.'
'type': 'string'
'required':
- 'language'
'type': 'object'
|
https://github.com/AdguardTeam/AdGuardHome/commit/756b14a61de138889130c239406dae43f1f115cb
|
openapi/openapi.yaml
|
keep keep keep keep replace replace replace replace keep keep keep keep keep
|
<mask> 'responses':
<mask> '200':
<mask> 'description': 'OK.'
<mask> 'content':
<mask> 'text/plain':
<mask> 'examples':
<mask> 'response':
<mask> 'value': 'en'
<mask> '/install/get_addresses_beta':
<mask> 'get':
<mask> 'tags':
<mask> - 'install'
<mask> 'operationId': 'installGetAddressesBeta'
</s> Pull request: HOFTIX-csrf
Merge in DNS/adguard-home from HOFTIX-csrf to master
Squashed commit of the following:
commit 75ab27bf6c52b80ab4e7347d7c254fa659eac244
Author: Ainar Garipov <[email protected]>
Date: Thu Sep 29 18:45:54 2022 +0300
all: imp cookie security; rm plain-text apis </s> add 'requestBody':
'content':
'application/json':
'schema':
'$ref': '#/components/schemas/DhcpFindActiveReq' </s> remove 'requestBody':
'content':
'text/plain':
'schema':
'type': 'string'
'enum':
- 'EARLY_CHILDHOOD'
- 'YOUNG'
- 'TEEN'
- 'MATURE'
'example': 'sensitivity=TEEN'
'description': |
Age sensitivity for parental filtering,
EARLY_CHILDHOOD is 3
YOUNG is 10
TEEN is 13
MATURE is 17
'required': true
</s> add </s> remove 'type': 'string'
'example': 'en'
</s> add '$ref': '#/components/schemas/LanguageSettings' </s> remove 'text/plain':
</s> add 'application/json': </s> add 'LanguageSettings':
'description': 'Language settings object.'
'properties':
'language':
'description': 'The current language or the language to set.'
'type': 'string'
'required':
- 'language'
'type': 'object' </s> add 'DhcpFindActiveReq':
'description': >
Request for checking for other DHCP servers in the network.
'properties':
'interface':
'description': 'The name of the network interface'
'example': 'eth0'
'type': 'string'
'type': 'object'
|
https://github.com/AdguardTeam/AdGuardHome/commit/756b14a61de138889130c239406dae43f1f115cb
|
openapi/openapi.yaml
|
keep add keep keep keep keep keep
|
<mask> '$ref': '#/components/schemas/NetInterface'
<mask>
<mask> 'DhcpSearchResult':
<mask> 'type': 'object'
<mask> 'description': >
<mask> Information about a DHCP server discovered in the current network.
<mask> 'properties':
</s> Pull request: HOFTIX-csrf
Merge in DNS/adguard-home from HOFTIX-csrf to master
Squashed commit of the following:
commit 75ab27bf6c52b80ab4e7347d7c254fa659eac244
Author: Ainar Garipov <[email protected]>
Date: Thu Sep 29 18:45:54 2022 +0300
all: imp cookie security; rm plain-text apis </s> add 'LanguageSettings':
'description': 'Language settings object.'
'properties':
'language':
'description': 'The current language or the language to set.'
'type': 'string'
'required':
- 'language'
'type': 'object' </s> remove 'type': 'string'
'example': 'en'
</s> add '$ref': '#/components/schemas/LanguageSettings' </s> remove 'text/plain':
</s> add 'application/json': </s> add 'requestBody':
'content':
'application/json':
'schema':
'$ref': '#/components/schemas/DhcpFindActiveReq' </s> remove // Perform the following tasks:
// . Search for another DHCP server running
// . Check if a static IP is configured for the network interface
// Respond with results
</s> add // findActiveServerReq is the JSON structure for the request to find active DHCP
// servers.
type findActiveServerReq struct {
Interface string `json:"interface"`
}
// handleDHCPFindActiveServer performs the following tasks:
// 1. searches for another DHCP server in the network;
// 2. check if a static IP is configured for the network interface;
// 3. responds with the results. </s> remove BindHost net.IP `yaml:"bind_host"` // BindHost is the IP address of the HTTP server to bind to
BindPort int `yaml:"bind_port"` // BindPort is the port the HTTP server
BetaBindPort int `yaml:"beta_bind_port"` // BetaBindPort is the port for new client
Users []User `yaml:"users"` // Users that can access HTTP server
</s> add BindHost net.IP `yaml:"bind_host"` // BindHost is the IP address of the HTTP server to bind to
BindPort int `yaml:"bind_port"` // BindPort is the port the HTTP server
BetaBindPort int `yaml:"beta_bind_port"` // BetaBindPort is the port for new client
Users []webUser `yaml:"users"` // Users that can access HTTP server
|
https://github.com/AdguardTeam/AdGuardHome/commit/756b14a61de138889130c239406dae43f1f115cb
|
openapi/openapi.yaml
|
keep keep keep add keep keep keep keep
|
<mask> 'message':
<mask> 'description': 'The error message, an opaque string.'
<mask> 'type': 'string'
<mask> 'type': 'object'
<mask> 'securitySchemes':
<mask> 'basicAuth':
<mask> 'type': 'http'
<mask> 'scheme': 'basic'
</s> Pull request: HOFTIX-csrf
Merge in DNS/adguard-home from HOFTIX-csrf to master
Squashed commit of the following:
commit 75ab27bf6c52b80ab4e7347d7c254fa659eac244
Author: Ainar Garipov <[email protected]>
Date: Thu Sep 29 18:45:54 2022 +0300
all: imp cookie security; rm plain-text apis </s> add 'DhcpFindActiveReq':
'description': >
Request for checking for other DHCP servers in the network.
'properties':
'interface':
'description': 'The name of the network interface'
'example': 'eth0'
'type': 'string'
'type': 'object'
</s> remove 'type': 'string'
'example': 'en'
</s> add '$ref': '#/components/schemas/LanguageSettings' </s> remove 'text/plain':
</s> add 'application/json': </s> remove 'requestBody':
'content':
'text/plain':
'schema':
'type': 'string'
'enum':
- 'EARLY_CHILDHOOD'
- 'YOUNG'
- 'TEEN'
- 'MATURE'
'example': 'sensitivity=TEEN'
'description': |
Age sensitivity for parental filtering,
EARLY_CHILDHOOD is 3
YOUNG is 10
TEEN is 13
MATURE is 17
'required': true
</s> add </s> add 'requestBody':
'content':
'application/json':
'schema':
'$ref': '#/components/schemas/DhcpFindActiveReq' </s> remove 'text/plain':
'examples':
'response':
'value': 'en'
</s> add 'application/json':
'schema':
'$ref': '#/components/schemas/LanguageSettings'
|
https://github.com/AdguardTeam/AdGuardHome/commit/756b14a61de138889130c239406dae43f1f115cb
|
openapi/openapi.yaml
|
keep keep keep keep replace keep
|
<mask> "reset_settings": "Reset settings",
<mask> "update_announcement": "AdGuard Home {{version}} is now available! <0>Click here</0> for more info.",
<mask> "upstream_parallel": "Use parallel queries to speed up resolving by simultaneously querying all upstream servers",
<mask> "bootstrap_dns": "Bootstrap DNS servers",
<mask> "bootstrap_dns_desc": "Bootstrap DNS servers are used to resolve IP addresses of the DOH/DOT resolvers you specify as upstreams."
<mask> }
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> add .popover__list--bold {
font-weight: 700;
}
</s> add .nav-version__link {
position: relative;
display: inline-block;
border-bottom: 1px dashed #495057;
cursor: pointer;
}
</s> remove <div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
</s> add {!dashboard.processing &&
<div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
} </s> add .popover__trigger--address {
top: 0;
margin: 0;
line-height: 1.2;
}
.popover__trigger--address:after {
display: none;
}
</s> add import { getDnsAddress } from '../../helpers/helpers';
</s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props;
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/__locales/en.json
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> import Dashboard from '../../containers/Dashboard';
<mask> import Settings from '../../containers/Settings';
<mask> import Filters from '../../containers/Filters';
<mask> import Logs from '../../containers/Logs';
<mask> import Footer from '../ui/Footer';
<mask> import Toasts from '../Toasts';
<mask> import Status from '../ui/Status';
<mask> import UpdateTopline from '../ui/UpdateTopline';
<mask> import EncryptionTopline from '../ui/EncryptionTopline';
<mask> import i18n from '../../i18n';
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> add import Footer from '../ui/Footer'; </s> remove import Tabs from '../../components/ui/Tabs';
import Icons from '../../components/ui/Icons';
</s> add import Guide from '../../components/ui/Guide'; </s> remove import { REPOSITORY } from '../../helpers/constants';
</s> add </s> add import { getDnsAddress } from '../../helpers/helpers';
</s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> add <Route path="/guide" component={SetupGuide} />
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/components/App/index.js
|
keep keep keep add keep keep keep keep keep keep
|
<mask> import Filters from '../../containers/Filters';
<mask> import Logs from '../../containers/Logs';
<mask> import SetupGuide from '../../containers/SetupGuide';
<mask> import Toasts from '../Toasts';
<mask> import Status from '../ui/Status';
<mask> import UpdateTopline from '../ui/UpdateTopline';
<mask> import EncryptionTopline from '../ui/EncryptionTopline';
<mask> import i18n from '../../i18n';
<mask>
<mask> class App extends Component {
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> remove import Footer from '../ui/Footer';
</s> add import SetupGuide from '../../containers/SetupGuide'; </s> remove import { REPOSITORY } from '../../helpers/constants';
</s> add </s> remove import Tabs from '../../components/ui/Tabs';
import Icons from '../../components/ui/Icons';
</s> add import Guide from '../../components/ui/Guide'; </s> add import { getDnsAddress } from '../../helpers/helpers';
</s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> add .popover__list--bold {
font-weight: 700;
}
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/components/App/index.js
|
keep keep add keep keep keep keep keep keep
|
<mask> <Route path="/settings" component={Settings} />
<mask> <Route path="/filters" component={Filters} />
<mask> <Route path="/logs" component={Logs} />
<mask> </Fragment>
<mask> }
<mask> </div>
<mask> <Footer />
<mask> <Toasts />
<mask> </Fragment>
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> remove <div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
</s> add {!dashboard.processing &&
<div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
} </s> remove <Icons />
<Tabs>
<div label="Router">
<div className="tab__title">
<Trans>install_devices_router</Trans>
</div>
<div className="tab__text">
<p><Trans>install_devices_router_desc</Trans></p>
<ol>
<li><Trans>install_devices_router_list_1</Trans></li>
<li><Trans>install_devices_router_list_2</Trans></li>
<li><Trans>install_devices_router_list_3</Trans></li>
</ol>
</div>
</div>
<div label="Windows">
<div className="tab__title">
Windows
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_windows_list_1</Trans></li>
<li><Trans>install_devices_windows_list_2</Trans></li>
<li><Trans>install_devices_windows_list_3</Trans></li>
<li><Trans>install_devices_windows_list_4</Trans></li>
<li><Trans>install_devices_windows_list_5</Trans></li>
<li><Trans>install_devices_windows_list_6</Trans></li>
</ol>
</div>
</div>
<div label="macOS">
<div className="tab__title">
macOS
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_macos_list_1</Trans></li>
<li><Trans>install_devices_macos_list_2</Trans></li>
<li><Trans>install_devices_macos_list_3</Trans></li>
<li><Trans>install_devices_macos_list_4</Trans></li>
</ol>
</div>
</div>
<div label="Android">
<div className="tab__title">
Android
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_android_list_1</Trans></li>
<li><Trans>install_devices_android_list_2</Trans></li>
<li><Trans>install_devices_android_list_3</Trans></li>
<li><Trans>install_devices_android_list_4</Trans></li>
<li><Trans>install_devices_android_list_5</Trans></li>
</ol>
</div>
</div>
<div label="iOS">
<div className="tab__title">
iOS
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_ios_list_1</Trans></li>
<li><Trans>install_devices_ios_list_2</Trans></li>
<li><Trans>install_devices_ios_list_3</Trans></li>
<li><Trans>install_devices_ios_list_4</Trans></li>
</ol>
</div>
</div>
</Tabs>
</s> add <Guide /> </s> remove <Trans>faq</Trans>
</a>
</s> add <Trans>setup_guide</Trans>
</NavLink> </s> remove <div className="nav-version__text">
<Trans>address</Trans>: <span className="nav-version__value">{dnsAddress}:{dnsPort}</span>
</s> add <div className="nav-version__link">
<div className="popover__trigger popover__trigger--address">
<Trans>dns_addresses</Trans>
</div>
<div className="popover__body popover__body--address">
<div className="popover__list">
{dnsAddresses
.map(ip => <li key={ip}>{getDnsAddress(ip, dnsPort)}</li>)
}
</div>
</div> </s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> add .popover__list--bold {
font-weight: 700;
}
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/components/App/index.js
|
keep add keep keep keep keep
|
<mask> }
<mask>
<mask> .header-brand-img {
<mask> height: 32px;
<mask> }
<mask>
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> add .popover__list--bold {
font-weight: 700;
}
</s> add import { getDnsAddress } from '../../helpers/helpers';
</s> add .popover__trigger--address {
top: 0;
margin: 0;
line-height: 1.2;
}
.popover__trigger--address:after {
display: none;
}
</s> remove <div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
</s> add {!dashboard.processing &&
<div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
} </s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> remove import { REPOSITORY } from '../../helpers/constants';
</s> add
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/components/Header/Header.css
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> import PropTypes from 'prop-types';
<mask> import enhanceWithClickOutside from 'react-click-outside';
<mask> import classnames from 'classnames';
<mask> import { Trans, withNamespaces } from 'react-i18next';
<mask> import { REPOSITORY } from '../../helpers/constants';
<mask>
<mask> class Menu extends Component {
<mask> handleClickOutside = () => {
<mask> this.props.closeMenu();
<mask> };
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> add import { getDnsAddress } from '../../helpers/helpers';
</s> remove import Tabs from '../../components/ui/Tabs';
import Icons from '../../components/ui/Icons';
</s> add import Guide from '../../components/ui/Guide'; </s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> add import Footer from '../ui/Footer'; </s> remove import Footer from '../ui/Footer';
</s> add import SetupGuide from '../../containers/SetupGuide'; </s> remove dnsVersion: PropTypes.string,
dnsAddress: PropTypes.string,
dnsPort: PropTypes.number,
</s> add dnsVersion: PropTypes.string.isRequired,
dnsAddresses: PropTypes.array.isRequired,
dnsPort: PropTypes.number.isRequired,
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/components/Header/Menu.js
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> <Trans>query_log</Trans>
<mask> </NavLink>
<mask> </li>
<mask> <li className="nav-item">
<mask> <a href={`${REPOSITORY.URL}/wiki`} className="nav-link" target="_blank" rel="noopener noreferrer">
<mask> <svg className="nav-icon" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#66b574" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round"><circle cx="12" cy="12" r="10"></circle><path d="M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3"></path><line x1="12" y1="17" x2="12" y2="17"></line></svg>
<mask> <Trans>faq</Trans>
<mask> </a>
<mask> </li>
<mask> </ul>
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> remove <Trans>faq</Trans>
</a>
</s> add <Trans>setup_guide</Trans>
</NavLink> </s> remove <div className="nav-version__text">
<Trans>address</Trans>: <span className="nav-version__value">{dnsAddress}:{dnsPort}</span>
</s> add <div className="nav-version__link">
<div className="popover__trigger popover__trigger--address">
<Trans>dns_addresses</Trans>
</div>
<div className="popover__body popover__body--address">
<div className="popover__list">
{dnsAddresses
.map(ip => <li key={ip}>{getDnsAddress(ip, dnsPort)}</li>)
}
</div>
</div> </s> add dnsPort: 53,
dnsAddresses: [],
dnsVersion: '', </s> add import { getDnsAddress } from '../../helpers/helpers';
</s> remove import Footer from '../ui/Footer';
</s> add import SetupGuide from '../../containers/SetupGuide'; </s> add import Footer from '../ui/Footer';
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/components/Header/Menu.js
|
keep keep keep keep replace replace keep keep keep keep keep
|
<mask> </li>
<mask> <li className="nav-item">
<mask> <a href={`${REPOSITORY.URL}/wiki`} className="nav-link" target="_blank" rel="noopener noreferrer">
<mask> <svg className="nav-icon" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#66b574" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round"><circle cx="12" cy="12" r="10"></circle><path d="M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3"></path><line x1="12" y1="17" x2="12" y2="17"></line></svg>
<mask> <Trans>faq</Trans>
<mask> </a>
<mask> </li>
<mask> </ul>
<mask> </div>
<mask> </Fragment>
<mask> );
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> remove <a href={`${REPOSITORY.URL}/wiki`} className="nav-link" target="_blank" rel="noopener noreferrer">
</s> add <NavLink to="/guide" href="/guide" className="nav-link"> </s> remove <div className="nav-version__text">
<Trans>address</Trans>: <span className="nav-version__value">{dnsAddress}:{dnsPort}</span>
</s> add <div className="nav-version__link">
<div className="popover__trigger popover__trigger--address">
<Trans>dns_addresses</Trans>
</div>
<div className="popover__body popover__body--address">
<div className="popover__list">
{dnsAddresses
.map(ip => <li key={ip}>{getDnsAddress(ip, dnsPort)}</li>)
}
</div>
</div> </s> add <Route path="/guide" component={SetupGuide} /> </s> remove <div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
</s> add {!dashboard.processing &&
<div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
} </s> remove <Icons />
<Tabs>
<div label="Router">
<div className="tab__title">
<Trans>install_devices_router</Trans>
</div>
<div className="tab__text">
<p><Trans>install_devices_router_desc</Trans></p>
<ol>
<li><Trans>install_devices_router_list_1</Trans></li>
<li><Trans>install_devices_router_list_2</Trans></li>
<li><Trans>install_devices_router_list_3</Trans></li>
</ol>
</div>
</div>
<div label="Windows">
<div className="tab__title">
Windows
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_windows_list_1</Trans></li>
<li><Trans>install_devices_windows_list_2</Trans></li>
<li><Trans>install_devices_windows_list_3</Trans></li>
<li><Trans>install_devices_windows_list_4</Trans></li>
<li><Trans>install_devices_windows_list_5</Trans></li>
<li><Trans>install_devices_windows_list_6</Trans></li>
</ol>
</div>
</div>
<div label="macOS">
<div className="tab__title">
macOS
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_macos_list_1</Trans></li>
<li><Trans>install_devices_macos_list_2</Trans></li>
<li><Trans>install_devices_macos_list_3</Trans></li>
<li><Trans>install_devices_macos_list_4</Trans></li>
</ol>
</div>
</div>
<div label="Android">
<div className="tab__title">
Android
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_android_list_1</Trans></li>
<li><Trans>install_devices_android_list_2</Trans></li>
<li><Trans>install_devices_android_list_3</Trans></li>
<li><Trans>install_devices_android_list_4</Trans></li>
<li><Trans>install_devices_android_list_5</Trans></li>
</ol>
</div>
</div>
<div label="iOS">
<div className="tab__title">
iOS
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_ios_list_1</Trans></li>
<li><Trans>install_devices_ios_list_2</Trans></li>
<li><Trans>install_devices_ios_list_3</Trans></li>
<li><Trans>install_devices_ios_list_4</Trans></li>
</ol>
</div>
</div>
</Tabs>
</s> add <Guide /> </s> remove dnsVersion: PropTypes.string,
dnsAddress: PropTypes.string,
dnsPort: PropTypes.number,
</s> add dnsVersion: PropTypes.string.isRequired,
dnsAddresses: PropTypes.array.isRequired,
dnsPort: PropTypes.number.isRequired,
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/components/Header/Menu.js
|
keep keep add keep keep keep keep
|
<mask> import PropTypes from 'prop-types';
<mask> import { Trans, withNamespaces } from 'react-i18next';
<mask>
<mask> function Version(props) {
<mask> const { dnsVersion, dnsAddresses, dnsPort } = props;
<mask> return (
<mask> <div className="nav-version">
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> remove import { REPOSITORY } from '../../helpers/constants';
</s> add </s> remove import Tabs from '../../components/ui/Tabs';
import Icons from '../../components/ui/Icons';
</s> add import Guide from '../../components/ui/Guide'; </s> add import Footer from '../ui/Footer'; </s> remove import Footer from '../ui/Footer';
</s> add import SetupGuide from '../../containers/SetupGuide'; </s> remove <div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
</s> add {!dashboard.processing &&
<div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
}
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/components/Header/Version.js
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> import PropTypes from 'prop-types';
<mask> import { Trans, withNamespaces } from 'react-i18next';
<mask>
<mask> function Version(props) {
<mask> const { dnsVersion, dnsAddress, dnsPort } = props;
<mask> return (
<mask> <div className="nav-version">
<mask> <div className="nav-version__text">
<mask> <Trans>version</Trans>: <span className="nav-version__value">{dnsVersion}</span>
<mask> </div>
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> add import { getDnsAddress } from '../../helpers/helpers';
</s> remove import { REPOSITORY } from '../../helpers/constants';
</s> add </s> remove <div className="nav-version__text">
<Trans>address</Trans>: <span className="nav-version__value">{dnsAddress}:{dnsPort}</span>
</s> add <div className="nav-version__link">
<div className="popover__trigger popover__trigger--address">
<Trans>dns_addresses</Trans>
</div>
<div className="popover__body popover__body--address">
<div className="popover__list">
{dnsAddresses
.map(ip => <li key={ip}>{getDnsAddress(ip, dnsPort)}</li>)
}
</div>
</div> </s> remove import Tabs from '../../components/ui/Tabs';
import Icons from '../../components/ui/Icons';
</s> add import Guide from '../../components/ui/Guide'; </s> remove <div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
</s> add {!dashboard.processing &&
<div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
} </s> add import Footer from '../ui/Footer';
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/components/Header/Version.js
|
keep keep keep keep replace replace keep keep keep keep keep
|
<mask> <div className="nav-version">
<mask> <div className="nav-version__text">
<mask> <Trans>version</Trans>: <span className="nav-version__value">{dnsVersion}</span>
<mask> </div>
<mask> <div className="nav-version__text">
<mask> <Trans>address</Trans>: <span className="nav-version__value">{dnsAddress}:{dnsPort}</span>
<mask> </div>
<mask> </div>
<mask> );
<mask> }
<mask>
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> remove <Icons />
<Tabs>
<div label="Router">
<div className="tab__title">
<Trans>install_devices_router</Trans>
</div>
<div className="tab__text">
<p><Trans>install_devices_router_desc</Trans></p>
<ol>
<li><Trans>install_devices_router_list_1</Trans></li>
<li><Trans>install_devices_router_list_2</Trans></li>
<li><Trans>install_devices_router_list_3</Trans></li>
</ol>
</div>
</div>
<div label="Windows">
<div className="tab__title">
Windows
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_windows_list_1</Trans></li>
<li><Trans>install_devices_windows_list_2</Trans></li>
<li><Trans>install_devices_windows_list_3</Trans></li>
<li><Trans>install_devices_windows_list_4</Trans></li>
<li><Trans>install_devices_windows_list_5</Trans></li>
<li><Trans>install_devices_windows_list_6</Trans></li>
</ol>
</div>
</div>
<div label="macOS">
<div className="tab__title">
macOS
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_macos_list_1</Trans></li>
<li><Trans>install_devices_macos_list_2</Trans></li>
<li><Trans>install_devices_macos_list_3</Trans></li>
<li><Trans>install_devices_macos_list_4</Trans></li>
</ol>
</div>
</div>
<div label="Android">
<div className="tab__title">
Android
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_android_list_1</Trans></li>
<li><Trans>install_devices_android_list_2</Trans></li>
<li><Trans>install_devices_android_list_3</Trans></li>
<li><Trans>install_devices_android_list_4</Trans></li>
<li><Trans>install_devices_android_list_5</Trans></li>
</ol>
</div>
</div>
<div label="iOS">
<div className="tab__title">
iOS
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_ios_list_1</Trans></li>
<li><Trans>install_devices_ios_list_2</Trans></li>
<li><Trans>install_devices_ios_list_3</Trans></li>
<li><Trans>install_devices_ios_list_4</Trans></li>
</ol>
</div>
</div>
</Tabs>
</s> add <Guide /> </s> remove <div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
</s> add {!dashboard.processing &&
<div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
} </s> add import { getDnsAddress } from '../../helpers/helpers';
</s> add <Route path="/guide" component={SetupGuide} /> </s> remove <Trans>faq</Trans>
</a>
</s> add <Trans>setup_guide</Trans>
</NavLink>
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/components/Header/Version.js
|
keep keep keep keep replace replace replace keep keep keep
|
<mask> );
<mask> }
<mask>
<mask> Version.propTypes = {
<mask> dnsVersion: PropTypes.string,
<mask> dnsAddress: PropTypes.string,
<mask> dnsPort: PropTypes.number,
<mask> };
<mask>
<mask> export default withNamespaces()(Version);
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> add dnsPort: 53,
dnsAddresses: [],
dnsVersion: '', </s> remove import { REPOSITORY } from '../../helpers/constants';
</s> add </s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> remove <div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
</s> add {!dashboard.processing &&
<div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
} </s> add import { getDnsAddress } from '../../helpers/helpers';
</s> remove import Tabs from '../../components/ui/Tabs';
import Icons from '../../components/ui/Icons';
</s> add import Guide from '../../components/ui/Guide';
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/components/Header/Version.js
|
keep keep keep keep replace replace replace replace replace keep keep keep keep keep
|
<mask> isMenuOpen={isMenuOpen}
<mask> toggleMenuOpen={this.toggleMenuOpen}
<mask> closeMenu={this.closeMenu}
<mask> />
<mask> <div className="col col-sm-6 col-lg-3">
<mask> <Version
<mask> { ...this.props.dashboard }
<mask> />
<mask> </div>
<mask> </div>
<mask> </div>
<mask> </div>
<mask> );
<mask> }
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> remove <Icons />
<Tabs>
<div label="Router">
<div className="tab__title">
<Trans>install_devices_router</Trans>
</div>
<div className="tab__text">
<p><Trans>install_devices_router_desc</Trans></p>
<ol>
<li><Trans>install_devices_router_list_1</Trans></li>
<li><Trans>install_devices_router_list_2</Trans></li>
<li><Trans>install_devices_router_list_3</Trans></li>
</ol>
</div>
</div>
<div label="Windows">
<div className="tab__title">
Windows
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_windows_list_1</Trans></li>
<li><Trans>install_devices_windows_list_2</Trans></li>
<li><Trans>install_devices_windows_list_3</Trans></li>
<li><Trans>install_devices_windows_list_4</Trans></li>
<li><Trans>install_devices_windows_list_5</Trans></li>
<li><Trans>install_devices_windows_list_6</Trans></li>
</ol>
</div>
</div>
<div label="macOS">
<div className="tab__title">
macOS
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_macos_list_1</Trans></li>
<li><Trans>install_devices_macos_list_2</Trans></li>
<li><Trans>install_devices_macos_list_3</Trans></li>
<li><Trans>install_devices_macos_list_4</Trans></li>
</ol>
</div>
</div>
<div label="Android">
<div className="tab__title">
Android
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_android_list_1</Trans></li>
<li><Trans>install_devices_android_list_2</Trans></li>
<li><Trans>install_devices_android_list_3</Trans></li>
<li><Trans>install_devices_android_list_4</Trans></li>
<li><Trans>install_devices_android_list_5</Trans></li>
</ol>
</div>
</div>
<div label="iOS">
<div className="tab__title">
iOS
</div>
<div className="tab__text">
<ol>
<li><Trans>install_devices_ios_list_1</Trans></li>
<li><Trans>install_devices_ios_list_2</Trans></li>
<li><Trans>install_devices_ios_list_3</Trans></li>
<li><Trans>install_devices_ios_list_4</Trans></li>
</ol>
</div>
</div>
</Tabs>
</s> add <Guide /> </s> add <Route path="/guide" component={SetupGuide} /> </s> remove <div className="nav-version__text">
<Trans>address</Trans>: <span className="nav-version__value">{dnsAddress}:{dnsPort}</span>
</s> add <div className="nav-version__link">
<div className="popover__trigger popover__trigger--address">
<Trans>dns_addresses</Trans>
</div>
<div className="popover__body popover__body--address">
<div className="popover__list">
{dnsAddresses
.map(ip => <li key={ip}>{getDnsAddress(ip, dnsPort)}</li>)
}
</div>
</div> </s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> add import { getDnsAddress } from '../../helpers/helpers';
</s> remove <Trans>faq</Trans>
</a>
</s> add <Trans>setup_guide</Trans>
</NavLink>
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/components/Header/index.js
|
keep add keep keep keep keep keep keep
|
<mask> }
<mask>
<mask> .popover__body {
<mask> content: "";
<mask> display: flex;
<mask> position: absolute;
<mask> bottom: calc(100% + 3px);
<mask> left: 50%;
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> add .nav-version__link {
position: relative;
display: inline-block;
border-bottom: 1px dashed #495057;
cursor: pointer;
}
</s> add .popover__list--bold {
font-weight: 700;
}
</s> add import { getDnsAddress } from '../../helpers/helpers';
</s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> remove <div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
</s> add {!dashboard.processing &&
<div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
} </s> remove import { REPOSITORY } from '../../helpers/constants';
</s> add
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/components/ui/Popover.css
|
keep keep add keep keep keep keep keep keep
|
<mask> stroke: #66b574;
<mask> }
<mask>
<mask> .popover__list-title {
<mask> margin-bottom: 3px;
<mask> }
<mask>
<mask> .popover__list-item {
<mask> margin-bottom: 2px;
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> add import { getDnsAddress } from '../../helpers/helpers';
</s> add .nav-version__link {
position: relative;
display: inline-block;
border-bottom: 1px dashed #495057;
cursor: pointer;
}
</s> add .popover__trigger--address {
top: 0;
margin: 0;
line-height: 1.2;
}
.popover__trigger--address:after {
display: none;
}
</s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> remove <div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
</s> add {!dashboard.processing &&
<div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
} </s> remove import { REPOSITORY } from '../../helpers/constants';
</s> add
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/components/ui/Popover.css
|
keep keep keep keep replace replace keep keep keep keep keep
|
<mask> import { reduxForm, formValueSelector } from 'redux-form';
<mask> import { Trans, withNamespaces } from 'react-i18next';
<mask> import flow from 'lodash/flow';
<mask>
<mask> import Tabs from '../../components/ui/Tabs';
<mask> import Icons from '../../components/ui/Icons';
<mask> import Controls from './Controls';
<mask> import AddressList from './AddressList';
<mask>
<mask> let Devices = props => (
<mask> <div className="setup__step">
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> remove import { REPOSITORY } from '../../helpers/constants';
</s> add </s> add import { getDnsAddress } from '../../helpers/helpers';
</s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> add import Footer from '../ui/Footer'; </s> remove import Footer from '../ui/Footer';
</s> add import SetupGuide from '../../containers/SetupGuide'; </s> remove <div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
</s> add {!dashboard.processing &&
<div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
}
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/install/Setup/Devices.js
|
keep keep keep keep replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace keep keep keep keep keep
|
<mask> isDns={true}
<mask> />
<mask> </div>
<mask> </div>
<mask> <Icons />
<mask> <Tabs>
<mask> <div label="Router">
<mask> <div className="tab__title">
<mask> <Trans>install_devices_router</Trans>
<mask> </div>
<mask> <div className="tab__text">
<mask> <p><Trans>install_devices_router_desc</Trans></p>
<mask> <ol>
<mask> <li><Trans>install_devices_router_list_1</Trans></li>
<mask> <li><Trans>install_devices_router_list_2</Trans></li>
<mask> <li><Trans>install_devices_router_list_3</Trans></li>
<mask> </ol>
<mask> </div>
<mask> </div>
<mask> <div label="Windows">
<mask> <div className="tab__title">
<mask> Windows
<mask> </div>
<mask> <div className="tab__text">
<mask> <ol>
<mask> <li><Trans>install_devices_windows_list_1</Trans></li>
<mask> <li><Trans>install_devices_windows_list_2</Trans></li>
<mask> <li><Trans>install_devices_windows_list_3</Trans></li>
<mask> <li><Trans>install_devices_windows_list_4</Trans></li>
<mask> <li><Trans>install_devices_windows_list_5</Trans></li>
<mask> <li><Trans>install_devices_windows_list_6</Trans></li>
<mask> </ol>
<mask> </div>
<mask> </div>
<mask> <div label="macOS">
<mask> <div className="tab__title">
<mask> macOS
<mask> </div>
<mask> <div className="tab__text">
<mask> <ol>
<mask> <li><Trans>install_devices_macos_list_1</Trans></li>
<mask> <li><Trans>install_devices_macos_list_2</Trans></li>
<mask> <li><Trans>install_devices_macos_list_3</Trans></li>
<mask> <li><Trans>install_devices_macos_list_4</Trans></li>
<mask> </ol>
<mask> </div>
<mask> </div>
<mask> <div label="Android">
<mask> <div className="tab__title">
<mask> Android
<mask> </div>
<mask> <div className="tab__text">
<mask> <ol>
<mask> <li><Trans>install_devices_android_list_1</Trans></li>
<mask> <li><Trans>install_devices_android_list_2</Trans></li>
<mask> <li><Trans>install_devices_android_list_3</Trans></li>
<mask> <li><Trans>install_devices_android_list_4</Trans></li>
<mask> <li><Trans>install_devices_android_list_5</Trans></li>
<mask> </ol>
<mask> </div>
<mask> </div>
<mask> <div label="iOS">
<mask> <div className="tab__title">
<mask> iOS
<mask> </div>
<mask> <div className="tab__text">
<mask> <ol>
<mask> <li><Trans>install_devices_ios_list_1</Trans></li>
<mask> <li><Trans>install_devices_ios_list_2</Trans></li>
<mask> <li><Trans>install_devices_ios_list_3</Trans></li>
<mask> <li><Trans>install_devices_ios_list_4</Trans></li>
<mask> </ol>
<mask> </div>
<mask> </div>
<mask> </Tabs>
<mask> </div>
<mask> <Controls />
<mask> </div>
<mask> );
<mask>
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> remove <div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
</s> add {!dashboard.processing &&
<div className="col col-sm-6 col-lg-3">
<Version
{ ...this.props.dashboard }
/>
</div>
} </s> remove <div className="nav-version__text">
<Trans>address</Trans>: <span className="nav-version__value">{dnsAddress}:{dnsPort}</span>
</s> add <div className="nav-version__link">
<div className="popover__trigger popover__trigger--address">
<Trans>dns_addresses</Trans>
</div>
<div className="popover__body popover__body--address">
<div className="popover__list">
{dnsAddresses
.map(ip => <li key={ip}>{getDnsAddress(ip, dnsPort)}</li>)
}
</div>
</div> </s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> add <Route path="/guide" component={SetupGuide} /> </s> remove <Trans>faq</Trans>
</a>
</s> add <Trans>setup_guide</Trans>
</NavLink> </s> add import { getDnsAddress } from '../../helpers/helpers';
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/install/Setup/Devices.js
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> const {
<mask> version,
<mask> running,
<mask> dns_port: dnsPort,
<mask> dns_address: dnsAddress,
<mask> querylog_enabled: queryLogEnabled,
<mask> upstream_dns: upstreamDns,
<mask> bootstrap_dns: bootstrapDns,
<mask> all_servers: allServers,
<mask> protection_enabled: protectionEnabled,
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> remove dnsAddress,
</s> add dnsAddresses, </s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> add import { getDnsAddress } from '../../helpers/helpers';
</s> add dnsPort: 53,
dnsAddresses: [],
dnsVersion: '', </s> add .popover__list--bold {
font-weight: 700;
}
</s> remove import { REPOSITORY } from '../../helpers/constants';
</s> add
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/reducers/index.js
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> isCoreRunning: running,
<mask> processing: false,
<mask> dnsVersion: version,
<mask> dnsPort,
<mask> dnsAddress,
<mask> queryLogEnabled,
<mask> upstreamDns: upstreamDns.join('\n'),
<mask> bootstrapDns: bootstrapDns.join('\n'),
<mask> allServers,
<mask> protectionEnabled,
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> remove dns_address: dnsAddress,
</s> add dns_addresses: dnsAddresses, </s> add dnsPort: 53,
dnsAddresses: [],
dnsVersion: '', </s> remove dnsVersion: PropTypes.string,
dnsAddress: PropTypes.string,
dnsPort: PropTypes.number,
</s> add dnsVersion: PropTypes.string.isRequired,
dnsAddresses: PropTypes.array.isRequired,
dnsPort: PropTypes.number.isRequired, </s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> add .popover__list--bold {
font-weight: 700;
}
</s> add .popover__trigger--address {
top: 0;
margin: 0;
line-height: 1.2;
}
.popover__trigger--address:after {
display: none;
}
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/reducers/index.js
|
keep add keep keep keep keep keep keep
|
<mask> processingProtection: false,
<mask> httpPort: 80,
<mask> });
<mask>
<mask> const queryLogs = handleActions({
<mask> [actions.getLogsRequest]: state => ({ ...state, getLogsProcessing: true }),
<mask> [actions.getLogsFailure]: state => ({ ...state, getLogsProcessing: false }),
<mask> [actions.getLogsSuccess]: (state, { payload }) => {
</s> + client: added setup guide page and DNS addresses popover
Closes #605 </s> remove import { REPOSITORY } from '../../helpers/constants';
</s> add </s> remove import Tabs from '../../components/ui/Tabs';
import Icons from '../../components/ui/Icons';
</s> add import Guide from '../../components/ui/Guide'; </s> remove const { dnsVersion, dnsAddress, dnsPort } = props;
</s> add const { dnsVersion, dnsAddresses, dnsPort } = props; </s> add import { getDnsAddress } from '../../helpers/helpers';
</s> remove <div className="nav-version__text">
<Trans>address</Trans>: <span className="nav-version__value">{dnsAddress}:{dnsPort}</span>
</s> add <div className="nav-version__link">
<div className="popover__trigger popover__trigger--address">
<Trans>dns_addresses</Trans>
</div>
<div className="popover__body popover__body--address">
<div className="popover__list">
{dnsAddresses
.map(ip => <li key={ip}>{getDnsAddress(ip, dnsPort)}</li>)
}
</div>
</div> </s> remove dns_address: dnsAddress,
</s> add dns_addresses: dnsAddresses,
|
https://github.com/AdguardTeam/AdGuardHome/commit/756c5ac0d3c9b685f95cc755ad098cef74e0c517
|
client/src/reducers/index.js
|
keep keep keep replace keep keep keep keep replace keep
|
<mask>
<mask> class Clients extends Component {
<mask> render() {
<mask> const { dashboard, clients, t } = this.props;
<mask>
<mask> return (
<mask> <Fragment>
<mask> <PageTitle title={t('clients_settings')} />
<mask> {!dashboard.processingTopStats || (!dashboard.processingClients && <Loading />)}
<mask> {!dashboard.processingTopStats && !dashboard.processingClients && (
</s> * client: move access settings to DNS settings page </s> remove return (
<Fragment>
<PageTitle title={t('dns_settings')} />
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
setUpstream={props.setUpstream}
testUpstream={props.testUpstream}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
/>
</Fragment>
);
};
</s> add render() {
const {
t,
dashboard,
settings,
access,
setAccessList,
testUpstream,
setUpstream,
} = this.props;
return (
<Fragment>
<PageTitle title={t('dns_settings')} />
{(dashboard.processing || access.processing) && <Loading />}
{!dashboard.processing && !access.processing && (
<Fragment>
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
setUpstream={setUpstream}
testUpstream={testUpstream}
/>
<Access access={access} setAccessList={setAccessList} />
</Fragment>
)}
</Fragment>
);
}
} </s> remove const Dns = (props) => {
const { dashboard, settings, t } = props;
</s> add class Dns extends Component {
componentDidMount() {
this.props.getAccessList();
} </s> add import Loading from '../../ui/Loading'; </s> add import Access from './Access'; </s> remove dashboard,
dhcp,
encryption,
clients,
access,
</s> add
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/components/Settings/Clients/index.js
|
keep keep keep keep replace replace replace replace keep keep keep keep keep
|
<mask> topStats={dashboard.topStats}
<mask> isModalOpen={clients.isModalOpen}
<mask> modalClientName={clients.modalClientName}
<mask> modalType={clients.modalType}
<mask> addClient={this.props.addClient}
<mask> updateClient={this.props.updateClient}
<mask> deleteClient={this.props.deleteClient}
<mask> toggleClientModal={this.props.toggleClientModal}
<mask> processingAdding={clients.processingAdding}
<mask> processingDeleting={clients.processingDeleting}
<mask> processingUpdating={clients.processingUpdating}
<mask> />
<mask> <AutoClients
</s> * client: move access settings to DNS settings page </s> remove {!dashboard.processingTopStats || (!dashboard.processingClients && <Loading />)}
</s> add {(dashboard.processingTopStats || dashboard.processingClients) && <Loading />} </s> remove return (
<Fragment>
<PageTitle title={t('dns_settings')} />
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
setUpstream={props.setUpstream}
testUpstream={props.testUpstream}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
/>
</Fragment>
);
};
</s> add render() {
const {
t,
dashboard,
settings,
access,
setAccessList,
testUpstream,
setUpstream,
} = this.props;
return (
<Fragment>
<PageTitle title={t('dns_settings')} />
{(dashboard.processing || access.processing) && <Loading />}
{!dashboard.processing && !access.processing && (
<Fragment>
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
setUpstream={setUpstream}
testUpstream={testUpstream}
/>
<Access access={access} setAccessList={setAccessList} />
</Fragment>
)}
</Fragment>
);
}
} </s> remove const Dns = (props) => {
const { dashboard, settings, t } = props;
</s> add class Dns extends Component {
componentDidMount() {
this.props.getAccessList();
} </s> remove const { dashboard, clients, t } = this.props;
</s> add const {
t,
dashboard,
clients,
addClient,
updateClient,
deleteClient,
toggleClientModal,
} = this.props; </s> remove clients: PropTypes.array.isRequired,
topStats: PropTypes.object.isRequired,
</s> add clients: PropTypes.object.isRequired, </s> remove isModalOpen: PropTypes.bool.isRequired,
modalType: PropTypes.string.isRequired,
modalClientName: PropTypes.string.isRequired,
processingAdding: PropTypes.bool.isRequired,
processingDeleting: PropTypes.bool.isRequired,
processingUpdating: PropTypes.bool.isRequired,
</s> add topStats: PropTypes.object,
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/components/Settings/Clients/index.js
|
keep keep replace replace keep keep keep keep replace replace replace replace replace replace keep keep
|
<mask> t: PropTypes.func.isRequired,
<mask> dashboard: PropTypes.object.isRequired,
<mask> clients: PropTypes.array.isRequired,
<mask> topStats: PropTypes.object.isRequired,
<mask> toggleClientModal: PropTypes.func.isRequired,
<mask> deleteClient: PropTypes.func.isRequired,
<mask> addClient: PropTypes.func.isRequired,
<mask> updateClient: PropTypes.func.isRequired,
<mask> isModalOpen: PropTypes.bool.isRequired,
<mask> modalType: PropTypes.string.isRequired,
<mask> modalClientName: PropTypes.string.isRequired,
<mask> processingAdding: PropTypes.bool.isRequired,
<mask> processingDeleting: PropTypes.bool.isRequired,
<mask> processingUpdating: PropTypes.bool.isRequired,
<mask> };
<mask>
</s> * client: move access settings to DNS settings page </s> add getAccessList: PropTypes.func.isRequired,
setAccessList: PropTypes.func.isRequired,
access: PropTypes.object.isRequired, </s> remove return (
<Fragment>
<PageTitle title={t('dns_settings')} />
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
setUpstream={props.setUpstream}
testUpstream={props.testUpstream}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
/>
</Fragment>
);
};
</s> add render() {
const {
t,
dashboard,
settings,
access,
setAccessList,
testUpstream,
setUpstream,
} = this.props;
return (
<Fragment>
<PageTitle title={t('dns_settings')} />
{(dashboard.processing || access.processing) && <Loading />}
{!dashboard.processing && !access.processing && (
<Fragment>
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
setUpstream={setUpstream}
testUpstream={testUpstream}
/>
<Access access={access} setAccessList={setAccessList} />
</Fragment>
)}
</Fragment>
);
}
} </s> add access, </s> remove dashboard,
dhcp,
encryption,
clients,
access,
</s> add </s> add getAccessList,
setAccessList,
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/components/Settings/Clients/index.js
|
replace keep keep keep keep keep
|
<mask> import React, { Fragment } from 'react';
<mask> import PropTypes from 'prop-types';
<mask> import { withNamespaces } from 'react-i18next';
<mask>
<mask> import Upstream from './Upstream';
<mask> import PageTitle from '../../ui/PageTitle';
</s> * client: move access settings to DNS settings page </s> add import Access from './Access'; </s> add import Loading from '../../ui/Loading'; </s> remove const Dns = (props) => {
const { dashboard, settings, t } = props;
</s> add class Dns extends Component {
componentDidMount() {
this.props.getAccessList();
} </s> remove import {
initSettings,
toggleSetting,
handleUpstreamChange,
setUpstream,
testUpstream,
addErrorToast,
toggleDhcp,
getDhcpStatus,
getDhcpInterfaces,
setDhcpConfig,
findActiveDhcp,
addStaticLease,
removeStaticLease,
toggleLeaseModal,
} from '../actions';
import {
getTlsStatus,
setTlsConfig,
validateTlsConfig,
} from '../actions/encryption';
import {
addClient,
updateClient,
deleteClient,
toggleClientModal,
} from '../actions/clients';
import {
getAccessList,
setAccessList,
} from '../actions/access';
</s> add import { initSettings, toggleSetting, addErrorToast } from '../actions'; </s> add import { getAccessList, setAccessList } from '../actions/access'; </s> remove const { dashboard, settings } = state;
</s> add const { dashboard, settings, access } = state;
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/components/Settings/Dns/index.js
|
keep keep keep add keep keep keep keep keep
|
<mask> import PropTypes from 'prop-types';
<mask> import { withNamespaces } from 'react-i18next';
<mask>
<mask> import Upstream from './Upstream';
<mask> import PageTitle from '../../ui/PageTitle';
<mask> import Loading from '../../ui/Loading';
<mask>
<mask> class Dns extends Component {
<mask> componentDidMount() {
</s> * client: move access settings to DNS settings page </s> add import Loading from '../../ui/Loading'; </s> remove import React, { Fragment } from 'react';
</s> add import React, { Component, Fragment } from 'react'; </s> remove const Dns = (props) => {
const { dashboard, settings, t } = props;
</s> add class Dns extends Component {
componentDidMount() {
this.props.getAccessList();
} </s> remove const { dashboard, clients, t } = this.props;
</s> add const {
t,
dashboard,
clients,
addClient,
updateClient,
deleteClient,
toggleClientModal,
} = this.props; </s> add import { getAccessList, setAccessList } from '../actions/access'; </s> remove import {
initSettings,
toggleSetting,
handleUpstreamChange,
setUpstream,
testUpstream,
addErrorToast,
toggleDhcp,
getDhcpStatus,
getDhcpInterfaces,
setDhcpConfig,
findActiveDhcp,
addStaticLease,
removeStaticLease,
toggleLeaseModal,
} from '../actions';
import {
getTlsStatus,
setTlsConfig,
validateTlsConfig,
} from '../actions/encryption';
import {
addClient,
updateClient,
deleteClient,
toggleClientModal,
} from '../actions/clients';
import {
getAccessList,
setAccessList,
} from '../actions/access';
</s> add import { initSettings, toggleSetting, addErrorToast } from '../actions';
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/components/Settings/Dns/index.js
|
keep keep add keep keep keep keep
|
<mask> import Upstream from './Upstream';
<mask> import Access from './Access';
<mask> import PageTitle from '../../ui/PageTitle';
<mask>
<mask> class Dns extends Component {
<mask> componentDidMount() {
<mask> this.props.getAccessList();
</s> * client: move access settings to DNS settings page </s> add import Access from './Access'; </s> remove const Dns = (props) => {
const { dashboard, settings, t } = props;
</s> add class Dns extends Component {
componentDidMount() {
this.props.getAccessList();
} </s> remove import React, { Fragment } from 'react';
</s> add import React, { Component, Fragment } from 'react'; </s> remove const { dashboard, clients, t } = this.props;
</s> add const {
t,
dashboard,
clients,
addClient,
updateClient,
deleteClient,
toggleClientModal,
} = this.props; </s> add import { getAccessList, setAccessList } from '../actions/access'; </s> remove import {
initSettings,
toggleSetting,
handleUpstreamChange,
setUpstream,
testUpstream,
addErrorToast,
toggleDhcp,
getDhcpStatus,
getDhcpInterfaces,
setDhcpConfig,
findActiveDhcp,
addStaticLease,
removeStaticLease,
toggleLeaseModal,
} from '../actions';
import {
getTlsStatus,
setTlsConfig,
validateTlsConfig,
} from '../actions/encryption';
import {
addClient,
updateClient,
deleteClient,
toggleClientModal,
} from '../actions/clients';
import {
getAccessList,
setAccessList,
} from '../actions/access';
</s> add import { initSettings, toggleSetting, addErrorToast } from '../actions';
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/components/Settings/Dns/index.js
|
keep keep keep keep replace replace keep keep keep keep keep
|
<mask>
<mask> import Upstream from './Upstream';
<mask> import PageTitle from '../../ui/PageTitle';
<mask>
<mask> const Dns = (props) => {
<mask> const { dashboard, settings, t } = props;
<mask>
<mask> return (
<mask> <Fragment>
<mask> <PageTitle title={t('dns_settings')} />
<mask> <Upstream
</s> * client: move access settings to DNS settings page </s> remove return (
<Fragment>
<PageTitle title={t('dns_settings')} />
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
setUpstream={props.setUpstream}
testUpstream={props.testUpstream}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
/>
</Fragment>
);
};
</s> add render() {
const {
t,
dashboard,
settings,
access,
setAccessList,
testUpstream,
setUpstream,
} = this.props;
return (
<Fragment>
<PageTitle title={t('dns_settings')} />
{(dashboard.processing || access.processing) && <Loading />}
{!dashboard.processing && !access.processing && (
<Fragment>
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
setUpstream={setUpstream}
testUpstream={testUpstream}
/>
<Access access={access} setAccessList={setAccessList} />
</Fragment>
)}
</Fragment>
);
}
} </s> remove const { dashboard, clients, t } = this.props;
</s> add const {
t,
dashboard,
clients,
addClient,
updateClient,
deleteClient,
toggleClientModal,
} = this.props; </s> add import Loading from '../../ui/Loading'; </s> add import Access from './Access'; </s> remove const { dashboard, settings } = state;
</s> add const { dashboard, settings, access } = state; </s> remove import React, { Fragment } from 'react';
</s> add import React, { Component, Fragment } from 'react';
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/components/Settings/Dns/index.js
|
keep keep keep keep replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace keep keep keep keep keep
|
<mask>
<mask> const Dns = (props) => {
<mask> const { dashboard, settings, t } = props;
<mask>
<mask> return (
<mask> <Fragment>
<mask> <PageTitle title={t('dns_settings')} />
<mask> <Upstream
<mask> upstreamDns={dashboard.upstreamDns}
<mask> bootstrapDns={dashboard.bootstrapDns}
<mask> allServers={dashboard.allServers}
<mask> setUpstream={props.setUpstream}
<mask> testUpstream={props.testUpstream}
<mask> processingTestUpstream={settings.processingTestUpstream}
<mask> processingSetUpstream={settings.processingSetUpstream}
<mask> />
<mask> </Fragment>
<mask> );
<mask> };
<mask>
<mask> Dns.propTypes = {
<mask> dashboard: PropTypes.object.isRequired,
<mask> settings: PropTypes.object.isRequired,
<mask> setUpstream: PropTypes.func.isRequired,
</s> * client: move access settings to DNS settings page </s> remove const Dns = (props) => {
const { dashboard, settings, t } = props;
</s> add class Dns extends Component {
componentDidMount() {
this.props.getAccessList();
} </s> remove clients: PropTypes.array.isRequired,
topStats: PropTypes.object.isRequired,
</s> add clients: PropTypes.object.isRequired, </s> remove const { dashboard, clients, t } = this.props;
</s> add const {
t,
dashboard,
clients,
addClient,
updateClient,
deleteClient,
toggleClientModal,
} = this.props; </s> add getAccessList: PropTypes.func.isRequired,
setAccessList: PropTypes.func.isRequired,
access: PropTypes.object.isRequired, </s> remove const { dashboard, settings } = state;
</s> add const { dashboard, settings, access } = state; </s> remove dashboard,
dhcp,
encryption,
clients,
access,
</s> add
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/components/Settings/Dns/index.js
|
keep add keep keep keep keep
|
<mask> setUpstream: PropTypes.func.isRequired,
<mask> testUpstream: PropTypes.func.isRequired,
<mask> t: PropTypes.func.isRequired,
<mask> };
<mask>
<mask> export default withNamespaces()(Dns);
</s> * client: move access settings to DNS settings page </s> remove isModalOpen: PropTypes.bool.isRequired,
modalType: PropTypes.string.isRequired,
modalClientName: PropTypes.string.isRequired,
processingAdding: PropTypes.bool.isRequired,
processingDeleting: PropTypes.bool.isRequired,
processingUpdating: PropTypes.bool.isRequired,
</s> add topStats: PropTypes.object, </s> remove clients: PropTypes.array.isRequired,
topStats: PropTypes.object.isRequired,
</s> add clients: PropTypes.object.isRequired, </s> add getAccessList,
setAccessList, </s> remove return (
<Fragment>
<PageTitle title={t('dns_settings')} />
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
setUpstream={props.setUpstream}
testUpstream={props.testUpstream}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
/>
</Fragment>
);
};
</s> add render() {
const {
t,
dashboard,
settings,
access,
setAccessList,
testUpstream,
setUpstream,
} = this.props;
return (
<Fragment>
<PageTitle title={t('dns_settings')} />
{(dashboard.processing || access.processing) && <Loading />}
{!dashboard.processing && !access.processing && (
<Fragment>
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
setUpstream={setUpstream}
testUpstream={testUpstream}
/>
<Access access={access} setAccessList={setAccessList} />
</Fragment>
)}
</Fragment>
);
}
} </s> remove toggleDhcp,
getDhcpStatus,
getDhcpInterfaces,
setDhcpConfig,
findActiveDhcp,
getTlsStatus,
setTlsConfig,
validateTlsConfig,
addClient,
updateClient,
deleteClient,
toggleClientModal,
addStaticLease,
removeStaticLease,
toggleLeaseModal,
getAccessList,
setAccessList,
</s> add </s> add access,
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/components/Settings/Dns/index.js
|
keep add keep keep keep keep
|
<mask> import { connect } from 'react-redux';
<mask> import { handleUpstreamChange, setUpstream, testUpstream, addErrorToast } from '../actions';
<mask> import Dns from '../components/Settings/Dns';
<mask>
<mask> const mapStateToProps = (state) => {
<mask> const { dashboard, settings, access } = state;
</s> * client: move access settings to DNS settings page </s> remove const { dashboard, settings } = state;
</s> add const { dashboard, settings, access } = state; </s> remove import {
initSettings,
toggleSetting,
handleUpstreamChange,
setUpstream,
testUpstream,
addErrorToast,
toggleDhcp,
getDhcpStatus,
getDhcpInterfaces,
setDhcpConfig,
findActiveDhcp,
addStaticLease,
removeStaticLease,
toggleLeaseModal,
} from '../actions';
import {
getTlsStatus,
setTlsConfig,
validateTlsConfig,
} from '../actions/encryption';
import {
addClient,
updateClient,
deleteClient,
toggleClientModal,
} from '../actions/clients';
import {
getAccessList,
setAccessList,
} from '../actions/access';
</s> add import { initSettings, toggleSetting, addErrorToast } from '../actions'; </s> remove const {
settings,
dashboard,
dhcp,
encryption,
clients,
access,
} = state;
</s> add const { settings } = state; </s> remove const Dns = (props) => {
const { dashboard, settings, t } = props;
</s> add class Dns extends Component {
componentDidMount() {
this.props.getAccessList();
} </s> remove dashboard,
dhcp,
encryption,
clients,
access,
</s> add </s> add import Access from './Access';
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/containers/Dns.js
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> import { handleUpstreamChange, setUpstream, testUpstream, addErrorToast } from '../actions';
<mask> import Dns from '../components/Settings/Dns';
<mask>
<mask> const mapStateToProps = (state) => {
<mask> const { dashboard, settings } = state;
<mask> const props = {
<mask> dashboard,
<mask> settings,
<mask> };
<mask> return props;
</s> * client: move access settings to DNS settings page </s> add import { getAccessList, setAccessList } from '../actions/access'; </s> remove const {
settings,
dashboard,
dhcp,
encryption,
clients,
access,
} = state;
</s> add const { settings } = state; </s> remove import {
initSettings,
toggleSetting,
handleUpstreamChange,
setUpstream,
testUpstream,
addErrorToast,
toggleDhcp,
getDhcpStatus,
getDhcpInterfaces,
setDhcpConfig,
findActiveDhcp,
addStaticLease,
removeStaticLease,
toggleLeaseModal,
} from '../actions';
import {
getTlsStatus,
setTlsConfig,
validateTlsConfig,
} from '../actions/encryption';
import {
addClient,
updateClient,
deleteClient,
toggleClientModal,
} from '../actions/clients';
import {
getAccessList,
setAccessList,
} from '../actions/access';
</s> add import { initSettings, toggleSetting, addErrorToast } from '../actions'; </s> remove dashboard,
dhcp,
encryption,
clients,
access,
</s> add </s> remove const Dns = (props) => {
const { dashboard, settings, t } = props;
</s> add class Dns extends Component {
componentDidMount() {
this.props.getAccessList();
} </s> add access,
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/containers/Dns.js
|
keep add keep keep keep keep keep keep
|
<mask> dashboard,
<mask> settings,
<mask> };
<mask> return props;
<mask> };
<mask>
<mask> const mapDispatchToProps = {
<mask> handleUpstreamChange,
</s> * client: move access settings to DNS settings page </s> remove dashboard,
dhcp,
encryption,
clients,
access,
</s> add </s> remove const { dashboard, settings } = state;
</s> add const { dashboard, settings, access } = state; </s> remove handleUpstreamChange,
setUpstream,
testUpstream,
</s> add </s> remove const Dns = (props) => {
const { dashboard, settings, t } = props;
</s> add class Dns extends Component {
componentDidMount() {
this.props.getAccessList();
} </s> remove return (
<Fragment>
<PageTitle title={t('dns_settings')} />
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
setUpstream={props.setUpstream}
testUpstream={props.testUpstream}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
/>
</Fragment>
);
};
</s> add render() {
const {
t,
dashboard,
settings,
access,
setAccessList,
testUpstream,
setUpstream,
} = this.props;
return (
<Fragment>
<PageTitle title={t('dns_settings')} />
{(dashboard.processing || access.processing) && <Loading />}
{!dashboard.processing && !access.processing && (
<Fragment>
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
setUpstream={setUpstream}
testUpstream={testUpstream}
/>
<Access access={access} setAccessList={setAccessList} />
</Fragment>
)}
</Fragment>
);
}
} </s> add import { getAccessList, setAccessList } from '../actions/access';
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/containers/Dns.js
|
keep keep add keep keep keep keep
|
<mask> setUpstream,
<mask> testUpstream,
<mask> addErrorToast,
<mask> };
<mask>
<mask> export default connect(
<mask> mapStateToProps,
</s> * client: move access settings to DNS settings page </s> remove toggleDhcp,
getDhcpStatus,
getDhcpInterfaces,
setDhcpConfig,
findActiveDhcp,
getTlsStatus,
setTlsConfig,
validateTlsConfig,
addClient,
updateClient,
deleteClient,
toggleClientModal,
addStaticLease,
removeStaticLease,
toggleLeaseModal,
getAccessList,
setAccessList,
</s> add </s> add getAccessList: PropTypes.func.isRequired,
setAccessList: PropTypes.func.isRequired,
access: PropTypes.object.isRequired, </s> remove handleUpstreamChange,
setUpstream,
testUpstream,
</s> add </s> remove isModalOpen: PropTypes.bool.isRequired,
modalType: PropTypes.string.isRequired,
modalClientName: PropTypes.string.isRequired,
processingAdding: PropTypes.bool.isRequired,
processingDeleting: PropTypes.bool.isRequired,
processingUpdating: PropTypes.bool.isRequired,
</s> add topStats: PropTypes.object, </s> remove import {
initSettings,
toggleSetting,
handleUpstreamChange,
setUpstream,
testUpstream,
addErrorToast,
toggleDhcp,
getDhcpStatus,
getDhcpInterfaces,
setDhcpConfig,
findActiveDhcp,
addStaticLease,
removeStaticLease,
toggleLeaseModal,
} from '../actions';
import {
getTlsStatus,
setTlsConfig,
validateTlsConfig,
} from '../actions/encryption';
import {
addClient,
updateClient,
deleteClient,
toggleClientModal,
} from '../actions/clients';
import {
getAccessList,
setAccessList,
} from '../actions/access';
</s> add import { initSettings, toggleSetting, addErrorToast } from '../actions'; </s> remove const { dashboard, settings } = state;
</s> add const { dashboard, settings, access } = state;
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/containers/Dns.js
|
keep replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace keep keep keep replace replace replace replace replace replace replace replace keep keep keep keep
|
<mask> import { connect } from 'react-redux';
<mask> import {
<mask> initSettings,
<mask> toggleSetting,
<mask> handleUpstreamChange,
<mask> setUpstream,
<mask> testUpstream,
<mask> addErrorToast,
<mask> toggleDhcp,
<mask> getDhcpStatus,
<mask> getDhcpInterfaces,
<mask> setDhcpConfig,
<mask> findActiveDhcp,
<mask> addStaticLease,
<mask> removeStaticLease,
<mask> toggleLeaseModal,
<mask> } from '../actions';
<mask> import {
<mask> getTlsStatus,
<mask> setTlsConfig,
<mask> validateTlsConfig,
<mask> } from '../actions/encryption';
<mask> import {
<mask> addClient,
<mask> updateClient,
<mask> deleteClient,
<mask> toggleClientModal,
<mask> } from '../actions/clients';
<mask> import {
<mask> getAccessList,
<mask> setAccessList,
<mask> } from '../actions/access';
<mask> import Settings from '../components/Settings';
<mask>
<mask> const mapStateToProps = (state) => {
<mask> const {
<mask> settings,
<mask> dashboard,
<mask> dhcp,
<mask> encryption,
<mask> clients,
<mask> access,
<mask> } = state;
<mask> const props = {
<mask> settings,
<mask> dashboard,
<mask> dhcp,
</s> * client: move access settings to DNS settings page </s> remove toggleDhcp,
getDhcpStatus,
getDhcpInterfaces,
setDhcpConfig,
findActiveDhcp,
getTlsStatus,
setTlsConfig,
validateTlsConfig,
addClient,
updateClient,
deleteClient,
toggleClientModal,
addStaticLease,
removeStaticLease,
toggleLeaseModal,
getAccessList,
setAccessList,
</s> add </s> add import { getAccessList, setAccessList } from '../actions/access'; </s> remove const { dashboard, settings } = state;
</s> add const { dashboard, settings, access } = state; </s> remove dashboard,
dhcp,
encryption,
clients,
access,
</s> add </s> remove handleUpstreamChange,
setUpstream,
testUpstream,
</s> add
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/containers/Settings.js
|
keep keep keep keep replace replace replace replace replace keep keep keep keep keep
|
<mask> access,
<mask> } = state;
<mask> const props = {
<mask> settings,
<mask> dashboard,
<mask> dhcp,
<mask> encryption,
<mask> clients,
<mask> access,
<mask> };
<mask> return props;
<mask> };
<mask>
<mask> const mapDispatchToProps = {
</s> * client: move access settings to DNS settings page </s> remove const {
settings,
dashboard,
dhcp,
encryption,
clients,
access,
} = state;
</s> add const { settings } = state; </s> add access, </s> remove const { dashboard, settings } = state;
</s> add const { dashboard, settings, access } = state; </s> remove return (
<Fragment>
<PageTitle title={t('dns_settings')} />
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
setUpstream={props.setUpstream}
testUpstream={props.testUpstream}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
/>
</Fragment>
);
};
</s> add render() {
const {
t,
dashboard,
settings,
access,
setAccessList,
testUpstream,
setUpstream,
} = this.props;
return (
<Fragment>
<PageTitle title={t('dns_settings')} />
{(dashboard.processing || access.processing) && <Loading />}
{!dashboard.processing && !access.processing && (
<Fragment>
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
setUpstream={setUpstream}
testUpstream={testUpstream}
/>
<Access access={access} setAccessList={setAccessList} />
</Fragment>
)}
</Fragment>
);
}
} </s> remove const { dashboard, clients, t } = this.props;
</s> add const {
t,
dashboard,
clients,
addClient,
updateClient,
deleteClient,
toggleClientModal,
} = this.props; </s> remove const Dns = (props) => {
const { dashboard, settings, t } = props;
</s> add class Dns extends Component {
componentDidMount() {
this.props.getAccessList();
}
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/containers/Settings.js
|
keep keep replace replace replace keep replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace keep keep
|
<mask> initSettings,
<mask> toggleSetting,
<mask> handleUpstreamChange,
<mask> setUpstream,
<mask> testUpstream,
<mask> addErrorToast,
<mask> toggleDhcp,
<mask> getDhcpStatus,
<mask> getDhcpInterfaces,
<mask> setDhcpConfig,
<mask> findActiveDhcp,
<mask> getTlsStatus,
<mask> setTlsConfig,
<mask> validateTlsConfig,
<mask> addClient,
<mask> updateClient,
<mask> deleteClient,
<mask> toggleClientModal,
<mask> addStaticLease,
<mask> removeStaticLease,
<mask> toggleLeaseModal,
<mask> getAccessList,
<mask> setAccessList,
<mask> };
<mask>
</s> * client: move access settings to DNS settings page </s> remove import {
initSettings,
toggleSetting,
handleUpstreamChange,
setUpstream,
testUpstream,
addErrorToast,
toggleDhcp,
getDhcpStatus,
getDhcpInterfaces,
setDhcpConfig,
findActiveDhcp,
addStaticLease,
removeStaticLease,
toggleLeaseModal,
} from '../actions';
import {
getTlsStatus,
setTlsConfig,
validateTlsConfig,
} from '../actions/encryption';
import {
addClient,
updateClient,
deleteClient,
toggleClientModal,
} from '../actions/clients';
import {
getAccessList,
setAccessList,
} from '../actions/access';
</s> add import { initSettings, toggleSetting, addErrorToast } from '../actions'; </s> add getAccessList,
setAccessList, </s> remove const { dashboard, clients, t } = this.props;
</s> add const {
t,
dashboard,
clients,
addClient,
updateClient,
deleteClient,
toggleClientModal,
} = this.props; </s> add import { getAccessList, setAccessList } from '../actions/access'; </s> remove const { dashboard, settings } = state;
</s> add const { dashboard, settings, access } = state;
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/containers/Settings.js
|
keep keep add keep keep keep keep keep keep
|
<mask> allowed_clients: allowed_clients.join('\n'),
<mask> disallowed_clients: disallowed_clients.join('\n'),
<mask> blocked_hosts: blocked_hosts.join('\n'),
<mask> };
<mask> return newState;
<mask> },
<mask>
<mask> [actions.setAccessListRequest]: state => ({ ...state, processingSet: true }),
<mask> [actions.setAccessListFailure]: state => ({ ...state, processingSet: false }),
</s> * client: move access settings to DNS settings page </s> remove const { dashboard, settings } = state;
</s> add const { dashboard, settings, access } = state; </s> remove const Dns = (props) => {
const { dashboard, settings, t } = props;
</s> add class Dns extends Component {
componentDidMount() {
this.props.getAccessList();
} </s> remove return (
<Fragment>
<PageTitle title={t('dns_settings')} />
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
setUpstream={props.setUpstream}
testUpstream={props.testUpstream}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
/>
</Fragment>
);
};
</s> add render() {
const {
t,
dashboard,
settings,
access,
setAccessList,
testUpstream,
setUpstream,
} = this.props;
return (
<Fragment>
<PageTitle title={t('dns_settings')} />
{(dashboard.processing || access.processing) && <Loading />}
{!dashboard.processing && !access.processing && (
<Fragment>
<Upstream
upstreamDns={dashboard.upstreamDns}
bootstrapDns={dashboard.bootstrapDns}
allServers={dashboard.allServers}
processingTestUpstream={settings.processingTestUpstream}
processingSetUpstream={settings.processingSetUpstream}
setUpstream={setUpstream}
testUpstream={testUpstream}
/>
<Access access={access} setAccessList={setAccessList} />
</Fragment>
)}
</Fragment>
);
}
} </s> remove const {
settings,
dashboard,
dhcp,
encryption,
clients,
access,
} = state;
</s> add const { settings } = state; </s> add import { getAccessList, setAccessList } from '../actions/access'; </s> add access,
|
https://github.com/AdguardTeam/AdGuardHome/commit/757bb7285a0afd804d5e26eee29aeecc09d8662e
|
client/src/reducers/access.js
|
keep keep add keep keep keep keep keep keep
|
<mask> queryLog querylog.QueryLog // Query log instance
<mask> stats stats.Stats
<mask>
<mask> AllowedClients map[string]bool // IP addresses of whitelist clients
<mask> DisallowedClients map[string]bool // IP addresses of clients that should be blocked
<mask> AllowedClientsIPNet []net.IPNet // CIDRs of whitelist clients
<mask> DisallowedClientsIPNet []net.IPNet // CIDRs of clients that should be blocked
<mask> BlockedHosts map[string]bool // hosts that should be blocked
<mask>
</s> * dnsforward: create dnsfilter asynchronously </s> add type dnsfilterCreatorParams struct {
conf dnsfilter.Config
filters map[int]string
}
</s> add // Create dnsfilter asynchronously.
// Requests won't be filtered until dnsfilter is created.
// If "restart" command is received while we're creating an old dnsfilter object,
// we delay creation of the new object until the old one is created.
AsyncStartup bool
</s> remove s.dnsFilter = dnsfilter.New(&s.conf.Config, filters)
if s.dnsFilter == nil {
return fmt.Errorf("could not initialize dnsfilter")
</s> add if s.conf.AsyncStartup {
params := dnsfilterCreatorParams{
conf: s.conf.Config,
filters: filters,
}
s.startCounter++
if s.startCounter == 1 {
s.dnsfilterCreatorChan = make(chan dnsfilterCreatorParams, 1)
go s.dnsfilterCreator()
}
// remove all pending tasks
stop := false
for !stop {
select {
case <-s.dnsfilterCreatorChan:
//
default:
stop = true
}
}
s.dnsfilterCreatorChan <- params
} else {
log.Debug("creating dnsfilter...")
f := dnsfilter.New(&s.conf.Config, filters)
if f == nil {
return fmt.Errorf("could not initialize dnsfilter")
}
log.Debug("created dnsfilter")
s.dnsFilter = f </s> remove log.Tracef("Creating dnsfilter")
</s> add </s> add newconfig.AsyncStartup = true
|
https://github.com/AdguardTeam/AdGuardHome/commit/75b864f25ec5f762d6cbfc07d3dce7d77ca0629c
|
dnsforward/dnsforward.go
|
keep keep add keep keep keep keep keep keep
|
<mask> conf ServerConfig
<mask> }
<mask>
<mask> // NewServer creates a new instance of the dnsforward.Server
<mask> // Note: this function must be called only once
<mask> func NewServer(stats stats.Stats, queryLog querylog.QueryLog) *Server {
<mask> s := &Server{}
<mask> s.stats = stats
<mask> s.queryLog = queryLog
</s> * dnsforward: create dnsfilter asynchronously </s> add // How many times the server was started
// While creating a dnsfilter object,
// we use this value to set s.dnsFilter property only with the most recent settings.
startCounter uint32
dnsfilterCreatorChan chan dnsfilterCreatorParams
</s> remove log.Tracef("Creating dnsfilter")
</s> add </s> remove s.dnsFilter = dnsfilter.New(&s.conf.Config, filters)
if s.dnsFilter == nil {
return fmt.Errorf("could not initialize dnsfilter")
</s> add if s.conf.AsyncStartup {
params := dnsfilterCreatorParams{
conf: s.conf.Config,
filters: filters,
}
s.startCounter++
if s.startCounter == 1 {
s.dnsfilterCreatorChan = make(chan dnsfilterCreatorParams, 1)
go s.dnsfilterCreator()
}
// remove all pending tasks
stop := false
for !stop {
select {
case <-s.dnsfilterCreatorChan:
//
default:
stop = true
}
}
s.dnsfilterCreatorChan <- params
} else {
log.Debug("creating dnsfilter...")
f := dnsfilter.New(&s.conf.Config, filters)
if f == nil {
return fmt.Errorf("could not initialize dnsfilter")
}
log.Debug("created dnsfilter")
s.dnsFilter = f </s> add // Create dnsfilter asynchronously.
// Requests won't be filtered until dnsfilter is created.
// If "restart" command is received while we're creating an old dnsfilter object,
// we delay creation of the new object until the old one is created.
AsyncStartup bool
</s> add newconfig.AsyncStartup = true
|
https://github.com/AdguardTeam/AdGuardHome/commit/75b864f25ec5f762d6cbfc07d3dce7d77ca0629c
|
dnsforward/dnsforward.go
|
keep add keep keep keep keep keep keep
|
<mask> // The zero FilteringConfig is empty and ready for use.
<mask> type FilteringConfig struct {
<mask> ProtectionEnabled bool `yaml:"protection_enabled"` // whether or not use any of dnsfilter features
<mask> FilteringEnabled bool `yaml:"filtering_enabled"` // whether or not use filter lists
<mask> FiltersUpdateIntervalHours uint32 `yaml:"filters_update_interval"` // time period to update filters (in hours)
<mask>
<mask> BlockingMode string `yaml:"blocking_mode"` // mode how to answer filtered requests
<mask> BlockedResponseTTL uint32 `yaml:"blocked_response_ttl"` // if 0, then default is used (3600)
</s> * dnsforward: create dnsfilter asynchronously </s> add // How many times the server was started
// While creating a dnsfilter object,
// we use this value to set s.dnsFilter property only with the most recent settings.
startCounter uint32
dnsfilterCreatorChan chan dnsfilterCreatorParams
</s> remove s.dnsFilter = dnsfilter.New(&s.conf.Config, filters)
if s.dnsFilter == nil {
return fmt.Errorf("could not initialize dnsfilter")
</s> add if s.conf.AsyncStartup {
params := dnsfilterCreatorParams{
conf: s.conf.Config,
filters: filters,
}
s.startCounter++
if s.startCounter == 1 {
s.dnsfilterCreatorChan = make(chan dnsfilterCreatorParams, 1)
go s.dnsfilterCreator()
}
// remove all pending tasks
stop := false
for !stop {
select {
case <-s.dnsfilterCreatorChan:
//
default:
stop = true
}
}
s.dnsfilterCreatorChan <- params
} else {
log.Debug("creating dnsfilter...")
f := dnsfilter.New(&s.conf.Config, filters)
if f == nil {
return fmt.Errorf("could not initialize dnsfilter")
}
log.Debug("created dnsfilter")
s.dnsFilter = f </s> add type dnsfilterCreatorParams struct {
conf dnsfilter.Config
filters map[int]string
}
</s> remove log.Tracef("Creating dnsfilter")
</s> add </s> add newconfig.AsyncStartup = true
|
https://github.com/AdguardTeam/AdGuardHome/commit/75b864f25ec5f762d6cbfc07d3dce7d77ca0629c
|
dnsforward/dnsforward.go
|
keep keep keep keep replace replace keep keep keep keep keep
|
<mask> }
<mask>
<mask> // Initializes the DNS filter
<mask> func (s *Server) initDNSFilter(config *ServerConfig) error {
<mask> log.Tracef("Creating dnsfilter")
<mask>
<mask> if config != nil {
<mask> s.conf = *config
<mask> }
<mask>
<mask> var filters map[int]string
</s> * dnsforward: create dnsfilter asynchronously </s> remove s.dnsFilter = dnsfilter.New(&s.conf.Config, filters)
if s.dnsFilter == nil {
return fmt.Errorf("could not initialize dnsfilter")
</s> add if s.conf.AsyncStartup {
params := dnsfilterCreatorParams{
conf: s.conf.Config,
filters: filters,
}
s.startCounter++
if s.startCounter == 1 {
s.dnsfilterCreatorChan = make(chan dnsfilterCreatorParams, 1)
go s.dnsfilterCreator()
}
// remove all pending tasks
stop := false
for !stop {
select {
case <-s.dnsfilterCreatorChan:
//
default:
stop = true
}
}
s.dnsfilterCreatorChan <- params
} else {
log.Debug("creating dnsfilter...")
f := dnsfilter.New(&s.conf.Config, filters)
if f == nil {
return fmt.Errorf("could not initialize dnsfilter")
}
log.Debug("created dnsfilter")
s.dnsFilter = f </s> add type dnsfilterCreatorParams struct {
conf dnsfilter.Config
filters map[int]string
}
</s> add newconfig.AsyncStartup = true </s> add // Create dnsfilter asynchronously.
// Requests won't be filtered until dnsfilter is created.
// If "restart" command is received while we're creating an old dnsfilter object,
// we delay creation of the new object until the old one is created.
AsyncStartup bool
</s> add // How many times the server was started
// While creating a dnsfilter object,
// we use this value to set s.dnsFilter property only with the most recent settings.
startCounter uint32
dnsfilterCreatorChan chan dnsfilterCreatorParams
|
https://github.com/AdguardTeam/AdGuardHome/commit/75b864f25ec5f762d6cbfc07d3dce7d77ca0629c
|
dnsforward/dnsforward.go
|
keep keep keep keep replace replace replace keep keep keep keep keep
|
<mask> if len(s.conf.SafeBrowsingBlockHost) == 0 {
<mask> s.conf.SafeBrowsingBlockHost = safeBrowsingBlockHost
<mask> }
<mask>
<mask> s.dnsFilter = dnsfilter.New(&s.conf.Config, filters)
<mask> if s.dnsFilter == nil {
<mask> return fmt.Errorf("could not initialize dnsfilter")
<mask> }
<mask> return nil
<mask> }
<mask>
<mask> // Stop stops the DNS server
</s> * dnsforward: create dnsfilter asynchronously </s> remove log.Tracef("Creating dnsfilter")
</s> add </s> add newconfig.AsyncStartup = true </s> add type dnsfilterCreatorParams struct {
conf dnsfilter.Config
filters map[int]string
}
</s> add // How many times the server was started
// While creating a dnsfilter object,
// we use this value to set s.dnsFilter property only with the most recent settings.
startCounter uint32
dnsfilterCreatorChan chan dnsfilterCreatorParams
</s> add // Create dnsfilter asynchronously.
// Requests won't be filtered until dnsfilter is created.
// If "restart" command is received while we're creating an old dnsfilter object,
// we delay creation of the new object until the old one is created.
AsyncStartup bool
|
https://github.com/AdguardTeam/AdGuardHome/commit/75b864f25ec5f762d6cbfc07d3dce7d77ca0629c
|
dnsforward/dnsforward.go
|
keep keep add keep keep keep keep
|
<mask> FilteringConfig: config.DNS.FilteringConfig,
<mask> Filters: filters,
<mask> }
<mask> bindhost := config.DNS.BindHost
<mask> if config.DNS.BindHost == "0.0.0.0" {
<mask> bindhost = "127.0.0.1"
<mask> }
</s> * dnsforward: create dnsfilter asynchronously </s> remove s.dnsFilter = dnsfilter.New(&s.conf.Config, filters)
if s.dnsFilter == nil {
return fmt.Errorf("could not initialize dnsfilter")
</s> add if s.conf.AsyncStartup {
params := dnsfilterCreatorParams{
conf: s.conf.Config,
filters: filters,
}
s.startCounter++
if s.startCounter == 1 {
s.dnsfilterCreatorChan = make(chan dnsfilterCreatorParams, 1)
go s.dnsfilterCreator()
}
// remove all pending tasks
stop := false
for !stop {
select {
case <-s.dnsfilterCreatorChan:
//
default:
stop = true
}
}
s.dnsfilterCreatorChan <- params
} else {
log.Debug("creating dnsfilter...")
f := dnsfilter.New(&s.conf.Config, filters)
if f == nil {
return fmt.Errorf("could not initialize dnsfilter")
}
log.Debug("created dnsfilter")
s.dnsFilter = f </s> remove log.Tracef("Creating dnsfilter")
</s> add </s> add type dnsfilterCreatorParams struct {
conf dnsfilter.Config
filters map[int]string
}
</s> add // Create dnsfilter asynchronously.
// Requests won't be filtered until dnsfilter is created.
// If "restart" command is received while we're creating an old dnsfilter object,
// we delay creation of the new object until the old one is created.
AsyncStartup bool
</s> add // How many times the server was started
// While creating a dnsfilter object,
// we use this value to set s.dnsFilter property only with the most recent settings.
startCounter uint32
dnsfilterCreatorChan chan dnsfilterCreatorParams
|
https://github.com/AdguardTeam/AdGuardHome/commit/75b864f25ec5f762d6cbfc07d3dce7d77ca0629c
|
home/dns.go
|
keep add keep keep keep keep keep keep
|
<mask> s.conf.TCPListenAddr = defaultValues.TCPListenAddr
<mask> }
<mask> }
<mask>
<mask> // prepareUpstreamSettings - prepares upstream DNS server settings
<mask> func (s *Server) prepareUpstreamSettings() error {
<mask> // We're setting a customized set of RootCAs
<mask> // The reason is that Go default mechanism of loading TLS roots
</s> * (dnsforward): added some hosts to disallowed by default </s> remove github.com/AdguardTeam/dnsproxy v0.32.1 h1:UoiFt/aT8YCBFUGe7hG8ehLRXyvoIf22mOQqeIQxhWI=
github.com/AdguardTeam/dnsproxy v0.32.1/go.mod h1:ZLDrKIypYxBDz2N9FQHgeehuHrwTbuhZXdGwNySshbw=
</s> add github.com/AdguardTeam/dnsproxy v0.32.2 h1:gD2VojnQEIzWp3fkT20RS9ehyF0MBGGZQdcX/eKM7fQ=
github.com/AdguardTeam/dnsproxy v0.32.2/go.mod h1:ZLDrKIypYxBDz2N9FQHgeehuHrwTbuhZXdGwNySshbw= </s> remove github.com/AdguardTeam/dnsproxy v0.32.1
</s> add github.com/AdguardTeam/dnsproxy v0.32.2 </s> add // Often requested by all kinds of DNS probes
var defaultBlockedHosts = []string{"version.bind", "id.server", "hostname.bind"}
|
https://github.com/AdguardTeam/AdGuardHome/commit/75d680ff30001e846edcbbc6c102fb36ce52bcba
|
dnsforward/config.go
|
keep keep add keep keep keep keep
|
<mask> }
<mask> var defaultBootstrap = []string{"9.9.9.10", "149.112.112.10", "2620:fe::10", "2620:fe::fe:10"}
<mask>
<mask> var webRegistered bool
<mask>
<mask> // Server is the main way to start a DNS server.
<mask> //
</s> * (dnsforward): added some hosts to disallowed by default </s> remove github.com/AdguardTeam/dnsproxy v0.32.1 h1:UoiFt/aT8YCBFUGe7hG8ehLRXyvoIf22mOQqeIQxhWI=
github.com/AdguardTeam/dnsproxy v0.32.1/go.mod h1:ZLDrKIypYxBDz2N9FQHgeehuHrwTbuhZXdGwNySshbw=
</s> add github.com/AdguardTeam/dnsproxy v0.32.2 h1:gD2VojnQEIzWp3fkT20RS9ehyF0MBGGZQdcX/eKM7fQ=
github.com/AdguardTeam/dnsproxy v0.32.2/go.mod h1:ZLDrKIypYxBDz2N9FQHgeehuHrwTbuhZXdGwNySshbw= </s> remove github.com/AdguardTeam/dnsproxy v0.32.1
</s> add github.com/AdguardTeam/dnsproxy v0.32.2 </s> add if len(s.conf.BlockedHosts) == 0 {
s.conf.BlockedHosts = defaultBlockedHosts
}
|
https://github.com/AdguardTeam/AdGuardHome/commit/75d680ff30001e846edcbbc6c102fb36ce52bcba
|
dnsforward/dnsforward.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask>
<mask> go 1.14
<mask>
<mask> require (
<mask> github.com/AdguardTeam/dnsproxy v0.32.1
<mask> github.com/AdguardTeam/golibs v0.4.2
<mask> github.com/AdguardTeam/urlfilter v0.12.2
<mask> github.com/NYTimes/gziphandler v1.1.1
<mask> github.com/fsnotify/fsnotify v1.4.9
<mask> github.com/gobuffalo/packr v1.30.1
</s> * (dnsforward): added some hosts to disallowed by default </s> remove github.com/AdguardTeam/dnsproxy v0.32.1 h1:UoiFt/aT8YCBFUGe7hG8ehLRXyvoIf22mOQqeIQxhWI=
github.com/AdguardTeam/dnsproxy v0.32.1/go.mod h1:ZLDrKIypYxBDz2N9FQHgeehuHrwTbuhZXdGwNySshbw=
</s> add github.com/AdguardTeam/dnsproxy v0.32.2 h1:gD2VojnQEIzWp3fkT20RS9ehyF0MBGGZQdcX/eKM7fQ=
github.com/AdguardTeam/dnsproxy v0.32.2/go.mod h1:ZLDrKIypYxBDz2N9FQHgeehuHrwTbuhZXdGwNySshbw= </s> add // Often requested by all kinds of DNS probes
var defaultBlockedHosts = []string{"version.bind", "id.server", "hostname.bind"}
</s> add if len(s.conf.BlockedHosts) == 0 {
s.conf.BlockedHosts = defaultBlockedHosts
}
|
https://github.com/AdguardTeam/AdGuardHome/commit/75d680ff30001e846edcbbc6c102fb36ce52bcba
|
go.mod
|
keep keep keep keep replace replace keep keep keep keep keep
|
<mask> dmitri.shuralyov.com/html/belt v0.0.0-20180602232347-f7d459c86be0/go.mod h1:JLBrvjyP0v+ecvNYvCpyZgu5/xkfAUhi6wJj28eUfSU=
<mask> dmitri.shuralyov.com/service/change v0.0.0-20181023043359-a85b471d5412/go.mod h1:a1inKt/atXimZ4Mv927x+r7UpyzRUf4emIoiiSC2TN4=
<mask> dmitri.shuralyov.com/state v0.0.0-20180228185332-28bcc343414c/go.mod h1:0PRwlb0D6DFvNNtx+9ybjezNCa8XF0xaYcETyp6rHWU=
<mask> git.apache.org/thrift.git v0.0.0-20180902110319-2566ecd5d999/go.mod h1:fPE2ZNJGynbRyZ4dJvy6G277gSllfV2HJqblrnkyeyg=
<mask> github.com/AdguardTeam/dnsproxy v0.32.1 h1:UoiFt/aT8YCBFUGe7hG8ehLRXyvoIf22mOQqeIQxhWI=
<mask> github.com/AdguardTeam/dnsproxy v0.32.1/go.mod h1:ZLDrKIypYxBDz2N9FQHgeehuHrwTbuhZXdGwNySshbw=
<mask> github.com/AdguardTeam/golibs v0.4.0/go.mod h1:skKsDKIBB7kkFflLJBpfGX+G8QFTx0WKUzB6TIgtUj4=
<mask> github.com/AdguardTeam/golibs v0.4.2 h1:7M28oTZFoFwNmp8eGPb3ImmYbxGaJLyQXeIFVHjME0o=
<mask> github.com/AdguardTeam/golibs v0.4.2/go.mod h1:skKsDKIBB7kkFflLJBpfGX+G8QFTx0WKUzB6TIgtUj4=
<mask> github.com/AdguardTeam/gomitmproxy v0.2.0/go.mod h1:Qdv0Mktnzer5zpdpi5rAwixNJzW2FN91LjKJCkVbYGU=
<mask> github.com/AdguardTeam/urlfilter v0.12.2 h1:5ZkH/+AWNBK8cCfbcgOL1MIrpPJ2NJXDs00KjYJr2WE=
</s> * (dnsforward): added some hosts to disallowed by default </s> remove github.com/AdguardTeam/dnsproxy v0.32.1
</s> add github.com/AdguardTeam/dnsproxy v0.32.2 </s> add // Often requested by all kinds of DNS probes
var defaultBlockedHosts = []string{"version.bind", "id.server", "hostname.bind"}
</s> add if len(s.conf.BlockedHosts) == 0 {
s.conf.BlockedHosts = defaultBlockedHosts
}
|
https://github.com/AdguardTeam/AdGuardHome/commit/75d680ff30001e846edcbbc6c102fb36ce52bcba
|
go.sum
|
keep keep keep keep replace replace keep keep keep keep keep
|
<mask> "top_blocked_domains": "Top blocked domains",
<mask> "top_clients": "Top clients",
<mask> "no_clients_found": "No clients found",
<mask> "general_statistics": "General statistics",
<mask> "number_of_dns_query_days": "A number of DNS quieries processed for the last {{value}} days",
<mask> "number_of_dns_query_24_hours": "A number of DNS quieries processed for the last 24 hours",
<mask> "number_of_dns_query_blocked_24_hours": "A number of DNS requests blocked by adblock filters and hosts blocklists",
<mask> "number_of_dns_query_blocked_24_hours_by_sec": "A number of DNS requests blocked by the AdGuard browsing security module",
<mask> "number_of_dns_query_blocked_24_hours_adult": "A number of adult websites blocked",
<mask> "enforced_save_search": "Enforced safe search",
<mask> "number_of_dns_query_to_safe_search": "A number of DNS requests to search engines for which Safe Search was enforced",
</s> * client: fix missed translations
Closes #952 </s> remove <Trans>Add DNS rewrite</Trans>
</s> add <Trans>rewrite_add</Trans> </s> remove "filter_added_successfully": "Filter has been added successfully"
</s> add "answer": "Answer",
"filter_added_successfully": "The filter has been successfully added" </s> remove subtitle={t('Allows to quickly block popular sites.')}
</s> add subtitle={t('blocked_services_desc')} </s> remove Header: 'Answer',
</s> add Header: this.props.t('answer'), </s> remove Header: 'Domain',
</s> add Header: this.props.t('domain'),
|
https://github.com/AdguardTeam/AdGuardHome/commit/75df5e82922a1e1e113c916d6996ac246186cda8
|
client/src/__locales/en.json
|
keep keep keep keep replace keep
|
<mask> "interval_24_hour": "24 hours",
<mask> "interval_days": "{{value}} days",
<mask> "time_period": "Time period",
<mask> "domain": "Domain",
<mask> "filter_added_successfully": "Filter has been added successfully"
<mask> }
</s> * client: fix missed translations
Closes #952 </s> remove "number_of_dns_query_days": "A number of DNS quieries processed for the last {{value}} days",
"number_of_dns_query_24_hours": "A number of DNS quieries processed for the last 24 hours",
</s> add "number_of_dns_query_days": "A number of DNS queries processed for the last {{value}} days",
"number_of_dns_query_24_hours": "A number of DNS queries processed for the last 24 hours", </s> remove subtitle={t('Allows to quickly block popular sites.')}
</s> add subtitle={t('blocked_services_desc')} </s> remove Header: 'Answer',
</s> add Header: this.props.t('answer'), </s> remove Header: 'Domain',
</s> add Header: this.props.t('domain'), </s> remove <Trans>Add DNS rewrite</Trans>
</s> add <Trans>rewrite_add</Trans>
|
https://github.com/AdguardTeam/AdGuardHome/commit/75df5e82922a1e1e113c916d6996ac246186cda8
|
client/src/__locales/en.json
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> >
<mask> <div className="modal-content">
<mask> <div className="modal-header">
<mask> <h4 className="modal-title">
<mask> <Trans>Add DNS rewrite</Trans>
<mask> </h4>
<mask> <button type="button" className="close" onClick={() => toggleRewritesModal()}>
<mask> <span className="sr-only">Close</span>
<mask> </button>
<mask> </div>
</s> * client: fix missed translations
Closes #952 </s> remove subtitle={t('Allows to quickly block popular sites.')}
</s> add subtitle={t('blocked_services_desc')} </s> remove "number_of_dns_query_days": "A number of DNS quieries processed for the last {{value}} days",
"number_of_dns_query_24_hours": "A number of DNS quieries processed for the last 24 hours",
</s> add "number_of_dns_query_days": "A number of DNS queries processed for the last {{value}} days",
"number_of_dns_query_24_hours": "A number of DNS queries processed for the last 24 hours", </s> remove Header: 'Answer',
</s> add Header: this.props.t('answer'), </s> remove Header: 'Domain',
</s> add Header: this.props.t('domain'), </s> remove "filter_added_successfully": "Filter has been added successfully"
</s> add "answer": "Answer",
"filter_added_successfully": "The filter has been successfully added"
|
https://github.com/AdguardTeam/AdGuardHome/commit/75df5e82922a1e1e113c916d6996ac246186cda8
|
client/src/components/Settings/Dns/Rewrites/Modal.js
|
keep keep keep keep replace keep keep keep keep replace keep keep
|
<mask> );
<mask>
<mask> columns = [
<mask> {
<mask> Header: 'Domain',
<mask> accessor: 'domain',
<mask> Cell: this.cellWrap,
<mask> },
<mask> {
<mask> Header: 'Answer',
<mask> accessor: 'answer',
<mask> Cell: this.cellWrap,
</s> * client: fix missed translations
Closes #952 </s> remove subtitle={t('Allows to quickly block popular sites.')}
</s> add subtitle={t('blocked_services_desc')} </s> remove <Trans>Add DNS rewrite</Trans>
</s> add <Trans>rewrite_add</Trans> </s> remove "filter_added_successfully": "Filter has been added successfully"
</s> add "answer": "Answer",
"filter_added_successfully": "The filter has been successfully added" </s> remove "number_of_dns_query_days": "A number of DNS quieries processed for the last {{value}} days",
"number_of_dns_query_24_hours": "A number of DNS quieries processed for the last 24 hours",
</s> add "number_of_dns_query_days": "A number of DNS queries processed for the last {{value}} days",
"number_of_dns_query_24_hours": "A number of DNS queries processed for the last 24 hours",
|
https://github.com/AdguardTeam/AdGuardHome/commit/75df5e82922a1e1e113c916d6996ac246186cda8
|
client/src/components/Settings/Dns/Rewrites/Table.js
|
keep keep keep keep replace keep keep keep keep keep
|
<mask>
<mask> return (
<mask> <Card
<mask> title={t('blocked_services')}
<mask> subtitle={t('Allows to quickly block popular sites.')}
<mask> bodyType="card-body box-body--settings"
<mask> >
<mask> <div className="form">
<mask> <Form
<mask> initialValues={{ ...initialData }}
</s> * client: fix missed translations
Closes #952 </s> remove <Trans>Add DNS rewrite</Trans>
</s> add <Trans>rewrite_add</Trans> </s> remove "number_of_dns_query_days": "A number of DNS quieries processed for the last {{value}} days",
"number_of_dns_query_24_hours": "A number of DNS quieries processed for the last 24 hours",
</s> add "number_of_dns_query_days": "A number of DNS queries processed for the last {{value}} days",
"number_of_dns_query_24_hours": "A number of DNS queries processed for the last 24 hours", </s> remove Header: 'Answer',
</s> add Header: this.props.t('answer'), </s> remove Header: 'Domain',
</s> add Header: this.props.t('domain'), </s> remove "filter_added_successfully": "Filter has been added successfully"
</s> add "answer": "Answer",
"filter_added_successfully": "The filter has been successfully added"
|
https://github.com/AdguardTeam/AdGuardHome/commit/75df5e82922a1e1e113c916d6996ac246186cda8
|
client/src/components/Settings/Services/index.js
|
keep keep keep add keep keep keep keep keep keep
|
<mask>
<mask> func handleDHCPStatus(w http.ResponseWriter, r *http.Request) {
<mask> log.Tracef("%s %v", r.Method, r.URL)
<mask> leases := convertLeases(dhcpServer.Leases(), true)
<mask> status := map[string]interface{}{
<mask> "config": config.DHCP,
<mask> "leases": leases,
<mask> "static_leases": staticLeases,
<mask> }
<mask>
</s> + dhcp: /dhcp/status: return static leases </s> remove if !ipInRange(s.leaseStart, s.leaseStop, obj[i].IP) {
</s> add if obj[i].Expiry != leaseExpireStatic &&
!ipInRange(s.leaseStart, s.leaseStop, obj[i].IP) {
</s> remove "config": config.DHCP,
"leases": leases,
</s> add "config": config.DHCP,
"leases": leases,
"static_leases": staticLeases,
|
https://github.com/AdguardTeam/AdGuardHome/commit/763b98695554f04e89ec1cbf15c47194d3a55d4e
|
dhcp.go
|
keep keep keep keep replace replace keep keep keep keep keep
|
<mask> func handleDHCPStatus(w http.ResponseWriter, r *http.Request) {
<mask> log.Tracef("%s %v", r.Method, r.URL)
<mask> leases := convertLeases(dhcpServer.Leases(), true)
<mask> status := map[string]interface{}{
<mask> "config": config.DHCP,
<mask> "leases": leases,
<mask> }
<mask>
<mask> w.Header().Set("Content-Type", "application/json")
<mask> err := json.NewEncoder(w).Encode(status)
<mask> if err != nil {
</s> + dhcp: /dhcp/status: return static leases </s> remove if !ipInRange(s.leaseStart, s.leaseStop, obj[i].IP) {
</s> add if obj[i].Expiry != leaseExpireStatic &&
!ipInRange(s.leaseStart, s.leaseStop, obj[i].IP) {
</s> add staticLeases := convertLeases(dhcpServer.StaticLeases(), false)
|
https://github.com/AdguardTeam/AdGuardHome/commit/763b98695554f04e89ec1cbf15c47194d3a55d4e
|
dhcp.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask>
<mask> numLeases := len(obj)
<mask> for i := range obj {
<mask>
<mask> if !ipInRange(s.leaseStart, s.leaseStop, obj[i].IP) {
<mask> log.Tracef("Skipping a lease with IP %s: not within current IP range", obj[i].IP)
<mask> continue
<mask> }
<mask>
<mask> lease := Lease{
</s> + dhcp: /dhcp/status: return static leases </s> add staticLeases := convertLeases(dhcpServer.StaticLeases(), false) </s> remove "config": config.DHCP,
"leases": leases,
</s> add "config": config.DHCP,
"leases": leases,
"static_leases": staticLeases,
|
https://github.com/AdguardTeam/AdGuardHome/commit/763b98695554f04e89ec1cbf15c47194d3a55d4e
|
dhcpd/db.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> type hourTop struct {
<mask> domains gcache.Cache
<mask> blocked gcache.Cache
<mask> clients gcache.Cache
<mask> sync.RWMutex
<mask> }
<mask>
<mask> func (top *hourTop) init() {
<mask> top.domains = gcache.New(500).LRU().Build()
<mask> top.blocked = gcache.New(500).LRU().Build()
</s> coredns plugin -- Final fix for deadlock during coredns reload </s> remove hours []*hourTop
loaded bool
sync.RWMutex // write -- rotating hourTop, read -- anything else
</s> add hours []*hourTop
hoursLock sync.RWMutex // writelock this lock ONLY WHEN rotating or intializing hours!
loaded bool
loadedLock sync.Mutex </s> remove runningTop.Lock()
</s> add runningTop.hoursWriteLock() </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock() </s> remove runningTop.Lock()
</s> add runningTop.hoursWriteLock() </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock() </s> remove runningTop.Lock() // not rlock because we set it at the end of the function
defer runningTop.Unlock()
</s> add runningTop.loadedWriteLock()
defer runningTop.loadedWriteUnlock()
|
https://github.com/AdguardTeam/AdGuardHome/commit/763dcc46e96393282864c914321007d8810ed223
|
coredns_plugin/querylog_top.go
|
keep keep keep keep replace replace replace keep keep keep keep keep
|
<mask> top.clients = gcache.New(500).LRU().Build()
<mask> }
<mask>
<mask> type dayTop struct {
<mask> hours []*hourTop
<mask> loaded bool
<mask> sync.RWMutex // write -- rotating hourTop, read -- anything else
<mask> }
<mask>
<mask> var runningTop dayTop
<mask>
<mask> func init() {
</s> coredns plugin -- Final fix for deadlock during coredns reload </s> remove sync.RWMutex
</s> add mutex sync.RWMutex </s> remove runningTop.Lock()
</s> add runningTop.hoursWriteLock() </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock() </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock() </s> remove runningTop.Lock()
</s> add runningTop.hoursWriteLock() </s> remove runningTop.Lock() // not rlock because we set it at the end of the function
defer runningTop.Unlock()
</s> add runningTop.loadedWriteLock()
defer runningTop.loadedWriteUnlock()
|
https://github.com/AdguardTeam/AdGuardHome/commit/763dcc46e96393282864c914321007d8810ed223
|
coredns_plugin/querylog_top.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask>
<mask> var runningTop dayTop
<mask>
<mask> func init() {
<mask> runningTop.Lock()
<mask> for i := 0; i < 24; i++ {
<mask> hour := hourTop{}
<mask> hour.init()
<mask> runningTop.hours = append(runningTop.hours, &hour)
<mask> }
</s> coredns plugin -- Final fix for deadlock during coredns reload </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock() </s> remove runningTop.RLock()
</s> add runningTop.hoursReadLock() </s> remove hours []*hourTop
loaded bool
sync.RWMutex // write -- rotating hourTop, read -- anything else
</s> add hours []*hourTop
hoursLock sync.RWMutex // writelock this lock ONLY WHEN rotating or intializing hours!
loaded bool
loadedLock sync.Mutex </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock() </s> remove runningTop.Lock()
</s> add runningTop.hoursWriteLock() </s> remove runningTop.Lock() // not rlock because we set it at the end of the function
defer runningTop.Unlock()
</s> add runningTop.loadedWriteLock()
defer runningTop.loadedWriteUnlock()
|
https://github.com/AdguardTeam/AdGuardHome/commit/763dcc46e96393282864c914321007d8810ed223
|
coredns_plugin/querylog_top.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> hour := hourTop{}
<mask> hour.init()
<mask> runningTop.hours = append(runningTop.hours, &hour)
<mask> }
<mask> runningTop.Unlock()
<mask> }
<mask>
<mask> func rotateHourlyTop() {
<mask> log.Printf("Rotating hourly top")
<mask> hour := &hourTop{}
</s> coredns plugin -- Final fix for deadlock during coredns reload </s> remove runningTop.Lock()
</s> add runningTop.hoursWriteLock() </s> remove runningTop.Lock()
</s> add runningTop.hoursWriteLock() </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock() </s> remove runningTop.RLock()
</s> add runningTop.hoursReadLock() </s> remove runningTop.Lock() // not rlock because we set it at the end of the function
defer runningTop.Unlock()
</s> add runningTop.loadedWriteLock()
defer runningTop.loadedWriteUnlock() </s> remove sync.RWMutex
</s> add mutex sync.RWMutex
|
https://github.com/AdguardTeam/AdGuardHome/commit/763dcc46e96393282864c914321007d8810ed223
|
coredns_plugin/querylog_top.go
|
keep keep keep keep replace keep keep replace keep keep keep keep
|
<mask> func rotateHourlyTop() {
<mask> log.Printf("Rotating hourly top")
<mask> hour := &hourTop{}
<mask> hour.init()
<mask> runningTop.Lock()
<mask> runningTop.hours = append([]*hourTop{hour}, runningTop.hours...)
<mask> runningTop.hours = runningTop.hours[:24]
<mask> runningTop.Unlock()
<mask> }
<mask>
<mask> func periodicHourlyTopRotate() {
<mask> t := time.Hour
</s> coredns plugin -- Final fix for deadlock during coredns reload </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock() </s> remove runningTop.Lock()
</s> add runningTop.hoursWriteLock() </s> remove runningTop.Lock() // not rlock because we set it at the end of the function
defer runningTop.Unlock()
</s> add runningTop.loadedWriteLock()
defer runningTop.loadedWriteUnlock() </s> remove sync.RWMutex
</s> add mutex sync.RWMutex </s> remove runningTop.RLock()
</s> add runningTop.hoursReadLock()
|
https://github.com/AdguardTeam/AdGuardHome/commit/763dcc46e96393282864c914321007d8810ed223
|
coredns_plugin/querylog_top.go
|
keep keep keep keep replace replace keep keep keep keep keep
|
<mask>
<mask> hostname := strings.ToLower(strings.TrimSuffix(q.Question[0].Name, "."))
<mask>
<mask> // get value, if not set, crate one
<mask> runningTop.RLock()
<mask> defer runningTop.RUnlock()
<mask> err := runningTop.hours[hour].incrementDomains(hostname)
<mask> if err != nil {
<mask> log.Printf("Failed to increment value: %s", err)
<mask> return err
<mask> }
</s> coredns plugin -- Final fix for deadlock during coredns reload </s> remove runningTop.Lock() // not rlock because we set it at the end of the function
defer runningTop.Unlock()
</s> add runningTop.loadedWriteLock()
defer runningTop.loadedWriteUnlock() </s> remove runningTop.RUnlock()
</s> add runningTop.hoursReadUnlock() </s> remove runningTop.RLock()
</s> add runningTop.hoursReadLock() </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock() </s> remove runningTop.Lock()
</s> add runningTop.hoursWriteLock() </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock()
|
https://github.com/AdguardTeam/AdGuardHome/commit/763dcc46e96393282864c914321007d8810ed223
|
coredns_plugin/querylog_top.go
|
keep keep keep keep replace replace keep keep keep keep keep
|
<mask> }
<mask>
<mask> func loadTopFromFiles() error {
<mask> now := time.Now()
<mask> runningTop.Lock() // not rlock because we set it at the end of the function
<mask> defer runningTop.Unlock()
<mask> if runningTop.loaded {
<mask> return nil
<mask> }
<mask> onEntry := func(entry *logEntry) error {
<mask> err := runningTop.addEntry(entry, now)
</s> coredns plugin -- Final fix for deadlock during coredns reload </s> remove runningTop.RLock()
defer runningTop.RUnlock()
</s> add runningTop.hoursReadLock()
defer runningTop.hoursReadUnlock() </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock() </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock() </s> remove runningTop.Lock()
</s> add runningTop.hoursWriteLock() </s> remove runningTop.RUnlock()
</s> add runningTop.hoursReadUnlock() </s> remove runningTop.Lock()
</s> add runningTop.hoursWriteLock()
|
https://github.com/AdguardTeam/AdGuardHome/commit/763dcc46e96393282864c914321007d8810ed223
|
coredns_plugin/querylog_top.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> result[key] += value
<mask> }
<mask> }
<mask>
<mask> runningTop.RLock()
<mask> for hour := 0; hour < 24; hour++ {
<mask> runningTop.hours[hour].RLock()
<mask> do(runningTop.hours[hour].domains.Keys(), runningTop.hours[hour].lockedGetDomains, domains)
<mask> do(runningTop.hours[hour].blocked.Keys(), runningTop.hours[hour].lockedGetBlocked, blocked)
<mask> do(runningTop.hours[hour].clients.Keys(), runningTop.hours[hour].lockedGetClients, clients)
</s> coredns plugin -- Final fix for deadlock during coredns reload </s> remove runningTop.RUnlock()
</s> add runningTop.hoursReadUnlock() </s> remove runningTop.Lock()
</s> add runningTop.hoursWriteLock() </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock() </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock() </s> remove runningTop.RLock()
defer runningTop.RUnlock()
</s> add runningTop.hoursReadLock()
defer runningTop.hoursReadUnlock() </s> remove runningTop.Lock()
</s> add runningTop.hoursWriteLock()
|
https://github.com/AdguardTeam/AdGuardHome/commit/763dcc46e96393282864c914321007d8810ed223
|
coredns_plugin/querylog_top.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> do(runningTop.hours[hour].blocked.Keys(), runningTop.hours[hour].lockedGetBlocked, blocked)
<mask> do(runningTop.hours[hour].clients.Keys(), runningTop.hours[hour].lockedGetClients, clients)
<mask> runningTop.hours[hour].RUnlock()
<mask> }
<mask> runningTop.RUnlock()
<mask>
<mask> // use manual json marshalling because we want maps to be sorted by value
<mask> json := bytes.Buffer{}
<mask> json.WriteString("{\n")
<mask>
</s> coredns plugin -- Final fix for deadlock during coredns reload </s> remove runningTop.RLock()
</s> add runningTop.hoursReadLock() </s> remove runningTop.RLock()
defer runningTop.RUnlock()
</s> add runningTop.hoursReadLock()
defer runningTop.hoursReadUnlock() </s> remove runningTop.Lock() // not rlock because we set it at the end of the function
defer runningTop.Unlock()
</s> add runningTop.loadedWriteLock()
defer runningTop.loadedWriteUnlock() </s> remove runningTop.Unlock()
</s> add runningTop.hoursWriteUnlock() </s> remove runningTop.Lock()
</s> add runningTop.hoursWriteLock() </s> remove hours []*hourTop
loaded bool
sync.RWMutex // write -- rotating hourTop, read -- anything else
</s> add hours []*hourTop
hoursLock sync.RWMutex // writelock this lock ONLY WHEN rotating or intializing hours!
loaded bool
loadedLock sync.Mutex
|
https://github.com/AdguardTeam/AdGuardHome/commit/763dcc46e96393282864c914321007d8810ed223
|
coredns_plugin/querylog_top.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> httpsServer.cond.Wait()
<mask> }
<mask> address := net.JoinHostPort(config.BindHost, strconv.Itoa(config.TLS.PortHTTPS))
<mask> // validate current TLS config and update warnings (it could have been loaded from file)
<mask> data := validateCertificates(config.TLS)
<mask> if !data.usable {
<mask> log.Fatal(data.WarningValidation)
<mask> os.Exit(1)
<mask> }
<mask> config.Lock()
</s> * validateCertificates(): change input parameters; added short description </s> remove config.TLS = data // update warnings
</s> add config.TLS.tlsConfigStatus = data // update warnings </s> remove data = validateCertificates(data)
</s> add data.tlsConfigStatus = validateCertificates(data.CertificateChain, data.PrivateKey, data.ServerName) </s> remove if data.PrivateKey != "" {
</s> add if PrivateKey != "" { </s> remove
// clear out status for certificates
data.tlsConfigStatus = tlsConfigStatus{}
</s> add var data tlsConfigStatus </s> remove if data.PrivateKey != "" && data.CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(data.CertificateChain), []byte(data.PrivateKey))
</s> add if PrivateKey != "" && CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(CertificateChain), []byte(PrivateKey)) </s> remove DNSName: data.ServerName,
</s> add DNSName: ServerName,
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
app.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> log.Fatal(data.WarningValidation)
<mask> os.Exit(1)
<mask> }
<mask> config.Lock()
<mask> config.TLS = data // update warnings
<mask> config.Unlock()
<mask>
<mask> // prepare certs for HTTPS server
<mask> // important -- they have to be copies, otherwise changing the contents in config.TLS will break encryption for in-flight requests
<mask> certchain := make([]byte, len(config.TLS.CertificateChain))
</s> * validateCertificates(): change input parameters; added short description </s> remove data := validateCertificates(config.TLS)
</s> add data := validateCertificates(config.TLS.CertificateChain, config.TLS.PrivateKey, config.TLS.ServerName) </s> remove data = validateCertificates(data)
</s> add data.tlsConfigStatus = validateCertificates(data.CertificateChain, data.PrivateKey, data.ServerName) </s> remove pemblock := []byte(data.CertificateChain)
</s> add pemblock := []byte(CertificateChain) </s> remove pemblock := []byte(data.PrivateKey)
</s> add pemblock := []byte(PrivateKey) </s> remove if data.CertificateChain != "" {
log.Tracef("got certificate: %s", data.CertificateChain)
</s> add if CertificateChain != "" {
log.Tracef("got certificate: %s", CertificateChain) </s> remove
// clear out status for certificates
data.tlsConfigStatus = tlsConfigStatus{}
</s> add var data tlsConfigStatus
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
app.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> return
<mask> }
<mask> }
<mask>
<mask> data = validateCertificates(data)
<mask> marshalTLS(w, data)
<mask> }
<mask>
<mask> func handleTLSConfigure(w http.ResponseWriter, r *http.Request) {
<mask> data, err := unmarshalTLS(r)
</s> * validateCertificates(): change input parameters; added short description </s> remove func validateCertificates(data tlsConfig) tlsConfig {
</s> add /* Process certificate data and its private key.
CertificateChain, PrivateKey parameters are optional.
On error, return partially set object
with 'WarningValidation' field containing error description.
*/
func validateCertificates(CertificateChain, PrivateKey, ServerName string) tlsConfigStatus { </s> remove if data.PrivateKey != "" && data.CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(data.CertificateChain), []byte(data.PrivateKey))
</s> add if PrivateKey != "" && CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(CertificateChain), []byte(PrivateKey)) </s> remove data.CertificateChain = "bad cert"
data.PrivateKey = ""
data = validateCertificates(data)
</s> add data = validateCertificates("bad cert", "", "") </s> remove data.CertificateChain = ""
data.PrivateKey = "bad priv key"
data = validateCertificates(data)
</s> add data = validateCertificates("", "bad priv key", "") </s> remove data = validateCertificates(data)
</s> add data.tlsConfigStatus = validateCertificates(data.CertificateChain, data.PrivateKey, data.ServerName) </s> remove
// clear out status for certificates
data.tlsConfigStatus = tlsConfigStatus{}
</s> add var data tlsConfigStatus
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
control.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> }
<mask> }
<mask>
<mask> restartHTTPS := false
<mask> data = validateCertificates(data)
<mask> if !reflect.DeepEqual(config.TLS.tlsConfigSettings, data.tlsConfigSettings) {
<mask> log.Printf("tls config settings have changed, will restart HTTPS server")
<mask> restartHTTPS = true
<mask> }
<mask> config.TLS = data
</s> * validateCertificates(): change input parameters; added short description </s> remove config.TLS = data // update warnings
</s> add config.TLS.tlsConfigStatus = data // update warnings </s> remove data := validateCertificates(config.TLS)
</s> add data := validateCertificates(config.TLS.CertificateChain, config.TLS.PrivateKey, config.TLS.ServerName) </s> remove data = validateCertificates(data)
</s> add data.tlsConfigStatus = validateCertificates(data.CertificateChain, data.PrivateKey, data.ServerName) </s> remove if data.PrivateKey != "" && data.CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(data.CertificateChain), []byte(data.PrivateKey))
</s> add if PrivateKey != "" && CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(CertificateChain), []byte(PrivateKey)) </s> remove data.CertificateChain = ""
data.PrivateKey = "bad priv key"
data = validateCertificates(data)
</s> add data = validateCertificates("", "bad priv key", "") </s> remove data.CertificateChain = "bad cert"
data.PrivateKey = ""
data = validateCertificates(data)
</s> add data = validateCertificates("bad cert", "", "")
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
control.go
|
keep keep keep replace keep replace replace replace keep keep
|
<mask> }
<mask> }
<mask>
<mask> func validateCertificates(data tlsConfig) tlsConfig {
<mask> var err error
<mask>
<mask> // clear out status for certificates
<mask> data.tlsConfigStatus = tlsConfigStatus{}
<mask>
<mask> // check only public certificate separately from the key
</s> * validateCertificates(): change input parameters; added short description </s> remove if data.CertificateChain != "" {
log.Tracef("got certificate: %s", data.CertificateChain)
</s> add if CertificateChain != "" {
log.Tracef("got certificate: %s", CertificateChain) </s> remove if data.PrivateKey != "" {
</s> add if PrivateKey != "" { </s> remove data = validateCertificates(data)
</s> add data.tlsConfigStatus = validateCertificates(data.CertificateChain, data.PrivateKey, data.ServerName) </s> remove var data tlsConfig
</s> add var data tlsConfigStatus </s> remove if data.PrivateKey != "" && data.CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(data.CertificateChain), []byte(data.PrivateKey))
</s> add if PrivateKey != "" && CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(CertificateChain), []byte(PrivateKey))
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
control.go
|
keep keep keep keep replace replace keep keep keep keep keep
|
<mask> // clear out status for certificates
<mask> data.tlsConfigStatus = tlsConfigStatus{}
<mask>
<mask> // check only public certificate separately from the key
<mask> if data.CertificateChain != "" {
<mask> log.Tracef("got certificate: %s", data.CertificateChain)
<mask>
<mask> // now do a more extended validation
<mask> var certs []*pem.Block // PEM-encoded certificates
<mask> var skippedBytes []string // skipped bytes
<mask>
</s> * validateCertificates(): change input parameters; added short description </s> remove
// clear out status for certificates
data.tlsConfigStatus = tlsConfigStatus{}
</s> add var data tlsConfigStatus </s> remove pemblock := []byte(data.CertificateChain)
</s> add pemblock := []byte(CertificateChain) </s> remove if data.PrivateKey != "" {
</s> add if PrivateKey != "" { </s> remove pemblock := []byte(data.PrivateKey)
</s> add pemblock := []byte(PrivateKey) </s> remove func validateCertificates(data tlsConfig) tlsConfig {
</s> add /* Process certificate data and its private key.
CertificateChain, PrivateKey parameters are optional.
On error, return partially set object
with 'WarningValidation' field containing error description.
*/
func validateCertificates(CertificateChain, PrivateKey, ServerName string) tlsConfigStatus { </s> remove if data.PrivateKey != "" && data.CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(data.CertificateChain), []byte(data.PrivateKey))
</s> add if PrivateKey != "" && CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(CertificateChain), []byte(PrivateKey))
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
control.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> // now do a more extended validation
<mask> var certs []*pem.Block // PEM-encoded certificates
<mask> var skippedBytes []string // skipped bytes
<mask>
<mask> pemblock := []byte(data.CertificateChain)
<mask> for {
<mask> var decoded *pem.Block
<mask> decoded, pemblock = pem.Decode(pemblock)
<mask> if decoded == nil {
<mask> break
</s> * validateCertificates(): change input parameters; added short description </s> remove pemblock := []byte(data.PrivateKey)
</s> add pemblock := []byte(PrivateKey) </s> remove if data.CertificateChain != "" {
log.Tracef("got certificate: %s", data.CertificateChain)
</s> add if CertificateChain != "" {
log.Tracef("got certificate: %s", CertificateChain) </s> remove if data.PrivateKey != "" {
</s> add if PrivateKey != "" { </s> remove config.TLS = data // update warnings
</s> add config.TLS.tlsConfigStatus = data // update warnings </s> remove
// clear out status for certificates
data.tlsConfigStatus = tlsConfigStatus{}
</s> add var data tlsConfigStatus </s> remove DNSName: data.ServerName,
</s> add DNSName: ServerName,
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
control.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask>
<mask> // spew.Dump(parsedCerts)
<mask>
<mask> opts := x509.VerifyOptions{
<mask> DNSName: data.ServerName,
<mask> }
<mask>
<mask> log.Printf("number of certs - %d", len(parsedCerts))
<mask> if len(parsedCerts) > 1 {
<mask> // set up an intermediate
</s> * validateCertificates(): change input parameters; added short description </s> remove pemblock := []byte(data.CertificateChain)
</s> add pemblock := []byte(CertificateChain) </s> remove if data.CertificateChain != "" {
log.Tracef("got certificate: %s", data.CertificateChain)
</s> add if CertificateChain != "" {
log.Tracef("got certificate: %s", CertificateChain) </s> remove func validateCertificates(data tlsConfig) tlsConfig {
</s> add /* Process certificate data and its private key.
CertificateChain, PrivateKey parameters are optional.
On error, return partially set object
with 'WarningValidation' field containing error description.
*/
func validateCertificates(CertificateChain, PrivateKey, ServerName string) tlsConfigStatus { </s> remove config.TLS = data // update warnings
</s> add config.TLS.tlsConfigStatus = data // update warnings </s> remove data := validateCertificates(config.TLS)
</s> add data := validateCertificates(config.TLS.CertificateChain, config.TLS.PrivateKey, config.TLS.ServerName) </s> remove if data.PrivateKey != "" {
</s> add if PrivateKey != "" {
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
control.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> }
<mask> }
<mask>
<mask> // validate private key (right now the only validation possible is just parsing it)
<mask> if data.PrivateKey != "" {
<mask> // now do a more extended validation
<mask> var key *pem.Block // PEM-encoded certificates
<mask> var skippedBytes []string // skipped bytes
<mask>
<mask> // go through all pem blocks, but take first valid pem block and drop the rest
</s> * validateCertificates(): change input parameters; added short description </s> remove pemblock := []byte(data.PrivateKey)
</s> add pemblock := []byte(PrivateKey) </s> remove if data.CertificateChain != "" {
log.Tracef("got certificate: %s", data.CertificateChain)
</s> add if CertificateChain != "" {
log.Tracef("got certificate: %s", CertificateChain) </s> remove pemblock := []byte(data.CertificateChain)
</s> add pemblock := []byte(CertificateChain) </s> remove
// clear out status for certificates
data.tlsConfigStatus = tlsConfigStatus{}
</s> add var data tlsConfigStatus </s> remove var data tlsConfig
</s> add var data tlsConfigStatus </s> remove data := validateCertificates(config.TLS)
</s> add data := validateCertificates(config.TLS.CertificateChain, config.TLS.PrivateKey, config.TLS.ServerName)
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
control.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> var key *pem.Block // PEM-encoded certificates
<mask> var skippedBytes []string // skipped bytes
<mask>
<mask> // go through all pem blocks, but take first valid pem block and drop the rest
<mask> pemblock := []byte(data.PrivateKey)
<mask> for {
<mask> var decoded *pem.Block
<mask> decoded, pemblock = pem.Decode(pemblock)
<mask> if decoded == nil {
<mask> break
</s> * validateCertificates(): change input parameters; added short description </s> remove pemblock := []byte(data.CertificateChain)
</s> add pemblock := []byte(CertificateChain) </s> remove if data.PrivateKey != "" {
</s> add if PrivateKey != "" { </s> remove if data.CertificateChain != "" {
log.Tracef("got certificate: %s", data.CertificateChain)
</s> add if CertificateChain != "" {
log.Tracef("got certificate: %s", CertificateChain) </s> remove
// clear out status for certificates
data.tlsConfigStatus = tlsConfigStatus{}
</s> add var data tlsConfigStatus </s> remove config.TLS = data // update warnings
</s> add config.TLS.tlsConfigStatus = data // update warnings </s> remove func validateCertificates(data tlsConfig) tlsConfig {
</s> add /* Process certificate data and its private key.
CertificateChain, PrivateKey parameters are optional.
On error, return partially set object
with 'WarningValidation' field containing error description.
*/
func validateCertificates(CertificateChain, PrivateKey, ServerName string) tlsConfigStatus {
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
control.go
|
keep keep keep keep replace replace keep keep keep keep keep
|
<mask> data.KeyType = keytype
<mask> }
<mask>
<mask> // if both are set, validate both in unison
<mask> if data.PrivateKey != "" && data.CertificateChain != "" {
<mask> _, err = tls.X509KeyPair([]byte(data.CertificateChain), []byte(data.PrivateKey))
<mask> if err != nil {
<mask> data.WarningValidation = fmt.Sprintf("Invalid certificate or key: %s", err)
<mask> return data
<mask> }
<mask> data.usable = true
</s> * validateCertificates(): change input parameters; added short description </s> remove
// clear out status for certificates
data.tlsConfigStatus = tlsConfigStatus{}
</s> add var data tlsConfigStatus </s> remove data.CertificateChain = ""
data.PrivateKey = "bad priv key"
data = validateCertificates(data)
</s> add data = validateCertificates("", "bad priv key", "") </s> remove data.CertificateChain = "bad cert"
data.PrivateKey = ""
data = validateCertificates(data)
</s> add data = validateCertificates("bad cert", "", "") </s> remove data = validateCertificates(data)
</s> add data.tlsConfigStatus = validateCertificates(data.CertificateChain, data.PrivateKey, data.ServerName) </s> remove data = validateCertificates(data)
</s> add data.tlsConfigStatus = validateCertificates(data.CertificateChain, data.PrivateKey, data.ServerName) </s> remove if data.CertificateChain != "" {
log.Tracef("got certificate: %s", data.CertificateChain)
</s> add if CertificateChain != "" {
log.Tracef("got certificate: %s", CertificateChain)
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
control.go
|
keep replace keep keep replace replace replace keep keep
|
<mask> func TestValidateCertificates(t *testing.T) {
<mask> var data tlsConfig
<mask>
<mask> // bad cert
<mask> data.CertificateChain = "bad cert"
<mask> data.PrivateKey = ""
<mask> data = validateCertificates(data)
<mask> if !(data.WarningValidation != "" &&
<mask> !data.ValidCert &&
</s> * validateCertificates(): change input parameters; added short description </s> remove data.CertificateChain = ""
data.PrivateKey = "bad priv key"
data = validateCertificates(data)
</s> add data = validateCertificates("", "bad priv key", "") </s> remove data = validateCertificates(data)
</s> add data = validateCertificates(CertificateChain, PrivateKey, "") </s> remove if data.PrivateKey != "" && data.CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(data.CertificateChain), []byte(data.PrivateKey))
</s> add if PrivateKey != "" && CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(CertificateChain), []byte(PrivateKey)) </s> remove
// clear out status for certificates
data.tlsConfigStatus = tlsConfigStatus{}
</s> add var data tlsConfigStatus </s> remove data = validateCertificates(data)
</s> add data.tlsConfigStatus = validateCertificates(data.CertificateChain, data.PrivateKey, data.ServerName)
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
control_test.go
|
keep keep keep keep replace replace replace keep keep keep keep keep
|
<mask> t.Fatalf("bad cert: validateCertificates(): %v", data)
<mask> }
<mask>
<mask> // bad priv key
<mask> data.CertificateChain = ""
<mask> data.PrivateKey = "bad priv key"
<mask> data = validateCertificates(data)
<mask> if !(data.WarningValidation != "" &&
<mask> !data.ValidKey) {
<mask> t.Fatalf("bad priv key: validateCertificates(): %v", data)
<mask> }
<mask>
</s> * validateCertificates(): change input parameters; added short description </s> remove data.CertificateChain = `-----BEGIN CERTIFICATE-----
</s> add CertificateChain := `-----BEGIN CERTIFICATE----- </s> remove data.CertificateChain = "bad cert"
data.PrivateKey = ""
data = validateCertificates(data)
</s> add data = validateCertificates("bad cert", "", "") </s> remove if data.PrivateKey != "" && data.CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(data.CertificateChain), []byte(data.PrivateKey))
</s> add if PrivateKey != "" && CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(CertificateChain), []byte(PrivateKey)) </s> remove var data tlsConfig
</s> add var data tlsConfigStatus </s> remove data = validateCertificates(data)
</s> add data.tlsConfigStatus = validateCertificates(data.CertificateChain, data.PrivateKey, data.ServerName) </s> remove data = validateCertificates(data)
</s> add data = validateCertificates(CertificateChain, PrivateKey, "")
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
control_test.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> t.Fatalf("bad priv key: validateCertificates(): %v", data)
<mask> }
<mask>
<mask> // valid cert & priv key
<mask> data.CertificateChain = `-----BEGIN CERTIFICATE-----
<mask> MIICKzCCAZSgAwIBAgIJAMT9kPVJdM7LMA0GCSqGSIb3DQEBCwUAMC0xFDASBgNV
<mask> BAoMC0FkR3VhcmQgTHRkMRUwEwYDVQQDDAxBZEd1YXJkIEhvbWUwHhcNMTkwMjI3
<mask> MDkyNDIzWhcNNDYwNzE0MDkyNDIzWjAtMRQwEgYDVQQKDAtBZEd1YXJkIEx0ZDEV
<mask> MBMGA1UEAwwMQWRHdWFyZCBIb21lMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKB
<mask> gQCwvwUnPJiOvLcOaWmGu6Y68ksFr13nrXBcsDlhxlXy8PaohVi3XxEmt2OrVjKW
</s> * validateCertificates(): change input parameters; added short description </s> remove data.CertificateChain = ""
data.PrivateKey = "bad priv key"
data = validateCertificates(data)
</s> add data = validateCertificates("", "bad priv key", "") </s> remove data.CertificateChain = "bad cert"
data.PrivateKey = ""
data = validateCertificates(data)
</s> add data = validateCertificates("bad cert", "", "") </s> remove var data tlsConfig
</s> add var data tlsConfigStatus </s> remove data.PrivateKey = `-----BEGIN PRIVATE KEY-----
</s> add PrivateKey := `-----BEGIN PRIVATE KEY----- </s> remove if data.PrivateKey != "" && data.CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(data.CertificateChain), []byte(data.PrivateKey))
</s> add if PrivateKey != "" && CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(CertificateChain), []byte(PrivateKey)) </s> remove if data.PrivateKey != "" {
</s> add if PrivateKey != "" {
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
control_test.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> LwlXfbakf7qkVTlCNXgoY7RaJ8rJdPgOZPoCTVToEhT6u/cb1c2qp8QB0dNExDna
<mask> b0Z+dnODTZqQOJo6z/wIXlcUrnR4cQVvytXt8lFn+26l6Y6EMI26twC/xWr+1swq
<mask> Muj4FeWHVDerquH4yMr1jsYLD3ci+kc5sbIX6TfVxQ==
<mask> -----END CERTIFICATE-----`
<mask> data.PrivateKey = `-----BEGIN PRIVATE KEY-----
<mask> MIICeAIBADANBgkqhkiG9w0BAQEFAASCAmIwggJeAgEAAoGBALC/BSc8mI68tw5p
<mask> aYa7pjrySwWvXeetcFywOWHGVfLw9qiFWLdfESa3Y6tWMpZAXD9t1Xh9n211YUBV
<mask> FGSB4ZshnM/tgEPU6t787lJD4NsIIRp++MkJxdAitN4oUTqL0bdpIwezQ/CrYuBX
<mask> xTmZii0uu/IWITxA8iclsMMyloVjAgMBAAECgYEAmjzoG1h27UDkIlB9BVWl95TP
<mask> QVPLB81D267xNFDnWk1Lgr5zL/pnNjkdYjyjgpkBp1yKyE4gHV4skv5sAFWTcOCU
</s> * validateCertificates(): change input parameters; added short description </s> remove data = validateCertificates(data)
</s> add data = validateCertificates(CertificateChain, PrivateKey, "") </s> remove data.CertificateChain = `-----BEGIN CERTIFICATE-----
</s> add CertificateChain := `-----BEGIN CERTIFICATE----- </s> remove data.CertificateChain = "bad cert"
data.PrivateKey = ""
data = validateCertificates(data)
</s> add data = validateCertificates("bad cert", "", "") </s> remove data.CertificateChain = ""
data.PrivateKey = "bad priv key"
data = validateCertificates(data)
</s> add data = validateCertificates("", "bad priv key", "") </s> remove var data tlsConfig
</s> add var data tlsConfigStatus </s> remove if data.PrivateKey != "" && data.CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(data.CertificateChain), []byte(data.PrivateKey))
</s> add if PrivateKey != "" && CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(CertificateChain), []byte(PrivateKey))
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
control_test.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> O5EX70gpeGQMPDK0QSWpaazg956njJSDbNCFM4BccrdQbJu1cW4qOsfBAkAMgZuG
<mask> O88slmgTRHX4JGFmy3rrLiHNI2BbJSuJ++Yllz8beVzh6NfvuY+HKRCmPqoBPATU
<mask> kXS9jgARhhiWXJrk
<mask> -----END PRIVATE KEY-----`
<mask> data = validateCertificates(data)
<mask> notBefore, _ := time.Parse(time.RFC3339, "2019-02-27T09:24:23Z")
<mask> notAfter, _ := time.Parse(time.RFC3339, "2046-07-14T09:24:23Z")
<mask> if !(data.WarningValidation != "" /* self signed */ &&
<mask> data.ValidCert &&
<mask> !data.ValidChain &&
</s> * validateCertificates(): change input parameters; added short description </s> remove data.CertificateChain = "bad cert"
data.PrivateKey = ""
data = validateCertificates(data)
</s> add data = validateCertificates("bad cert", "", "") </s> remove data.CertificateChain = ""
data.PrivateKey = "bad priv key"
data = validateCertificates(data)
</s> add data = validateCertificates("", "bad priv key", "") </s> remove data.PrivateKey = `-----BEGIN PRIVATE KEY-----
</s> add PrivateKey := `-----BEGIN PRIVATE KEY----- </s> remove if data.PrivateKey != "" && data.CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(data.CertificateChain), []byte(data.PrivateKey))
</s> add if PrivateKey != "" && CertificateChain != "" {
_, err = tls.X509KeyPair([]byte(CertificateChain), []byte(PrivateKey)) </s> remove var data tlsConfig
</s> add var data tlsConfigStatus </s> remove data = validateCertificates(data)
</s> add data.tlsConfigStatus = validateCertificates(data.CertificateChain, data.PrivateKey, data.ServerName)
|
https://github.com/AdguardTeam/AdGuardHome/commit/766fbab0718f2b02fb3864e521820033ab015e36
|
control_test.go
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> "homepage": "https://github.com/DandelionSprout/adfilt",
<mask> "source": "https://adguardteam.github.io/HostlistsRegistry/assets/filter_13.txt"
<mask> },
<mask> "POL_polish_filters_for_pi_hole": {
<mask> "name": "POL: Polish filters for Pi hole",
<mask> "categoryId": "regional",
<mask> "homepage": "https://www.certyficate.it/",
<mask> "source": "https://adguardteam.github.io/HostlistsRegistry/assets/filter_14.txt"
<mask> },
<mask> "SWE_frellwit_swedish_hosts_file": {
</s> Pull request 1748: upd-all
Merge in DNS/adguard-home from upd-all to master
Squashed commit of the following:
commit 7014e7631933f7d5cb58ec6fd1a221f497983e98
Author: Ainar Garipov <[email protected]>
Date: Tue Feb 21 17:57:35 2023 +0300
all: upd i18n, filters, trackers, services, tools </s> add "oztam": {
"name": "OzTAM",
"categoryId": 8,
"url": "https://oztam.com.au/",
"companyId": "oztam",
"source": "AdGuard"
},
"oppo": {
"name": "OPPO",
"categoryId": 101,
"url": "https://www.oppo.com/",
"companyId": "oppo",
"source": "AdGuard"
}, </s> add "kik": {
"name": "Kik",
"categoryId": 7,
"url": "https://kik.com/",
"companyId": "kik",
"source": "AdGuard"
}, </s> add "telstra": {
"name": "Telstra",
"categoryId": 8,
"url": "https://www.telstra.com.au/",
"companyId": "telstra",
"source": "AdGuard"
},
"medialab": {
"name": "MediaLab.AI Inc.",
"categoryId": 8,
"url": "https://medialab.la/",
"companyId": "medialab",
"source": "AdGuard"
}, </s> add "gmail": {
"name": "Gmail",
"categoryId": 13,
"url": "https://mail.google.com/",
"companyId": "google",
"source": "AdGuard"
}, </s> add "sectigo": {
"name": "Sectigo Limited",
"categoryId": 5,
"url": "https://www.solaredge.com/",
"companyId": "sectigo",
"source": "AdGuard"
}, </s> remove "companyId": "facebook",
</s> add "companyId": "meta",
|
https://github.com/AdguardTeam/AdGuardHome/commit/76a513cdaf3fa2e951843f8779b79d56975916df
|
client/src/helpers/filters/filters.js
|
keep replace keep keep keep keep keep
|
<mask> {
<mask> "timeUpdated": "2023-02-09T12:31:34.007Z",
<mask> "categories": {
<mask> "0": "audio_video_player",
<mask> "1": "comments",
<mask> "2": "customer_interaction",
<mask> "3": "pornvertising",
</s> Pull request 1748: upd-all
Merge in DNS/adguard-home from upd-all to master
Squashed commit of the following:
commit 7014e7631933f7d5cb58ec6fd1a221f497983e98
Author: Ainar Garipov <[email protected]>
Date: Tue Feb 21 17:57:35 2023 +0300
all: upd i18n, filters, trackers, services, tools </s> remove "companyId": "facebook",
</s> add "companyId": "meta", </s> add "oztam": {
"name": "OzTAM",
"categoryId": 8,
"url": "https://oztam.com.au/",
"companyId": "oztam",
"source": "AdGuard"
},
"oppo": {
"name": "OPPO",
"categoryId": 101,
"url": "https://www.oppo.com/",
"companyId": "oppo",
"source": "AdGuard"
}, </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard"
|
https://github.com/AdguardTeam/AdGuardHome/commit/76a513cdaf3fa2e951843f8779b79d56975916df
|
client/src/helpers/trackers/trackers.json
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> "facebook": {
<mask> "name": "Facebook",
<mask> "categoryId": 4,
<mask> "url": "https://www.facebook.com",
<mask> "companyId": "facebook"
<mask> },
<mask> "facebook_beacon": {
<mask> "name": "Facebook Beacon",
<mask> "categoryId": 7,
<mask> "url": "http://www.facebook.com/beacon/faq.php",
</s> Pull request 1748: upd-all
Merge in DNS/adguard-home from upd-all to master
Squashed commit of the following:
commit 7014e7631933f7d5cb58ec6fd1a221f497983e98
Author: Ainar Garipov <[email protected]>
Date: Tue Feb 21 17:57:35 2023 +0300
all: upd i18n, filters, trackers, services, tools </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard"
|
https://github.com/AdguardTeam/AdGuardHome/commit/76a513cdaf3fa2e951843f8779b79d56975916df
|
client/src/helpers/trackers/trackers.json
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> "facebook_beacon": {
<mask> "name": "Facebook Beacon",
<mask> "categoryId": 7,
<mask> "url": "http://www.facebook.com/beacon/faq.php",
<mask> "companyId": "facebook"
<mask> },
<mask> "facebook_cdn": {
<mask> "name": "Facebook CDN",
<mask> "categoryId": 9,
<mask> "url": "https://www.facebook.com",
</s> Pull request 1748: upd-all
Merge in DNS/adguard-home from upd-all to master
Squashed commit of the following:
commit 7014e7631933f7d5cb58ec6fd1a221f497983e98
Author: Ainar Garipov <[email protected]>
Date: Tue Feb 21 17:57:35 2023 +0300
all: upd i18n, filters, trackers, services, tools </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard"
|
https://github.com/AdguardTeam/AdGuardHome/commit/76a513cdaf3fa2e951843f8779b79d56975916df
|
client/src/helpers/trackers/trackers.json
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> "facebook_cdn": {
<mask> "name": "Facebook CDN",
<mask> "categoryId": 9,
<mask> "url": "https://www.facebook.com",
<mask> "companyId": "facebook"
<mask> },
<mask> "facebook_connect": {
<mask> "name": "Facebook Connect",
<mask> "categoryId": 6,
<mask> "url": "https://developers.facebook.com/connect.php",
</s> Pull request 1748: upd-all
Merge in DNS/adguard-home from upd-all to master
Squashed commit of the following:
commit 7014e7631933f7d5cb58ec6fd1a221f497983e98
Author: Ainar Garipov <[email protected]>
Date: Tue Feb 21 17:57:35 2023 +0300
all: upd i18n, filters, trackers, services, tools </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard"
|
https://github.com/AdguardTeam/AdGuardHome/commit/76a513cdaf3fa2e951843f8779b79d56975916df
|
client/src/helpers/trackers/trackers.json
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> "facebook_connect": {
<mask> "name": "Facebook Connect",
<mask> "categoryId": 6,
<mask> "url": "https://developers.facebook.com/connect.php",
<mask> "companyId": "facebook"
<mask> },
<mask> "facebook_conversion_tracking": {
<mask> "name": "Facebook Conversion Tracking",
<mask> "categoryId": 4,
<mask> "url": "http://www.facebook.com/",
</s> Pull request 1748: upd-all
Merge in DNS/adguard-home from upd-all to master
Squashed commit of the following:
commit 7014e7631933f7d5cb58ec6fd1a221f497983e98
Author: Ainar Garipov <[email protected]>
Date: Tue Feb 21 17:57:35 2023 +0300
all: upd i18n, filters, trackers, services, tools </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard"
|
https://github.com/AdguardTeam/AdGuardHome/commit/76a513cdaf3fa2e951843f8779b79d56975916df
|
client/src/helpers/trackers/trackers.json
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> "facebook_conversion_tracking": {
<mask> "name": "Facebook Conversion Tracking",
<mask> "categoryId": 4,
<mask> "url": "http://www.facebook.com/",
<mask> "companyId": "facebook"
<mask> },
<mask> "facebook_custom_audience": {
<mask> "name": "Facebook Custom Audience",
<mask> "categoryId": 4,
<mask> "url": "https://www.facebook.com",
</s> Pull request 1748: upd-all
Merge in DNS/adguard-home from upd-all to master
Squashed commit of the following:
commit 7014e7631933f7d5cb58ec6fd1a221f497983e98
Author: Ainar Garipov <[email protected]>
Date: Tue Feb 21 17:57:35 2023 +0300
all: upd i18n, filters, trackers, services, tools </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard"
|
https://github.com/AdguardTeam/AdGuardHome/commit/76a513cdaf3fa2e951843f8779b79d56975916df
|
client/src/helpers/trackers/trackers.json
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> "facebook_custom_audience": {
<mask> "name": "Facebook Custom Audience",
<mask> "categoryId": 4,
<mask> "url": "https://www.facebook.com",
<mask> "companyId": "facebook"
<mask> },
<mask> "facebook_graph": {
<mask> "name": "Facebook Social Graph",
<mask> "categoryId": 7,
<mask> "url": "https://developers.facebook.com/docs/reference/api/",
</s> Pull request 1748: upd-all
Merge in DNS/adguard-home from upd-all to master
Squashed commit of the following:
commit 7014e7631933f7d5cb58ec6fd1a221f497983e98
Author: Ainar Garipov <[email protected]>
Date: Tue Feb 21 17:57:35 2023 +0300
all: upd i18n, filters, trackers, services, tools </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard"
|
https://github.com/AdguardTeam/AdGuardHome/commit/76a513cdaf3fa2e951843f8779b79d56975916df
|
client/src/helpers/trackers/trackers.json
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> "facebook_graph": {
<mask> "name": "Facebook Social Graph",
<mask> "categoryId": 7,
<mask> "url": "https://developers.facebook.com/docs/reference/api/",
<mask> "companyId": "facebook"
<mask> },
<mask> "facebook_impressions": {
<mask> "name": "Facebook Impressions",
<mask> "categoryId": 4,
<mask> "url": "https://www.facebook.com/",
</s> Pull request 1748: upd-all
Merge in DNS/adguard-home from upd-all to master
Squashed commit of the following:
commit 7014e7631933f7d5cb58ec6fd1a221f497983e98
Author: Ainar Garipov <[email protected]>
Date: Tue Feb 21 17:57:35 2023 +0300
all: upd i18n, filters, trackers, services, tools </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard"
|
https://github.com/AdguardTeam/AdGuardHome/commit/76a513cdaf3fa2e951843f8779b79d56975916df
|
client/src/helpers/trackers/trackers.json
|
keep keep keep keep replace keep keep keep keep keep
|
<mask> "facebook_impressions": {
<mask> "name": "Facebook Impressions",
<mask> "categoryId": 4,
<mask> "url": "https://www.facebook.com/",
<mask> "companyId": "facebook"
<mask> },
<mask> "facebook_social_plugins": {
<mask> "name": "Facebook Social Plugins",
<mask> "categoryId": 7,
<mask> "url": "https://developers.facebook.com/plugins",
</s> Pull request 1748: upd-all
Merge in DNS/adguard-home from upd-all to master
Squashed commit of the following:
commit 7014e7631933f7d5cb58ec6fd1a221f497983e98
Author: Ainar Garipov <[email protected]>
Date: Tue Feb 21 17:57:35 2023 +0300
all: upd i18n, filters, trackers, services, tools </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard" </s> remove "companyId": "facebook"
</s> add "companyId": "meta",
"source": "AdGuard"
|
https://github.com/AdguardTeam/AdGuardHome/commit/76a513cdaf3fa2e951843f8779b79d56975916df
|
client/src/helpers/trackers/trackers.json
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.