Subversion Repositories ALCASAR

Rev

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

Rev 2446 Rev 2447
Line 1... Line 1...
1
#!/bin/bash
1
#!/bin/bash
2
#  $Id: alcasar.sh 2446 2017-12-03 23:07:18Z richard $ 
2
#  $Id: alcasar.sh 2447 2017-12-04 23:05:51Z 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 1100... Line 1100...
1100
# INFO : To connect from outside (EAP), add the EAP virtual server (link in sites-enabled) and inner-tunnel modules (link in mods-enabled) 
1100
# INFO : To connect from outside (EAP), add the EAP virtual server (link in sites-enabled) and inner-tunnel modules (link in mods-enabled) 
1101
 
1101
 
1102
# Set modules 
1102
# Set modules 
1103
# Set only usefull modules for ALCASAR (ldap is enabled only via ACC)
1103
# Set only usefull modules for ALCASAR (ldap is enabled only via ACC)
1104
    rm -rf  /etc/raddb/mods-enabled/*
1104
    rm -rf  /etc/raddb/mods-enabled/*
1105
    for mods in sql sqlcounter attr_filter expiration logintime pap expr ldap
1105
    for mods in sql sqlcounter attr_filter expiration logintime pap expr
1106
        do
1106
        do
1107
        ln -s /etc/raddb/mods-available/$mods /etc/raddb/mods-enabled/$mods
1107
        ln -s /etc/raddb/mods-available/$mods /etc/raddb/mods-enabled/$mods
1108
        done
1108
        done
1109
# Configure SQL mod
1109
# Configure SQL mod
1110
	[ -e /etc/raddb/mods-available/sql.default ] || cp /etc/raddb/mods-available/sql /etc/raddb/mods-available/sql.default
1110
	[ -e /etc/raddb/mods-available/sql.default ] || cp /etc/raddb/mods-available/sql /etc/raddb/mods-available/sql.default
Line 2096... Line 2096...
2096
	echo "HTTPS_LOGIN=on" >> $CONF_FILE
2096
	echo "HTTPS_LOGIN=on" >> $CONF_FILE
2097
	echo "HTTPS_CHILLI=off" >> $CONF_FILE
2097
	echo "HTTPS_CHILLI=off" >> $CONF_FILE
2098
	echo "SSH=on" >> $CONF_FILE
2098
	echo "SSH=on" >> $CONF_FILE
2099
	echo "SSH_ADMIN_FROM=0.0.0.0/0.0.0.0" >> $CONF_FILE
2099
	echo "SSH_ADMIN_FROM=0.0.0.0/0.0.0.0" >> $CONF_FILE
2100
	echo "LDAP=off" >> $CONF_FILE
2100
	echo "LDAP=off" >> $CONF_FILE
2101
	echo "LDAP_IP=0.0.0.0/0.0.0.0" >> $CONF_FILE
2101
	echo "LDAP_SERVER=127.0.0.1" >> $CONF_FILE
-
 
2102
    echo "LDAP_BASE=ou=my_lan;dc=server_name;dc=localdoamin" >> $CONF_FILE
-
 
2103
    echo "LDAP_UID=sAMAccountName" >> $CONF_FILE
-
 
2104
    echo "LDAP_FILTER=" >> $CONF_FILE
-
 
2105
    echo "LDAP_USER=alcasar" >> $CONF_FILE
-
 
2106
    echo "LDAP_PASSWORD=" >> $CONF_FILE
2102
	echo "MULTIWAN=off" >> $CONF_FILE
2107
    echo "MULTIWAN=off" >> $CONF_FILE
2103
	echo "FAILOVER=30" >> $CONF_FILE
2108
	echo "FAILOVER=30" >> $CONF_FILE
2104
	echo "## WANx=active,@IPx/mask,GWx,Weight,MTUx" >> $CONF_FILE
2109
	echo "## WANx=active,@IPx/mask,GWx,Weight,MTUx" >> $CONF_FILE
2105
	echo "#WAN1=\"1,$EXTIF:1,192.168.2.20/24,192.168.2.6,1,1500\"" >> $CONF_FILE
2110
	echo "#WAN1=\"1,$EXTIF:1,192.168.2.20/24,192.168.2.6,1,1500\"" >> $CONF_FILE
2106
	echo "#WAN2=\"1,$EXTIF:2,192.168.3.20/24,192.168.3.1,2,1500\"" >> $CONF_FILE
2111
	echo "#WAN2=\"1,$EXTIF:2,192.168.3.20/24,192.168.3.1,2,1500\"" >> $CONF_FILE
2107
# Prompt customisation (colors)
2112
# Prompt customisation (colors)