Dns over Tls (dot) / Dns over https (doh) with BIND9
Langsung setelah lama tidak mengikuti dns server bind versi baru mulai versi 9.17 sudah support doh dan dot, di sini memakai bind 9.18 di debian 11
tambahkan repo
deb https://packages.sury.org/bind/ bullseye main
pastikan gpg sudah di add dan install bind
# apt install bind9
tambah di bind konfig nya /etc/bind/named.conf
tls server-tls {
cert-file "/etc/bind/ssl/cert.crt";
key-file "/etc/bind/ssl/privatekey.pem";
dhparam-file "/etc/bind/ssl/ssl-dhparams.pem";
protocols { TLSv1.2; TLSv1.3; };
ciphers "HIGH:!kRSA:!aNULL:!eNULL:!RC4:!3DES:!MD5:!EXP:!PSK:!SRP:!DSS:!SHA1:!SHA256:!SHA384";
prefer-server-ciphers yes;
session-tickets no;
};
options {
directory "/var/cache/bind";
dnssec-validation auto;
listen-on port 853 tls server-tls { any; };
listen-on port 443 tls server-tls http default {any;};
forwarders {
8.8.8.8;
1.1.1.1;
};
recursion yes;
allow-query { any; };
};
check config
# named-checkconf /etc/bind/named.conf
start serice
# systemctl start named.service
check status
# systemctl status named.service
Test query tls di sisi client
user@tux:~> kdig -d @105.15.110.xx +tls-ca +tls-host=dns.domain.com detik.com
Untuk Test query over https di sisi client jika sudah install bind-utility 9.18.18
dig +tls @dns.domain.com +tls-ca +tls-host=dns.domain.com detik.com
dig +https @dns.domain.com +tls-ca +tls-host=dns.domain.com detik.com
Untuk lebih jelas dan detil bisa baca di sini
https://bind9.readthedocs.io/en/v9_18_0/
Untuk bind 9.19 sudah support forwarders via tls
Untuk opendns
tls OpenDNS-DoT {
ca-file "/etc/ssl/certs/IdenTrust_Commercial_Root_CA_1.pem";
remote-hostname "dns.opendns.com";
};
forwarders port 853 tls OpenDNS-DoT {
// OpenDNS public
208.67.220.220;
208.67.222.222;
};
Untuk adguard
tls adguard {
ca-file "/etc/ssl/certs/USERTrust_ECC_Certification_Authority.pem";
remote-hostname "dns.adguard.com";
};
forwarders port 853 tls adguard {
// adguard public
94.140.14.14;
94.140.15.15;
};
Untuk lebih detil nya bisa baca di
https://downloads.isc.org/isc/bind9/9.19.16/doc/arm/html/
Salam
Semoga bermanfaat
Komentar
Posting Komentar