Skip to content

Commit dae9da8

Browse files
committed
Hide named hostname, server-id and version for bind.
1 parent 73cd6c5 commit dae9da8

File tree

7 files changed

+126
-2
lines changed

7 files changed

+126
-2
lines changed
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
options {
2+
directory "/var/cache/bind";
3+
// If there is a firewall between you and nameservers you want
4+
// to talk to, you may need to fix the firewall to allow multiple
5+
// ports to talk. See http://www.kb.cert.org/vuls/id/800113
6+
// If your ISP provided one or more IP addresses for stable
7+
// nameservers, you probably want to use them as forwarders.
8+
// Uncomment the following block, and insert the addresses replacing
9+
// the all-0's placeholder.
10+
// forwarders {
11+
// 0.0.0.0;
12+
// };
13+
//========================================================================
14+
// If BIND logs error messages about the root key being expired,
15+
// you will need to update your keys. See https://www.isc.org/bind-keys
16+
//========================================================================
17+
dnssec-validation auto;
18+
auth-nxdomain no;
19+
allow-recursion { 127.0.0.1; ::1; };
20+
allow-transfer {"none";};
21+
hostname none;
22+
server-id none;
23+
version none;
24+
};
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
options {
2+
directory "/var/cache/bind";
3+
// If there is a firewall between you and nameservers you want
4+
// to talk to, you may need to fix the firewall to allow multiple
5+
// ports to talk. See http://www.kb.cert.org/vuls/id/800113
6+
// If your ISP provided one or more IP addresses for stable
7+
// nameservers, you probably want to use them as forwarders.
8+
// Uncomment the following block, and insert the addresses replacing
9+
// the all-0's placeholder.
10+
// forwarders {
11+
// 0.0.0.0;
12+
// };
13+
//========================================================================
14+
// If BIND logs error messages about the root key being expired,
15+
// you will need to update your keys. See https://www.isc.org/bind-keys
16+
//========================================================================
17+
dnssec-validation auto;
18+
auth-nxdomain no;
19+
allow-recursion { 127.0.0.1; ::1; };
20+
allow-transfer {"none";};
21+
hostname none;
22+
server-id none;
23+
version none;
24+
};

install/hst-install-debian.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1154,9 +1154,11 @@ fi
11541154

11551155
if [ "$named" = 'yes' ]; then
11561156
cp -f $hestiacp/bind/named.conf /etc/bind/
1157-
sed -i "s%listen-on%//listen%" /etc/bind/named.conf.options
1157+
cp -f $hestiacp/bind/named.conf.options /etc/bind/
11581158
chown root:bind /etc/bind/named.conf
1159+
chown root:bind /etc/bind/named.conf.options
11591160
chmod 640 /etc/bind/named.conf
1161+
chmod 640 /etc/bind/named.conf.options
11601162
aa-complain /usr/sbin/named 2>/dev/null
11611163
if [ "$apparmor" = 'yes' ]; then
11621164
echo "/home/** rwm," >> /etc/apparmor.d/local/usr.sbin.named 2>/dev/null

install/hst-install-ubuntu.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1138,9 +1138,11 @@ fi
11381138

11391139
if [ "$named" = 'yes' ]; then
11401140
cp -f $hestiacp/bind/named.conf /etc/bind/
1141-
sed -i "s%listen-on%//listen%" /etc/bind/named.conf.options
1141+
cp -f $hestiacp/bind/named.conf.options /etc/bind/
11421142
chown root:bind /etc/bind/named.conf
1143+
chown root:bind /etc/bind/named.conf.options
11431144
chmod 640 /etc/bind/named.conf
1145+
chmod 640 /etc/bind/named.conf.options
11441146
aa-complain /usr/sbin/named > /dev/null 2>&1
11451147
echo "/home/** rwm," >> /etc/apparmor.d/local/usr.sbin.named 2>/dev/null
11461148
service apparmor status > /dev/null 2>&1
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
options {
2+
directory "/var/cache/bind";
3+
// If there is a firewall between you and nameservers you want
4+
// to talk to, you may need to fix the firewall to allow multiple
5+
// ports to talk. See http://www.kb.cert.org/vuls/id/800113
6+
// If your ISP provided one or more IP addresses for stable
7+
// nameservers, you probably want to use them as forwarders.
8+
// Uncomment the following block, and insert the addresses replacing
9+
// the all-0's placeholder.
10+
// forwarders {
11+
// 0.0.0.0;
12+
// };
13+
//========================================================================
14+
// If BIND logs error messages about the root key being expired,
15+
// you will need to update your keys. See https://www.isc.org/bind-keys
16+
//========================================================================
17+
dnssec-validation auto;
18+
auth-nxdomain no;
19+
allow-recursion { 127.0.0.1; ::1; };
20+
allow-transfer {"none";};
21+
hostname none;
22+
server-id none;
23+
version none;
24+
};
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
options {
2+
directory "/var/cache/bind";
3+
// If there is a firewall between you and nameservers you want
4+
// to talk to, you may need to fix the firewall to allow multiple
5+
// ports to talk. See http://www.kb.cert.org/vuls/id/800113
6+
// If your ISP provided one or more IP addresses for stable
7+
// nameservers, you probably want to use them as forwarders.
8+
// Uncomment the following block, and insert the addresses replacing
9+
// the all-0's placeholder.
10+
// forwarders {
11+
// 0.0.0.0;
12+
// };
13+
//========================================================================
14+
// If BIND logs error messages about the root key being expired,
15+
// you will need to update your keys. See https://www.isc.org/bind-keys
16+
//========================================================================
17+
dnssec-validation auto;
18+
auth-nxdomain no;
19+
allow-recursion { 127.0.0.1; ::1; };
20+
allow-transfer {"none";};
21+
hostname none;
22+
server-id none;
23+
version none;
24+
};
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
options {
2+
directory "/var/cache/bind";
3+
// If there is a firewall between you and nameservers you want
4+
// to talk to, you may need to fix the firewall to allow multiple
5+
// ports to talk. See http://www.kb.cert.org/vuls/id/800113
6+
// If your ISP provided one or more IP addresses for stable
7+
// nameservers, you probably want to use them as forwarders.
8+
// Uncomment the following block, and insert the addresses replacing
9+
// the all-0's placeholder.
10+
// forwarders {
11+
// 0.0.0.0;
12+
// };
13+
//========================================================================
14+
// If BIND logs error messages about the root key being expired,
15+
// you will need to update your keys. See https://www.isc.org/bind-keys
16+
//========================================================================
17+
dnssec-validation auto;
18+
auth-nxdomain no;
19+
allow-recursion { 127.0.0.1; ::1; };
20+
allow-transfer {"none";};
21+
hostname none;
22+
server-id none;
23+
version none;
24+
};

0 commit comments

Comments
 (0)