AdguardTeam / AdguardTeam/AdGuardHome

DNS Rewrites: Mix subdomain and CNAME wildcard

Abierto
#7,063 1 comentario 3 reacciones 0 asignados Ver en GitHub
Lenguaje dominante
TypeScript
Estrellas
36.9k
Forks
2.5k
Métricas de merge de PR
Sin PR fusionados en 30 d

Descripción

### Prerequisites

- [X] I have checked the [Wiki](https://github.com/AdguardTeam/AdGuardHome/wiki) and [Discussions](https://github.com/AdguardTeam/AdGuardHome/discussions/categories/q-a) and found no answer

- [X] I have searched other issues and found no duplicates

- [X] I want to report a bug and not [ask a question or ask for help](https://github.com/AdguardTeam/AdGuardHome/discussions/categories/q-a)

- [X] I have set up AdGuard Home correctly and [configured clients to use it](https://github.com/AdguardTeam/AdGuardHome/wiki/Clients). (Use the [Discussions](https://github.com/AdguardTeam/AdGuardHome/discussions/categories/q-a) for help with installing and configuring clients.)

### Platform (OS and CPU architecture)

Darwin (aka macOS), AMD64 (aka x86_64)

### Installation

Other (please mention in the description)

### Setup

On one machine

### AdGuard Home version

0.107.50

### Action

Run AdguardHome from terminal, bind to 0.0.0.0:53, leave the rest default, then add 3 following DSN Rewrites.

```conf
abc.home 1.1.1.1
*.abc.home abc.home
x.abc.home 2.2.2.2
```

```sh
dig x.abc.home 127.0.0.1
```

### Expected result

```
; <<>> DiG 9.10.6 <<>> x.abc.home 127.0.0.1
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 10398
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0

;; QUESTION SECTION:
;x.abc.home. IN A

;; ANSWER SECTION:
x.abc.home. 10 IN A 2.2.2.2
```

### Actual result

```
; <<>> DiG 9.10.6 <<>> x.abc.home 127.0.0.1
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 38526
;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 0

;; QUESTION SECTION:
;x.abc.home. IN A

;; ANSWER SECTION:
x.abc.home. 10 IN CNAME abc.home.
abc.home. 10 IN A 1.1.1.1
```

### Additional information and/or screenshots

If `*.abc.home` value is set to IP instead of CNAME as following, then the result will be correct as expected.

```conf
abc.home. 1.1.1.1
*.abc.home 1.1.1.1
x.abc.home. 2.2.2.2
```

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.