Line 1... |
Line 1... |
1 |
#/bin/bash
|
1 |
#/bin/bash
|
2 |
# $Id: alcasar-conf.sh 838 2012-03-14 22:56:41Z richard $
|
2 |
# $Id: alcasar-conf.sh 841 2012-03-18 22:19:04Z richard $
|
3 |
|
3 |
|
4 |
# alcasar-conf.sh
|
4 |
# alcasar-conf.sh
|
5 |
# by Richard REY
|
5 |
# by Richard REY
|
6 |
# This script is distributed under the Gnu General Public License (GPL)
|
6 |
# This script is distributed under the Gnu General Public License (GPL)
|
7 |
|
7 |
|
Line 77... |
Line 77... |
77 |
cp -rf /etc/dansguardian/lists/blacklists/ossi $DIR_UPDATE
|
77 |
cp -rf /etc/dansguardian/lists/blacklists/ossi $DIR_UPDATE
|
78 |
# sauvegarde des fichiers : de conf, de filtrage, d'exception, digest, etc.
|
78 |
# sauvegarde des fichiers : de conf, de filtrage, d'exception, digest, etc.
|
79 |
mkdir $DIR_UPDATE/etc/
|
79 |
mkdir $DIR_UPDATE/etc/
|
80 |
cp -rf $DIR_ETC/* $DIR_UPDATE/etc/
|
80 |
cp -rf $DIR_ETC/* $DIR_UPDATE/etc/
|
81 |
# particularité des versions
|
81 |
# particularité des versions
|
- |
|
82 |
rm -f $DIR_UPDATE/etc/alcasar-macallowed # macallowed is replaced with macauth
|
82 |
# si version <= 2.0
|
83 |
# si version <= 2.0
|
83 |
if [ $MAJ_RUNNING_VERSION -lt 2 ] || ([ $MAJ_RUNNING_VERSION -eq 2 ] && [ $MIN_RUNNING_VERSION -eq 0 ])
|
84 |
if [ $MAJ_RUNNING_VERSION -lt 2 ] || ([ $MAJ_RUNNING_VERSION -eq 2 ] && [ $MIN_RUNNING_VERSION -eq 0 ])
|
84 |
then
|
85 |
then
|
85 |
rm -f $DIR_UPDATE/etc/alcasar-dns-name # changement de format
|
86 |
rm -f $DIR_UPDATE/etc/alcasar-dns-name # changement de format
|
86 |
rm -f $DIR_UPDATE/etc/alcasar-macallowed # ajout d'un commentaire par @MAC
|
- |
|
87 |
rm -rf $DIR_UPDATE/etc/digest # hostname=alcasar
|
87 |
rm -rf $DIR_UPDATE/etc/digest # hostname=alcasar
|
88 |
if [ -e $DIR_UPDATE/etc/alcasar-uamallowed ]; then
|
88 |
if [ -e $DIR_UPDATE/etc/alcasar-uamallowed ]; then
|
89 |
uamallowed=`cat $DIR_UPDATE/etc/alcasar-uamallowed`
|
89 |
uamallowed=`cat $DIR_UPDATE/etc/alcasar-uamallowed`
|
90 |
if [ $uamallowed == "uamallowed=\"\"" ]
|
90 |
if [ $uamallowed == "uamallowed=\"\"" ]
|
91 |
then rm -f $DIR_UPDATE/etc/alcasar-uamallowed # un uamallowed 'vide' perturbe coova
|
91 |
then rm -f $DIR_UPDATE/etc/alcasar-uamallowed # un uamallowed 'vide' perturbe coova
|