Subversion Repositories ALCASAR

Rev

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

Rev 766 Rev 768
Line 1... Line 1...
1
#!/bin/sh
1
#!/bin/sh
2
# $Id: alcasar-iptables.sh 766 2011-11-10 22:29:41Z richard $
2
# $Id: alcasar-iptables.sh 768 2011-11-11 21:04:20Z richard $
3
# Script de mise en place des regles du parefeu d'Alcasar (mode normal)
3
# Script de mise en place des regles du parefeu d'Alcasar (mode normal)
4
# This script write the netfilter rules for ALCASAR
4
# This script write the netfilter rules for ALCASAR
5
# Rexy - 3abtux - CPN
5
# Rexy - 3abtux - CPN
6
#
6
#
7
# Reminders
7
# Reminders
Line 31... Line 31...
31
SSH=${SSH:=off}
31
SSH=${SSH:=off}
32
Admin_from_IP=${Admin_from_IP:="0.0.0.0/0.0.0.0"}			# Une @IP fixe peut-être fournie pour restreindre l'accès en ssh depuis l'extérieur (ex: 80.22.21.53/24) ( 0.0.0.0/0.0.0.0  = de n'importe où ! )
32
Admin_from_IP=${Admin_from_IP:="0.0.0.0/0.0.0.0"}			# Une @IP fixe peut-être fournie pour restreindre l'accès en ssh depuis l'extérieur (ex: 80.22.21.53/24) ( 0.0.0.0/0.0.0.0  = de n'importe où ! )
33
LDAP=`grep LDAP= $conf_file|cut -d"=" -f2`				# ldap external server active (on/off)
33
LDAP=`grep LDAP= $conf_file|cut -d"=" -f2`				# ldap external server active (on/off)
34
LDAP=${LDAP:=off}
34
LDAP=${LDAP:=off}
35
LDAP_IP=`grep LDAP_IP= $conf_file|cut -d"=" -f2`			# ldap external server IP address
35
LDAP_IP=`grep LDAP_IP= $conf_file|cut -d"=" -f2`			# ldap external server IP address
36
LDAP_IP=${LDAP_IP:="0.0.0.0"}
36
LDAP_IP=${LDAP_IP:="0.0.0.0/0.0.0.0"}
37
PRIVATE_NETWORK_MASK=$private_network/$private_prefix			# Lan IP address + prefix (192.168.182.0/24)
37
PRIVATE_NETWORK_MASK=$private_network/$private_prefix			# Lan IP address + prefix (192.168.182.0/24)
38
PRIVATE_IP=`echo $private_ip_mask | cut -d"/" -f1`			# ALCASAR LAN IP address
38
PRIVATE_IP=`echo $private_ip_mask | cut -d"/" -f1`			# ALCASAR LAN IP address
39
DNSSERVERS="$dns1,$dns2"						# first and second DNS IP servers addresses
39
DNSSERVERS="$dns1,$dns2"						# first and second DNS IP servers addresses
40
EXTIF="eth0"
40
EXTIF="eth0"
41
INTIF="eth1"
41
INTIF="eth1"