1,6 → 1,8 |
<html> |
<? |
# on discrimine les accès directs sur Alcasar par rapport aux redirections |
$private_ip = "192.168.182.1"; |
if (($_SERVER['HTTP_HOST'] == $private_ip) || ($_SERVER['HTTP_HOST'] == "alcasar")){$direct_access="true";} else {$direct_access="false";} |
# Choice of language |
$Language = 'en'; |
if(isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])){ |
8,23 → 10,29 |
$Language = strtolower(substr(chop($Langue[0]),0,2)); } |
if($Language == 'fr'){ |
$l_access_denied = "ACCÈS REFUSÉ"; |
$l_access_controled = "ACCÈS CONTRÔLÉ"; |
$l_required_domain = "Site WEB demandé"; |
$l_explain = "Vous tentez d'accéder à une ressource dont le contenu est réputé contenir des informations inappropriées."; |
$l_explain_alcasar = "L'accès au centre de gestion du portail ALCASAR (ALCASAR Control Center) nécéssite une authentification sécurisée."; |
$l_contact = "Contactez le responsable de la sécurité (OSSI/RSSI) si vous pensez que ce filtrage est abusif."; |
$l_contact_alcasar = "<a href=\"https://alcasar/acc\">Accès au centre de gestion</A>"; |
$l_welcome = "Bienvenue sur le portail captif ALCASAR.<br>Vous pouvez : "; |
$l_acc_access = "<a href=\"https://i$private_ip/acc\">Accéder au centre de gestion (ALCASAR Control Center)</A>"; |
$l_internet_access = "<a href=\"https://$private_ip/intercept.php\">Tester l'interception de l'accès à Internet</A>"; |
} |
else { |
$l_access_denied = "ACCESS DENIED"; |
$l_access_controled = "ACCESS CONTROLED"; |
$l_required_domain = "Required WEB site"; |
$l_explain = "Your portal has just detected that the Internet access is down"; |
$l_explain_alcasar = "In order to access to the ALCASAR Control Center (ACC) you should authenticate threw a secure connection."; |
$l_contact = "Contact your Internet provider responsive for more information"; |
$l_contact_alcasar = "<a href=\"https://alcasar/acc\">ALCASAR Control Center access</A>"; |
$l_welcome = "Welcome on the captive portal ALCASAR.<br>You can connect: "; |
$l_acc_access = "<a href=\"https://$private_ip/acc\">to the ALCASAR Control Center (ACC)</A>"; |
$l_internet_access = "<a href=\"https://$private_ip/intercept.php\">Internet intercept page for Test</A>"; |
} |
?> |
<head> |
<title><? echo "ALCASAR - $l_access_denied";?></title> |
<title> |
<? if ($direct_access == "true"){echo "ALCASAR - $l_access_controled";} else {echo "ALCASAR - $l_access_denied";}?> |
</title> |
</head> |
<body bgcolor=#FFFFFF> |
<center> |
32,7 → 40,7 |
<tr> |
<td colspan=2 bgcolor=#FEA700 height=100 align=center> |
<font face=arial,helvetica size=6> |
<b><? echo "$l_access_denied";?></b> |
<? if ($direct_access == "true"){echo "<b>$l_access_controled</b>";} else {echo "<b>$l_access_denied</b>";}?> |
</td> |
</tr> |
<tr> |
47,21 → 55,16 |
<img src="images/logo-alcasar.png"> |
<BR><CENTER>ALCASAR</CENTER> |
</td> |
<td width=550 bgcolor=#FFFFFF align=center valign=center> |
<td width=550 bgcolor=#FFFFFF valign=center> |
<font face=arial,helvetica color=black> |
<font size=3> |
<br><br><br><br> |
<? |
# on traite les accès directs sur Alcasar par rapport aux redirections |
if (($_SERVER['HTTP_HOST'] == $private_ip) || ($_SERVER['HTTP_HOST'] == "alcasar")){ |
echo "$l_explain_alcasar <br><br> $l_contact_alcasar";} |
if ($direct_access == "true"){ |
echo "<center>$l_welcome</center> <br><li> $l_acc_access <li> $l_internet_access";} |
else {echo "$l_explain <br><br> $l_contact";} |
?> |
<br><br><br><br> |
</td> |
</tr> |
</table> |
</body> |
</html> |
|
|