Line 1... |
Line 1... |
1 |
#!/bin/bash
|
1 |
#!/bin/bash
|
2 |
# $Id: alcasar.sh 994 2012-11-18 17:13:24Z franck $
|
2 |
# $Id: alcasar.sh 1000 2012-12-08 14:23:32Z richard $
|
3 |
|
3 |
|
4 |
# alcasar.sh
|
4 |
# alcasar.sh
|
5 |
|
5 |
|
6 |
# ALCASAR - Portail captif d'accès à l'Internet - Copyright (C) [2005] [ALcasar team - Rexy - 3abtux - ...]
|
6 |
# ALCASAR - Portail captif d'accès à l'Internet - Copyright (C) [2005] [ALcasar team - Rexy - 3abtux - ...]
|
7 |
# Ce programme est un logiciel libre ; vous pouvez le redistribuer et/ou le modifier au titre des clauses de la Licence Publique Générale GNU,
|
7 |
# Ce programme est un logiciel libre ; vous pouvez le redistribuer et/ou le modifier au titre des clauses de la Licence Publique Générale GNU,
|
Line 1334... |
Line 1334... |
1334 |
# block all SSL and CONNECT tunnels specified only as an IP
|
1334 |
# block all SSL and CONNECT tunnels specified only as an IP
|
1335 |
*ips
|
1335 |
*ips
|
1336 |
# block all sites specified only by an IP
|
1336 |
# block all sites specified only by an IP
|
1337 |
*ip
|
1337 |
*ip
|
1338 |
EOF
|
1338 |
EOF
|
1339 |
# On ajoute Bing et Youtube à la récriture d'URL liée au contrôle scolaire/parental
|
1339 |
# Add Bing and Youtube to the safesearch url regext list (parental control)
|
1340 |
cat <<EOF >> $DIR_DG/lists/urlregexplist
|
1340 |
cat <<EOF >> $DIR_DG/lists/urlregexplist
|
1341 |
# Bing - add 'adlt=strict'
|
1341 |
# Bing - add 'adlt=strict'
|
1342 |
#"(^http://[0-9a-z]+\.bing\.[a-z]+[-/%.0-9a-z]*\?)(.*)"->"\1\2&adlt=strict"
|
1342 |
#"(^http://[0-9a-z]+\.bing\.[a-z]+[-/%.0-9a-z]*\?)(.*)"->"\1\2&adlt=strict"
|
1343 |
# Youtube - add 'edufilter=your_ID'
|
1343 |
# Youtube - add 'edufilter=your_ID'
|
1344 |
#"(^http://[0-9a-z]+\.youtube\.[a-z]+[-/%.0-9a-z]*\?)(.*)"->"\1\2&edufilter=ABCD1234567890abcdef"
|
1344 |
#"(^http://[0-9a-z]+\.youtube\.[a-z]+[-/%.0-9a-z]*\?)(.*)"->"\1\2&edufilter=ABCD1234567890abcdef"
|
1345 |
EOF
|
1345 |
EOF
|
- |
|
1346 |
# change the the google safesearch ("safe=strict" instead of "safe=vss")
|
- |
|
1347 |
$SED "s?safe=vss?safe=strict?g" $DIR_DG/lists/urlregexlist
|
1346 |
chown -R dansguardian:apache $DIR_DG
|
1348 |
chown -R dansguardian:apache $DIR_DG
|
1347 |
chmod -R g+rw $DIR_DG
|
1349 |
chmod -R g+rw $DIR_DG
|
1348 |
# On crée la structure du DNS-blackhole :
|
1350 |
# On crée la structure du DNS-blackhole :
|
1349 |
mkdir $DIR_DEST_ETC/{alcasar-dnsfilter-available,alcasar-dnsfilter-enabled}
|
1351 |
mkdir $DIR_DEST_ETC/{alcasar-dnsfilter-available,alcasar-dnsfilter-enabled}
|
1350 |
chown -R 770 $DIR_DEST_ETC/{alcasar-dnsfilter-available,alcasar-dnsfilter-enabled}
|
1352 |
chown -R 770 $DIR_DEST_ETC/{alcasar-dnsfilter-available,alcasar-dnsfilter-enabled}
|