Line 916... |
Line 916... |
916 |
[ -e /var/lib/named/etc/trusted_networks_acl.conf.default ] || cp /var/lib/named/etc/trusted_networks_acl.conf /var/lib/named/etc/trusted_networks_acl.conf.default
|
916 |
[ -e /var/lib/named/etc/trusted_networks_acl.conf.default ] || cp /var/lib/named/etc/trusted_networks_acl.conf /var/lib/named/etc/trusted_networks_acl.conf.default
|
917 |
[ -e /var/lib/named/etc/named.conf.default ] || cp /var/lib/named/etc/named.conf /var/lib/named/etc/named.conf.default
|
917 |
[ -e /var/lib/named/etc/named.conf.default ] || cp /var/lib/named/etc/named.conf /var/lib/named/etc/named.conf.default
|
918 |
[ -e /var/lib/named/var/named/master/localdomain.zone.default ] || cp /var/lib/named/var/named/master/localdomain.zone /var/lib/named/var/named/master/localdomain.zone.default
|
918 |
[ -e /var/lib/named/var/named/master/localdomain.zone.default ] || cp /var/lib/named/var/named/master/localdomain.zone /var/lib/named/var/named/master/localdomain.zone.default
|
919 |
$SED "s?127.0.0.1;.*?127.0.0.1; $CUSTOM_PRIVATE_NETWORK_MASK;?g" /var/lib/named/etc/trusted_networks_acl.conf
|
919 |
$SED "s?127.0.0.1;.*?127.0.0.1; $CUSTOM_PRIVATE_NETWORK_MASK;?g" /var/lib/named/etc/trusted_networks_acl.conf
|
920 |
$SED "s?listen-on.*?listen-on port 53 \{ 127.0.0.1; $PRIVATE_IP; \};?g" /var/lib/named/etc/named.conf
|
920 |
$SED "s?listen-on.*?listen-on port 53 \{ 127.0.0.1; $PRIVATE_IP; \};?g" /var/lib/named/etc/named.conf
|
921 |
$SED "s?^\/\/ include \"\/etc\/bogon_acl.conf\";.*?include \"\/etc\/bogon_acl.conf\";?g" /var/lib/named/etc/named.conf
|
921 |
# $SED "s?^\/\/ include \"\/etc\/bogon_acl.conf\";.*?include \"\/etc\/bogon_acl.conf\";?g" /var/lib/named/etc/named.conf
|
922 |
# On crée l'entrée pour le reverse
|
922 |
# On crée l'entrée pour le reverse
|
923 |
for i in $(seq $classe)
|
- |
|
924 |
do
|
- |
|
925 |
o[$i]=`echo $PRIVATE_NETWORK|cut -d"." -f$i`
|
- |
|
926 |
done
|
- |
|
927 |
for i in $(seq $classe -1 1)
|
923 |
for i in $(seq $classe -1 1)
|
928 |
do
|
924 |
do
|
929 |
echo -n "${o[$i]}." >> /tmp/rev.txt
|
925 |
echo -n `echo $PRIVATE_NETWORK|cut -d"." -f$i`. >> /tmp/rev.txt
|
930 |
done
|
926 |
done
|
931 |
echo "in-addr.arpa" >> /tmp/rev.txt
|
927 |
echo "in-addr.arpa" >> /tmp/rev.txt
|
932 |
reverse_addr=`cat /tmp/rev.txt`
|
928 |
reverse_addr=`cat /tmp/rev.txt`
|
933 |
rm -f /tmp/rev.txt
|
929 |
rm -f /tmp/rev.txt
|
934 |
cat << EOF >> /var/lib/named/etc/named.conf
|
930 |
cat << EOF >> /var/lib/named/etc/named.conf
|