Subversion Repositories ALCASAR

Rev

Rev 1870 | Rev 1874 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log

Rev 1870 Rev 1873
Line 1... Line 1...
1
#/bin/bash
1
#/bin/bash
2
 
2
 
3
# $Id: alcasar-bl.sh 1870 2016-05-04 14:55:06Z raphael.pion $
3
# $Id: alcasar-bl.sh 1873 2016-05-05 10:31:32Z richard $
4
 
4
 
5
# alcasar-bl.sh
5
# alcasar-bl.sh
6
# by Franck BOUIJOUX and Richard REY
6
# by Franck BOUIJOUX and Richard REY
7
# This script is distributed under the Gnu General Public License (GPL)
7
# This script is distributed under the Gnu General Public License (GPL)
8
 
8
 
Line 153... Line 153...
153
case $args in
153
case $args in
154
	-\? | -h* | --h*)
154
	-\? | -h* | --h*)
155
		echo "$usage"
155
		echo "$usage"
156
		exit 0
156
		exit 0
157
		;;
157
		;;
158
	# Retrieve Toulouse BL
158
	# Retrieve Toulouse University BL
159
	-download | --download)
159
	-download | --download)
160
		rm -rf /tmp/con_ok.html
160
		rm -rf /tmp/con_ok.html
161
		`/usr/bin/curl $BL_SERVER -# -o /tmp/con_ok.html`
161
		`/usr/bin/curl $BL_SERVER -# -o /tmp/con_ok.html`
162
		if [ ! -e /tmp/con_ok.html ]
162
		if [ ! -e /tmp/con_ok.html ]
163
		then
163
		then
Line 172... Line 172...
172
		;;		
172
		;;		
173
	# enable/disable categories (used only during the alcasar install process)
173
	# enable/disable categories (used only during the alcasar install process)
174
	-cat_choice | --cat_choice)
174
	-cat_choice | --cat_choice)
175
		cat_choice
175
		cat_choice
176
		;;
176
		;;
177
	# Adapt Toulouse BL to ALCASAR architecture (dnsmasq + DG + iptables)
177
	# Adapt Toulouse University BL to ALCASAR architecture (dnsmasq + DG + iptables)
178
	-adapt | --adapt)
178
	-adapt | --adapt)
179
		echo -n "Toulouse BlackList migration process. Please wait : "
179
		echo -n "Adaptation process of Toulouse University blackList. Please wait : "
180
	
180
	
181
	
181
	
182
		if [ -f $DIR_tmp/blacklists.tar.gz ] # when downloading the last version of the BL
182
		if [ -f $DIR_tmp/blacklists.tar.gz ] # when downloading the last version of the BL
183
		then
183
		then
184
			[ -d $DIR_DG_BL/ossi ] && mv $DIR_DG_BL/ossi $DIR_tmp
184
			[ -d $DIR_DG_BL/ossi ] && mv $DIR_DG_BL/ossi $DIR_tmp