Line 1... |
Line 1... |
1 |
#!/bin/bash
|
1 |
#!/bin/bash
|
2 |
# $Id: alcasar.sh 1938 2016-06-12 15:12:06Z richard $
|
2 |
# $Id: alcasar.sh 1940 2016-06-12 22:09:49Z richard $
|
3 |
|
3 |
|
4 |
# alcasar.sh
|
4 |
# alcasar.sh
|
5 |
|
5 |
|
6 |
# ALCASAR Install script - CopyLeft ALCASAR Team [Rexy + 3abtux + Steweb + Crox + ...]
|
6 |
# ALCASAR Install script - CopyLeft ALCASAR Team [Rexy + 3abtux + Steweb + Crox + ...]
|
7 |
# Ce programme est un logiciel libre ; This software is free and open source
|
7 |
# Ce programme est un logiciel libre ; This software is free and open source
|
Line 1629... |
Line 1629... |
1629 |
$SED "s?safe=vss?safe=strict?g" $DIR_DG/lists/urlregexplist
|
1629 |
$SED "s?safe=vss?safe=strict?g" $DIR_DG/lists/urlregexplist
|
1630 |
# creation of the custom BL and WL categorie named "ossi" (for domain names & ip only)
|
1630 |
# creation of the custom BL and WL categorie named "ossi" (for domain names & ip only)
|
1631 |
if [ "$mode" != "update" ]; then
|
1631 |
if [ "$mode" != "update" ]; then
|
1632 |
mkdir -p $DIR_DG/lists/blacklists/ossi-bl
|
1632 |
mkdir -p $DIR_DG/lists/blacklists/ossi-bl
|
1633 |
touch $DIR_DG/lists/blacklists/ossi-bl/domains
|
1633 |
touch $DIR_DG/lists/blacklists/ossi-bl/domains
|
- |
|
1634 |
echo "ossi-bl" >> $DIR_DEST_ETC/alcasar-bl-categories-enabled
|
1634 |
mkdir -p $DIR_DG/lists/blacklists/ossi-wl
|
1635 |
mkdir -p $DIR_DG/lists/blacklists/ossi-wl
|
1635 |
touch $DIR_DG/lists/blacklists/ossi-wl/domains
|
1636 |
touch $DIR_DG/lists/blacklists/ossi-wl/domains
|
- |
|
1637 |
echo "ossi-wl" >> $DIR_DEST_ETC/alcasar-wl-categories-enabled
|
1636 |
# add custom ALCASAR BL files
|
1638 |
# add custom ALCASAR BL files
|
1637 |
for x in $(ls $DIR_BLACKLIST | grep -v "^blacklist")
|
1639 |
for x in $(ls $DIR_BLACKLIST | grep -v "^blacklist")
|
1638 |
do
|
1640 |
do
|
1639 |
mkdir $DIR_DG/lists/blacklists/ossi-bl-$x
|
1641 |
mkdir $DIR_DG/lists/blacklists/ossi-bl-$x
|
1640 |
cp $DIR_BLACKLIST/$x $DIR_DG/lists/blacklists/ossi-bl-$x/domains
|
1642 |
cp $DIR_BLACKLIST/$x $DIR_DG/lists/blacklists/ossi-bl-$x/domains
|
- |
|
1643 |
echo "ossi-bl-$x" >> $DIR_DEST_ETC/alcasar-bl-categories-enabled
|
1641 |
done
|
1644 |
done
|
1642 |
chown -R dansguardian:apache $DIR_DG $DIR_DEST_SHARE
|
1645 |
chown -R dansguardian:apache $DIR_DG $DIR_DEST_SHARE
|
1643 |
chmod -R g+rw $DIR_DG $DIR_DEST_SHARE
|
1646 |
chmod -R g+rw $DIR_DG $DIR_DEST_SHARE
|
1644 |
# adapt the Toulouse BL to ALCASAR architecture
|
1647 |
# adapt the Toulouse BL to ALCASAR architecture
|
1645 |
$DIR_DEST_BIN/alcasar-bl.sh --adapt
|
1648 |
$DIR_DEST_BIN/alcasar-bl.sh --adapt
|