Subversion Repositories ALCASAR

Rev

Rev 2134 | Rev 2186 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log

Rev 2134 Rev 2136
1
<?php
1
<?php
2
# $Id: index.php 2134 2017-03-12 19:53:15Z richard $
2
# $Id: index.php 2136 2017-03-16 23:09:43Z richard $
3
#
3
#
4
# index.php for ALCASAR by Rexy
4
# index.php for ALCASAR by Rexy
5
# UI & css style by stephane ERARD
5
# UI & css style by stephane ERARD
6
# The contents of this file may be used under the terms of the GNU
6
# The contents of this file may be used under the terms of the GNU
7
# General Public License Version 2, provided that the above copyright
7
# General Public License Version 2, provided that the above copyright
8
# notice and this permission notice is included in all copies or
8
# notice and this permission notice is included in all copies or
9
# substantial portions of the software.
9
# substantial portions of the software.
10
/****************************************************************
10
/****************************************************************
11
*			GLOBAL FILE PATHS			*
11
*			GLOBAL FILE PATHS			*
12
*****************************************************************/
12
*****************************************************************/
13
define ("CONF_FILE", "/usr/local/etc/alcasar.conf");
13
define ("CONF_FILE", "/usr/local/etc/alcasar.conf");
14
 
14
 
15
/****************************************************************
15
/****************************************************************
16
*			FILE reading test			*
16
*			FILE reading test			*
17
*****************************************************************/
17
*****************************************************************/
18
$conf_files=array(CONF_FILE);
18
$conf_files=array(CONF_FILE);
19
foreach ($conf_files as $file){
19
foreach ($conf_files as $file){
20
	if (!file_exists($file)){
20
	if (!file_exists($file)){
21
		exit("File ".$file." unknown");
21
		exit("File ".$file." unknown");
22
	}
22
	}
23
	if (!is_readable($file)){
23
	if (!is_readable($file)){
24
		exit("You don't have read rights on the file ".$file);
24
		exit("You don't have read rights on the file ".$file);
25
	}
25
	}
26
}
26
}
27
/****************************************************************
27
/****************************************************************
28
*			Read CONF_FILE				*
28
*			Read CONF_FILE				*
29
*****************************************************************/
29
*****************************************************************/
30
$ouvre=fopen(CONF_FILE,"r");
30
$ouvre=fopen(CONF_FILE,"r");
31
if ($ouvre){
31
if ($ouvre){
32
	while (!feof ($ouvre)){
32
	while (!feof ($ouvre)){
33
		$tampon = fgets($ouvre, 4096);
33
		$tampon = fgets($ouvre, 4096);
34
		if (strpos($tampon,"=")!==false){
34
		if (strpos($tampon,"=")!==false){
35
			$tmp = explode("=",$tampon);
35
			$tmp = explode("=",$tampon);
36
			$conf[$tmp[0]] = $tmp[1];
36
			$conf[$tmp[0]] = $tmp[1];
37
		}
37
		}
38
	}
38
	}
39
}else{
39
}else{
40
	exit("Error opening the file ".CONF_FILE);
40
	exit("Error opening the file ".CONF_FILE);
41
}
41
}
42
fclose($ouvre);
42
fclose($ouvre);
43
$organisme = trim($conf["ORGANISM"]);
43
$organisme = trim($conf["ORGANISM"]);
44
$domainname = trim($conf["DOMAIN"]);
44
$domainname = trim($conf["DOMAIN"]);
45
$hostname = "alcasar.".$domainname;
45
$hostname = "alcasar.".$domainname;
46
$network_pb = False; # "alcasar-watchdog.sh" changes this value if a network issue is detected
46
$network_pb = False; # "alcasar-watchdog.sh" changes this value if a network issue is detected
-
 
47
$diagnostic = "can't contact the default router"; # "alcasar-watchdog.sh" changes this value if a network issue is detected
47
$cert_add = "http://$hostname/certs";
48
$cert_add = "http://$hostname/certs";
48
$direct_access = False;
49
$direct_access = False;
49
$display_menu=False;
50
$display_menu=False;
50
$diagnostic = "can't contact the default router";
-
 
51
$remote_ip = preg_match('#^([0-9]{1,3}\.){3}[0-9]{1,3}$#', $_SERVER['REMOTE_ADDR']) ? $_SERVER['REMOTE_ADDR'] : "";
51
$remote_ip = preg_match('#^([0-9]{1,3}\.){3}[0-9]{1,3}$#', $_SERVER['REMOTE_ADDR']) ? $_SERVER['REMOTE_ADDR'] : "";
52
$tab = array();$user = array();
52
$tab = array();$user = array();
53
$connection_history =  "";
53
$connection_history =  "";
54
$nb_connection_history = 3;
54
$nb_connection_history = 3;
55
$Language = 'en';
55
$Language = 'en';
56
if(isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])){
56
if(isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])){
57
	$Langue = explode(",",$_SERVER['HTTP_ACCEPT_LANGUAGE']);
57
	$Langue = explode(",",$_SERVER['HTTP_ACCEPT_LANGUAGE']);
58
	$Language = strtolower(substr(chop($Langue[0]),0,2));
58
	$Language = strtolower(substr(chop($Langue[0]),0,2));
59
}
59
}
60
$redirect_link = "www.euronews.com"; # Default redirection for HTTPS interception (beware, this website must run in HTTP)
60
$redirect_link = "www.euronews.com"; # Default redirection for HTTPS interception (beware, this website must run in HTTP)
61
 
61
 
62
# Retrieve the user info behind the remote ip
62
# Retrieve the user info behind the remote ip
63
exec ("sudo /usr/sbin/chilli_query list | grep -Ew $remote_ip" , $tab);
63
exec ("sudo /usr/sbin/chilli_query list | grep -Ew $remote_ip" , $tab);
64
$user = explode (" ", $tab[0]);
64
$user = explode (" ", $tab[0]);
65
 
65
 
66
# Test if it's a direct connexion to ALCASAR
66
# Test if it's a direct connexion to ALCASAR
67
if (isset($_SERVER['HTTP_HOST'])){
67
if (isset($_SERVER['HTTP_HOST'])){
68
	if (($_SERVER['HTTP_HOST'] == $_SERVER['SERVER_ADDR']) || (preg_match ("/^alcasar$/", $_SERVER['HTTP_HOST'])) || (preg_match ("/^$hostname$/", $_SERVER['HTTP_HOST'])) || (preg_match ("/^$organisme$/", $_SERVER['HTTP_HOST']))){
68
	if (($_SERVER['HTTP_HOST'] == $_SERVER['SERVER_ADDR']) || (preg_match ("/^alcasar$/", $_SERVER['HTTP_HOST'])) || (preg_match ("/^$hostname$/", $_SERVER['HTTP_HOST'])) || (preg_match ("/^$organisme$/", $_SERVER['HTTP_HOST']))){
69
		$direct_access=True;
69
		$direct_access=True;
70
		exec("sudo /usr/sbin/ipset del not_auth_yet $remote_ip"); # del user of the ipset "not_auth_yet" to not loop
70
		exec("sudo /usr/sbin/ipset del not_auth_yet $remote_ip"); # del user of the ipset "not_auth_yet" to not loop
71
	}
71
	}
72
}
72
}
73
# Function to adapt time connexion in seconds to H,M,S
73
# Function to adapt time connexion in seconds to H,M,S
74
function secondsToDuration($seconds = null){
74
function secondsToDuration($seconds = null){
75
	if ($seconds == null) return "";
75
	if ($seconds == null) return "";
76
	$temp = $seconds % 3600;
76
	$temp = $seconds % 3600;
77
	$time[0] = ( $seconds - $temp ) / 3600 ;	// hours
77
	$time[0] = ( $seconds - $temp ) / 3600 ;	// hours
78
	$time[2] = $temp % 60 ;				// seconds
78
	$time[2] = $temp % 60 ;				// seconds
79
	$time[1] = ( $temp - $time[2] ) / 60;		// minutes
79
	$time[1] = ( $temp - $time[2] ) / 60;		// minutes
80
	return $time[0]." h ".$time[1]." m ".$time[2]." s";
80
	return $time[0]." h ".$time[1]." m ".$time[2]." s";
81
}
81
}
82
 
82
 
83
# if user need to be warned
83
# if user need to be warned
84
if(isset($_GET['warn']) && isset($_GET['url']))
84
if(isset($_GET['warn']) && isset($_GET['url']))
85
{
85
{
86
	$direct_access = False;
86
	$direct_access = False;
87
}
87
}
88
 
88
 
89
if ((isset ($user[4])) && ($user[4] != "0")){ # the user is authenticated
89
if ((isset ($user[4])) && ($user[4] != "0")){ # the user is authenticated
90
	if(isset($_GET['redirect'])) # if user has been warned, we redirect him to his website
90
	if(isset($_GET['redirect'])) # if user has been warned, we redirect him to his website
91
	{
91
	{
92
		$redir = "http://".$_GET['url'];  
92
		$redir = "http://".$_GET['url'];  
93
		header("Location: $_GET[url]",TRUE,307);
93
		header("Location: $_GET[url]",TRUE,307);
94
		exit; 
94
		exit; 
95
	}
95
	}
96
	# we retrieve his three last connections
96
	# we retrieve his three last connections
97
	if ((is_file("./acc/manager/lib/sql/drivers/mysql/functions.php"))&&(is_file("/etc/freeradius-web/config.php"))){
97
	if ((is_file("./acc/manager/lib/sql/drivers/mysql/functions.php"))&&(is_file("/etc/freeradius-web/config.php"))){
98
		include_once("/etc/freeradius-web/config.php");
98
		include_once("/etc/freeradius-web/config.php");
99
		include_once("./acc/manager/lib/sql/drivers/mysql/functions.php");
99
		include_once("./acc/manager/lib/sql/drivers/mysql/functions.php");
100
		$sql = "SELECT UserName, AcctStartTime, AcctStopTime, acctsessiontime FROM radacct WHERE UserName='$user[5]' ORDER BY AcctStartTime DESC LIMIT 0 , $nb_connection_history";
100
		$sql = "SELECT UserName, AcctStartTime, AcctStopTime, acctsessiontime FROM radacct WHERE UserName='$user[5]' ORDER BY AcctStartTime DESC LIMIT 0 , $nb_connection_history";
101
		$link = @da_sql_pconnect($config);
101
		$link = @da_sql_pconnect($config);
102
		if ($link){
102
		if ($link){
103
			$res = @da_sql_query($link,$config,$sql);
103
			$res = @da_sql_query($link,$config,$sql);
104
			if ($res){
104
			if ($res){
105
				$connection_history.= "<ul>";
105
				$connection_history.= "<ul>";
106
				while(($row = @da_sql_fetch_array($res,$config))){
106
				while(($row = @da_sql_fetch_array($res,$config))){
107
					$connected = "";
107
					$connected = "";
108
					if ($row['acctstoptime'] == "") $connected = " (active)";
108
					if ($row['acctstoptime'] == "") $connected = " (active)";
109
					$connection_history.="<li title='$row[username] $row[acctstarttime] $row[acctstoptime] (".secondsToDuration($row['acctsessiontime']).")'>$row[acctstarttime] (".secondsToDuration($row['acctsessiontime']).") $connected</li>";
109
					$connection_history.="<li title='$row[username] $row[acctstarttime] $row[acctstoptime] (".secondsToDuration($row['acctsessiontime']).")'>$row[acctstarttime] (".secondsToDuration($row['acctsessiontime']).") $connected</li>";
110
				}
110
				}
111
				$connection_history.="</ul>";
111
				$connection_history.="</ul>";
112
			}
112
			}
113
		}
113
		}
114
	}
114
	}
115
}
115
}
116
else # the user isn't authenticated
116
else # the user isn't authenticated
117
{
117
{
118
	exec("sudo /usr/sbin/ipset list not_auth_yet | grep $remote_ip | wc -l 2>&1", $ipset_not_auth_yet);
118
	exec("sudo /usr/sbin/ipset list not_auth_yet | grep $remote_ip | wc -l 2>&1", $ipset_not_auth_yet);
119
	if(!$direct_access && $ipset_not_auth_yet[0] == '0'){ # it's the first stage of the interception
119
	if(!$direct_access && $ipset_not_auth_yet[0] == '0'){ # it's the first stage of the interception
120
		$display_menu = True; # Display menu for user not_auth_yet
120
		$display_menu = True; # Display menu for user not_auth_yet
121
		if (!isset($_SERVER['HTTPS'])){ # In HTTP, the user is redirected on it's home page. In HTTPS, it's on the default page (see $redirect_link)
121
		if (!isset($_SERVER['HTTPS'])){ # In HTTP, the user is redirected on it's home page. In HTTPS, it's on the default page (see $redirect_link)
122
			$redirect_link = $_SERVER['HTTP_HOST'];
122
			$redirect_link = $_SERVER['HTTP_HOST'];
123
		}
123
		}
124
	}
124
	}
125
	if(isset($_GET['url'])){ # it's the second stage (when user has clicked on the button "open a connection")
125
	if(isset($_GET['url'])){ # it's the second stage (when user has clicked on the button "open a connection")
126
		exec("sudo /usr/sbin/ipset add not_auth_yet $remote_ip"); # Add user in the ipset "not_auth_yet" (DNS requests not intercepted)
126
		exec("sudo /usr/sbin/ipset add not_auth_yet $remote_ip"); # Add user in the ipset "not_auth_yet" (DNS requests not intercepted)
127
		$redir = "http://".$_GET['url'];
127
		$redir = "http://".$_GET['url'];
128
		header("Location: $redir",TRUE,307);
128
		header("Location: $redir",TRUE,307);
129
		exit; 
129
		exit; 
130
	}
130
	}
131
	if ($ipset_not_auth_yet[0] == '1'){ # if user not_auth_yet still here (index.php), we force DNS resquest.
131
	if ($ipset_not_auth_yet[0] == '1'){ # if user not_auth_yet still here (index.php), we force DNS resquest.
132
		 echo "<script>window.location.reload(true)</script>"; # force DNS request
132
		 echo "<script>window.location.reload(true)</script>"; # force DNS request
133
	}
133
	}
134
}
134
}
135
# Choice of language
135
# Choice of language
136
if($Language == 'fr'){
136
if($Language == 'fr'){
137
	$l_access_denied = "Contrôle d'accès";
137
	$l_access_denied = "Contrôle d'accès";
138
	$l_access_welcome = "Bienvenue sur ALCASAR";
138
	$l_access_welcome = "Bienvenue sur ALCASAR";
139
	$l_access_unavailable = "ACCÈS INDISPONIBLE";
139
	$l_access_unavailable = "ACCÈS INDISPONIBLE";
140
	$l_required_domain = "Site WEB demandé";
140
	$l_required_domain = "Site WEB demandé";
141
	$l_explain_acc_access = "Le centre de gestion permet d'administrer le portail. Vous devez posséder un compte d'administration ou de gestion pour y accéder.";
141
	$l_explain_acc_access = "Le centre de gestion permet d'administrer le portail. Vous devez posséder un compte d'administration ou de gestion pour y accéder.";
142
	$l_explain_access_deny = "Vous tentez d'accéder à une ressource dont le contenu est réputé contenir des informations inappropriées.";
142
	$l_explain_access_deny = "Vous tentez d'accéder à une ressource dont le contenu est réputé contenir des informations inappropriées.";
143
	$l_explain_net_pb = "Votre portail détecte que l'accès à Internet est indisponible.";
143
	$l_explain_net_pb = "Votre portail détecte que l'accès à Internet est indisponible.";
144
	$l_contact_access_deny = "Contactez le responsable de la séurité (OSSI/RSSI) si vous pensez que ce filtrage est abusif.";
144
	$l_contact_access_deny = "Contactez le responsable de la séurité (OSSI/RSSI) si vous pensez que ce filtrage est abusif.";
145
	$l_contact_net_pb = "Contactez votre responsable informatique ou votre prestataire Internet pour plus d'information.";
145
	$l_contact_net_pb = "Contactez votre responsable informatique ou votre prestataire Internet pour plus d'information.";
146
	$l_welcome = "Page principale de votre portail captif";
-
 
147
	$l_sms_access = "<a href=\"https://$hostname/autoregistrationinfo.php\">Auto Enregistrement par SMS</a>";
146
	$l_sms_access = "<a href=\"https://$hostname/autoregistrationinfo.php\">Auto Enregistrement par SMS</a>";
148
	$l_install_certif = "<a href=\"$cert_add/certificat_alcasar_ca.der\">Installer le certificat racine</a>";
147
	$l_install_certif = "<a href=\"$cert_add/certificat_alcasar_ca.der\">Installer le certificat racine</a>";
149
	$l_install_certif_more = "<a href=\"$cert_add/certificat_alcasar_ca.der\">Installation du certificat de l'autorité; racine d'ALCASAR</a>";
148
	$l_install_certif_more = "<a href=\"$cert_add/certificat_alcasar_ca.der\">Installation du certificat de l'autorité; racine d'ALCASAR</a>";
150
	$l_certif_explain = "Permet l'échange de données sécurisées entre votre station de consultation et le portail captif ALCASAR.<BR>Si ce certificat n'est pas enregistré sur votre station de consultation, il est possible que des alertes de sécurité soient émises par votre navigateur.<br><br>";
149
	$l_certif_explain = "Permet l'échange de données sécurisées entre votre station de consultation et le portail captif ALCASAR.<BR>Si ce certificat n'est pas enregistré sur votre station de consultation, il est possible que des alertes de sécurité soient émises par votre navigateur.<br><br>";
151
	$l_certif_explain_help = "<a href=\"alcasar-certificat.pdf\" target=\"_blank\">Aide complémentaire</a>";
150
	$l_certif_explain_help = "<a href=\"alcasar-certificat.pdf\" target=\"_blank\">Aide complémentaire</a>";
152
	$l_category = "catégorie :";
151
	$l_category = "catégorie :";
153
	if ((isset ($user[4])) && ($user[4] == "0")){
152
	if ((isset ($user[4])) && ($user[4] == "0")){
154
		$l_logout_explain = "Aucune session de consultation Internet n'est actuellement ouverte sur votre système.";
153
		$l_logout_explain = "Aucune session de consultation Internet n'est actuellement ouverte sur votre système.";
155
		$l_logout = "<a href=\"http://$hostname/index.php?url=$redirect_link\">Ouvrir une session Internet</a>";
154
		$l_logout = "<a href=\"http://$hostname/index.php?url=$redirect_link\">Ouvrir une session Internet</a>";
156
	}
155
	}
157
	else{
156
	else{
158
		if ($user[5] != $user[0]){ # authentication exception or not
157
		if ($user[5] != $user[0]){ # authentication exception or not
159
			$l_logout_explain = "Ferme la session de l'usager actuellement connecté. <br><br>Utilisateur connecté : <a href=\"http://$hostname:3990/logoff\" title=\"Deconnecter l'utilisateur $user[5]\"><b>$user[5]</b></a><br><br>$nb_connection_history dernières connexions :$connection_history";
158
			$l_logout_explain = "Ferme la session de l'usager actuellement connecté. <br><br>Utilisateur connecté : <a href=\"http://$hostname:3990/logoff\" title=\"Deconnecter l'utilisateur $user[5]\"><b>$user[5]</b></a><br><br>$nb_connection_history dernières connexions :$connection_history";
160
			$l_logout = "<a href=\"http://$hostname:3990/logoff\">Se déconnecter d'internet</a>";
159
			$l_logout = "<a href=\"http://$hostname:3990/logoff\">Se déconnecter d'internet</a>";
161
		}
160
		}
162
		else{
161
		else{
163
			$l_logout_explain = "Votre système ($user[5]) est en exception d'authentication.<br><br>$nb_connection_history last connections :$connection_history";
162
			$l_logout_explain = "Votre système ($user[5]) est en exception d'authentication.<br><br>$nb_connection_history last connections :$connection_history";
164
			$l_logout = "Information des connexions";
163
			$l_logout = "Information des connexions";
165
		}
164
		}
166
	}
165
	}
167
	$l_password_change = "<a href=\"https://$hostname/pass\">Changer votre mot de passe</a>";
166
	$l_password_change = "<a href=\"https://$hostname/pass\">Changer votre mot de passe</a>";
168
	$l_password_change_explain = "Vous redirige sur la page de changement du mot de passe de votre compte d'accès à Internet.<br><br>Vous devez avoir un compte internet valide.";
167
	$l_password_change_explain = "Vous redirige sur la page de changement du mot de passe de votre compte d'accès à Internet.<br><br>Vous devez avoir un compte internet valide.";
169
	$l_sms_explain = "Vous redirige vers la page explicative de l'auto enregistrement par SMS.<br><br><strong>Identifiant:</strong> votre numéro de téléphone<br><strong>Mot de passe:</strong> votre message";
168
	$l_sms_explain = "Vous redirige vers la page explicative de l'auto enregistrement par SMS.<br><br><strong>Identifiant:</strong> votre numéro de téléphone<br><strong>Mot de passe:</strong> votre message";
170
	$l_back_page = "<a href=\"javascript:history.back()\">Page précédente</a>";
169
	$l_back_page = "<a href=\"javascript:history.back()\">Page précédente</a>";
171
	$l_service_sms = "Service SMS actif";
170
	$l_service_sms = "Service SMS actif";
172
	$l_service_sms_n = "Service SMS non actif";
171
	$l_service_sms_n = "Service SMS non actif";
173
	$l_acc_sms = "Auto enregistrement par SMS";
172
	$l_acc_sms = "Auto enregistrement par SMS";
174
	$l_explain_warn = "L'administrateur a créé une archive contenant vos journaux de connexion dans le cadre d'une affaire judiciaire.";
173
	$l_explain_warn = "L'administrateur a créé une archive contenant vos journaux de connexion dans le cadre d'une affaire judiciaire.";
175
	if(isset($_GET['url'])){
174
	if(isset($_GET['url'])){
176
		$l_continue_link = "<a href='index.php?redirect=1&url=$_GET[url]' class='button'>Je comprends et je souhaite continuer ma navigation.</a>";
175
		$l_continue_link = "<a href='index.php?redirect=1&url=$_GET[url]' class='button'>Je comprends et je souhaite continuer ma navigation.</a>";
177
	}
176
	}
178
	else{
177
	else{
179
		$l_continue_link = "<a href='index.php' class='button'>Je comprends et je souhaite continuer ma navigation.</a>";
178
		$l_continue_link = "<a href='index.php' class='button'>Je comprends et je souhaite continuer ma navigation.</a>";
180
	}
179
	}
181
	$l_title_warn="Cher utilisateur, ";
180
	$l_title_warn="Cher utilisateur, ";
182
	$l_explain_warn_name="Une personne sous le nom de ";
181
	$l_explain_warn_name="Une personne sous le nom de ";
183
	$l_explain_warn_ip="sous cette IP : ";
182
	$l_explain_warn_ip="sous cette IP : ";
184
	$l_explain_warn_date="a consulté vos journaux de connexion le ";
183
	$l_explain_warn_date="a consulté vos journaux de connexion le ";
185
	$l_explain_warn_reason="Raison invoquée : ";
184
	$l_explain_warn_reason="Raison invoquée : ";
186
}
185
}
187
else if($Language == 'pt'){
186
else if($Language == 'pt'){
188
	$l_access_denied = "Controle de acesso";
187
	$l_access_denied = "Controle de acesso";
189
	$l_access_welcome = "Bem-vindo ao Alcasar";
188
	$l_access_welcome = "Bem-vindo ao Alcasar";
190
	$l_access_unavailable = "ACESSO INDISPONÍVEL";
189
	$l_access_unavailable = "ACESSO INDISPONÍVEL";
191
	$l_required_domain = "Site WEB Obrigatório";
190
	$l_required_domain = "Site WEB Obrigatório";
192
	$l_explain_acc_access = "Este é o centro de controle do portal para acessar você deve ter uma conta administrativa valida.";
191
	$l_explain_acc_access = "Este é o centro de controle do portal para acessar você deve ter uma conta administrativa valida.";
193
	$l_explain_access_deny = "Você tenta se conectar a um recurso cujo conteúdo é considerado inadequado no conteúdo de informações.";
192
	$l_explain_access_deny = "Você tenta se conectar a um recurso cujo conteúdo é considerado inadequado no conteúdo de informações.";
194
	$l_explain_net_pb = "O sistema detectou que o acesso é de risco, não será permitido o acesso";
193
	$l_explain_net_pb = "O sistema detectou que o acesso é de risco, não será permitido o acesso";
195
	$l_contact_access_deny = "Entre em contato com o administrador do sistema de segurança se acha que essa filtragem é abusiva.";
194
	$l_contact_access_deny = "Entre em contato com o administrador do sistema de segurança se acha que essa filtragem é abusiva.";
196
	$l_contact_net_pb = "Entre em contato com a empresa fornecedora de Internet para mais informações";
195
	$l_contact_net_pb = "Entre em contato com a empresa fornecedora de Internet para mais informações";
197
	$l_welcome = "Página do portal";
-
 
198
	$l_sms_access = "<a href=\"https://$hostname/autoregistrationinfo.php\">Auto Registration by SMS</a>";
196
	$l_sms_access = "<a href=\"https://$hostname/autoregistrationinfo.php\">Auto Registration by SMS</a>";
199
	$l_install_certif = "<a href=\"$cert_add/certificat_alcasar_ca.der\">Instalar Certificado Alcasar AC</a>";
197
	$l_install_certif = "<a href=\"$cert_add/certificat_alcasar_ca.der\">Instalar Certificado Alcasar AC</a>";
200
	$l_install_certif_more = "<a href=\"$cert_add/certificat_alcasar_ca.der\">Instalar Certificado Alcasar AC</a>";
198
	$l_install_certif_more = "<a href=\"$cert_add/certificat_alcasar_ca.der\">Instalar Certificado Alcasar AC</a>";
201
	$l_certif_explain = "O certificado Permiti a troca de dados seguro entre seu computador e o portal Alcasar.<BR>Se este certificado não estiver incorporado no seu computador, alguns alertas de segurança deverá aparecer no navegador.<br><br>";
199
	$l_certif_explain = "O certificado Permiti a troca de dados seguro entre seu computador e o portal Alcasar.<BR>Se este certificado não estiver incorporado no seu computador, alguns alertas de segurança deverá aparecer no navegador.<br><br>";
202
	$l_certif_explain_help = "<a href=\"alcasar-certificat.pdf\" target=\"_blank\">Essa foi uma ajuda complementar</a>";
200
	$l_certif_explain_help = "<a href=\"alcasar-certificat.pdf\" target=\"_blank\">Essa foi uma ajuda complementar</a>";
203
	$l_category = "categoria :";
201
	$l_category = "categoria :";
204
	if ((isset ($user[4])) && ($user[4] == "0")){
202
	if ((isset ($user[4])) && ($user[4] == "0")){
205
		$l_logout_explain = "Não há conexão de Internet aberta em seu computador, deseja conectar?";
203
		$l_logout_explain = "Não há conexão de Internet aberta em seu computador, deseja conectar?";
206
		$l_logout = "<a href=\"http://$hostname/index.php?url=$redirect_link\">Abrir uma conexão de Internet</a>";
204
		$l_logout = "<a href=\"http://$hostname/index.php?url=$redirect_link\">Abrir uma conexão de Internet</a>";
207
	}
205
	}
208
	else{
206
	else{
209
		if ($user[5] != $user[0]){ # authentication exception or not
207
		if ($user[5] != $user[0]){ # authentication exception or not
210
			$l_logout_explain = "Se desejar, feche a conexão do usuário atual conectado.<br> Usuário conectado : <a href=\"http://$hostname:3990/logoff\" title=\"Disconnect user $user[5]\"><b>$user[5]</b></a><br><br>$nb_connection_history last connections :$connection_history";
208
			$l_logout_explain = "Se desejar, feche a conexão do usuário atual conectado.<br> Usuário conectado : <a href=\"http://$hostname:3990/logoff\" title=\"Disconnect user $user[5]\"><b>$user[5]</b></a><br><br>$nb_connection_history last connections :$connection_history";
211
			$l_logout = "<a href=\"http://$hostname:3990/logoff\">Sair da Internet</a>";
209
			$l_logout = "<a href=\"http://$hostname:3990/logoff\">Sair da Internet</a>";
212
		}
210
		}
213
		else{
211
		else{
214
			$l_logout_explain = "O sistema ($user[5]) detctou exesso de autenticação.<br><br>$nb_connection_history logins últimos :$connection_history";
212
			$l_logout_explain = "O sistema ($user[5]) detctou exesso de autenticação.<br><br>$nb_connection_history logins últimos :$connection_history";
215
			$l_logout = "Informações de conexões";
213
			$l_logout = "Informações de conexões";
216
		}
214
		}
217
	}
215
	}
218
	$l_password_change = "<a href=\"https://$hostname/pass\">Mudar sua senha</a>";
216
	$l_password_change = "<a href=\"https://$hostname/pass\">Mudar sua senha</a>";
219
	$l_password_change_explain = "Você será redirecionado à página de alteração de senha.<br><br> e deverá ter uma conta de usuário valido para efetuar a troca e acessar à Internet.";
217
	$l_password_change_explain = "Você será redirecionado à página de alteração de senha.<br><br> e deverá ter uma conta de usuário valido para efetuar a troca e acessar à Internet.";
220
	$l_sms_explain = "Redirect you on auto registration page.<br><br><strong>Login:</strong> your phone number<br><strong>Password:</strong> SMS content";
218
	$l_sms_explain = "Redirect you on auto registration page.<br><br><strong>Login:</strong> your phone number<br><strong>Password:</strong> SMS content";
221
	$l_back_page = "<a href=\"javascript:history.back()\">Página anterior</a>";
219
	$l_back_page = "<a href=\"javascript:history.back()\">Página anterior</a>";
222
	$l_service_sms = "SMS service enable";
220
	$l_service_sms = "SMS service enable";
223
	$l_service_sms_n = "SMS service disable";
221
	$l_service_sms_n = "SMS service disable";
224
	$l_acc_sms = "Auto registration by SMS";
222
	$l_acc_sms = "Auto registration by SMS";
225
	$l_explain_warn = "El administrador ha creado un archivo que contiene los periódicos de inicio de sesión como parte de un proceso judicial."; 
223
	$l_explain_warn = "El administrador ha creado un archivo que contiene los periódicos de inicio de sesión como parte de un proceso judicial."; 
226
	if(isset($_GET['url'])){
224
	if(isset($_GET['url'])){
227
		$l_continue_link = "<a href='index.php?redirect=1&url=$_GET[url]' class='button'>Lo comprendo y deseo continuar mi navegación.</a>";
225
		$l_continue_link = "<a href='index.php?redirect=1&url=$_GET[url]' class='button'>Lo comprendo y deseo continuar mi navegación.</a>";
228
	}
226
	}
229
	else{
227
	else{
230
		$l_continue_link = "<a href='index.php' class='button'>Lo comprendo y deseo continuar mi navegación.</a>";
228
		$l_continue_link = "<a href='index.php' class='button'>Lo comprendo y deseo continuar mi navegación.</a>";
231
	}
229
	}
232
	$l_title_warn="Estimado usuario,";
230
	$l_title_warn="Estimado usuario,";
233
	$l_explain_warn_name="El usario ";
231
	$l_explain_warn_name="El usario ";
234
	$l_explain_warn_ip="con este IP : ";
232
	$l_explain_warn_ip="con este IP : ";
235
	$l_explain_warn_date="consultó a sus registros de conexión el ";
233
	$l_explain_warn_date="consultó a sus registros de conexión el ";
236
	$l_explain_warn_reason="con la siguiente razón : ";
234
	$l_explain_warn_reason="con la siguiente razón : ";
237
}
235
}
238
else if($Language == 'zn'){
236
else if($Language == 'zn'){
239
	$l_access_denied = "访问控制";
237
	$l_access_denied = "访问控制";
240
	$l_access_welcome = "欢迎来到ALCASAR";
238
	$l_access_welcome = "欢迎来到ALCASAR";
241
	$l_access_unavailable = "不可访问";
239
	$l_access_unavailable = "不可访问";
242
	$l_required_domain = "访问的网站";
240
	$l_required_domain = "访问的网站";
243
	$l_explain_acc_access = "管理中心能管理门户,您必须通过超级用户或者管理用户来访问。";
241
	$l_explain_acc_access = "管理中心能管理门户,您必须通过超级用户或者管理用户来访问。";
244
	$l_explain_access_deny = "您试图访问一个含有不当信息的资源。";
242
	$l_explain_access_deny = "您试图访问一个含有不当信息的资源。";
245
	$l_explain_net_pb = "您的门户检测因特网不可用。";
243
	$l_explain_net_pb = "您的门户检测因特网不可用。";
246
	$l_contact_access_deny = "如果您认为该过滤不当,请联系安全负责人(OSSI/RSSI)。";
244
	$l_contact_access_deny = "如果您认为该过滤不当,请联系安全负责人(OSSI/RSSI)。";
247
	$l_contact_net_pb = "请联系IT负责人或网络服务商来了解更多信息。";
245
	$l_contact_net_pb = "请联系IT负责人或网络服务商来了解更多信息。";
248
	$l_welcome = "强制门户主页";
-
 
249
	$l_sms_access = "<a href=\"https://$hostname/autoregistrationinfo.php\">短信自动登录 </a>";
246
	$l_sms_access = "<a href=\"https://$hostname/autoregistrationinfo.php\">短信自动登录 </a>";
250
	$l_install_certif = "<a href=\"$cert_add/certificat_alcasar_ca.der\">安装根证书 </a>";
247
	$l_install_certif = "<a href=\"$cert_add/certificat_alcasar_ca.der\">安装根证书 </a>";
251
	$l_install_certif_more = "<a href=\"$cert_add/certificat_alcasar_ca.der\">安装根证书 </a>";
248
	$l_install_certif_more = "<a href=\"$cert_add/certificat_alcasar_ca.der\">安装根证书 </a>";
252
	$l_certif_explain = "允许您的计算机与ALCASAR门户进行安全数据交换。<BR>如果该证书未包含在您的计算机中,您的浏览器将出现一些安全提醒。<br><br>";
249
	$l_certif_explain = "允许您的计算机与ALCASAR门户进行安全数据交换。<BR>如果该证书未包含在您的计算机中,您的浏览器将出现一些安全提醒。<br><br>";
253
	$l_certif_explain_help = "<a href=\"alcasar-certificat.pdf\" target=\"_blank\">额外帮助</a>";
250
	$l_certif_explain_help = "<a href=\"alcasar-certificat.pdf\" target=\"_blank\">额外帮助</a>";
254
	$l_category = "类别 :";
251
	$l_category = "类别 :";
255
	if ((isset ($user[4])) && ($user[4] == "0")){
252
	if ((isset ($user[4])) && ($user[4] == "0")){
256
		$l_logout_explain = "您的系统目前没有打开任何网络咨询进程。";
253
		$l_logout_explain = "您的系统目前没有打开任何网络咨询进程。";
257
		$l_logout = "<a href=\"http://$hostname/index.php?url=$redirect_link\">打开一个网络进程</a>";
254
		$l_logout = "<a href=\"http://$hostname/index.php?url=$redirect_link\">打开一个网络进程</a>";
258
	}
255
	}
259
	else{
256
	else{
260
		if ($user[5] != $user[0]){ # authentication exception or not
257
		if ($user[5] != $user[0]){ # authentication exception or not
261
			$l_logout_explain = "关闭当前连接进程。<br> 已连接用户:<a href=\"http://$hostname:3990/logoff\" title=\" $user[5]\"><b>$user[5]</b></a><br><br>$nb_connection_history 最后连接 :$connection_history";
258
			$l_logout_explain = "关闭当前连接进程。<br> 已连接用户:<a href=\"http://$hostname:3990/logoff\" title=\" $user[5]\"><b>$user[5]</b></a><br><br>$nb_connection_history 最后连接 :$connection_history";
262
			$l_logout = "<a href=\"http://$hostname:3990/logoff\">断开网络</a>";
259
			$l_logout = "<a href=\"http://$hostname:3990/logoff\">断开网络</a>";
263
		}
260
		}
264
		else{
261
		else{
265
			$l_logout_explain = "您的系统($user[5])验证例外<br><br>$nb_connection_history 最后连接: $connection_history";
262
			$l_logout_explain = "您的系统($user[5])验证例外<br><br>$nb_connection_history 最后连接: $connection_history";
266
			$l_logout = "连接信息";
263
			$l_logout = "连接信息";
267
		}
264
		}
268
	}
265
	}
269
	$l_password_change = "<a href=\"https://$hostname/pass\">更改您的密码</a>";
266
	$l_password_change = "<a href=\"https://$hostname/pass\">更改您的密码</a>";
270
	$l_password_change_explain = "重新指向密码修改页面。<br><br> 您需要一个可用的网络账户。";
267
	$l_password_change_explain = "重新指向密码修改页面。<br><br> 您需要一个可用的网络账户。";
271
	$l_sms_explain = "重新指向短信登录页面。<br><br><strong>用户名:</strong>您的电话号码<br><strong>密码:</strong>您的信息";
268
	$l_sms_explain = "重新指向短信登录页面。<br><br><strong>用户名:</strong>您的电话号码<br><strong>密码:</strong>您的信息";
272
	$l_back_page = "<a href=\"javascript:history.back()\">上一页</a>";
269
	$l_back_page = "<a href=\"javascript:history.back()\">上一页</a>";
273
	$l_service_sms = "短信服务可用";
270
	$l_service_sms = "短信服务可用";
274
	$l_service_sms_n = "短信服务禁用";
271
	$l_service_sms_n = "短信服务禁用";
275
	$l_acc_sms = "短信自动注册";
272
	$l_acc_sms = "短信自动注册";
276
	$l_explain_warn = "管理员创建了一份可用于司法调查的连接日志文档。";
273
	$l_explain_warn = "管理员创建了一份可用于司法调查的连接日志文档。";
277
	if(isset($_GET['url'])){
274
	if(isset($_GET['url'])){
278
		$l_continue_link = "<a href='index.php?redirect=1&url=$_GET[url]' class='button'>我明白并希望继续浏览。</a>";
275
		$l_continue_link = "<a href='index.php?redirect=1&url=$_GET[url]' class='button'>我明白并希望继续浏览。</a>";
279
	}
276
	}
280
	else{
277
	else{
281
		$l_continue_link = "<a href='index.php' class='button'>我明白并希望继续浏览。</a>";
278
		$l_continue_link = "<a href='index.php' class='button'>我明白并希望继续浏览。</a>";
282
	}
279
	}
283
	$l_title_warn="亲爱的用户,";
280
	$l_title_warn="亲爱的用户,";
284
	$l_explain_warn_name="一人名为";
281
	$l_explain_warn_name="一人名为";
285
	$l_explain_warn_ip="在此IP:";
282
	$l_explain_warn_ip="在此IP:";
286
	$l_explain_warn_date="查看您的连接日志于";
283
	$l_explain_warn_date="查看您的连接日志于";
287
	$l_explain_warn_reason=" 如下原因:";
284
	$l_explain_warn_reason=" 如下原因:";
288
}
285
}
289
else if ($Language == 'ar'){
286
else if ($Language == 'ar'){
290
	$l_access_denied = "مراقبة الدخول";
287
	$l_access_denied = "مراقبة الدخول";
291
	$l_access_welcome = "ALCASAR مرحبا بك في";
288
	$l_access_welcome = "ALCASAR مرحبا بك في";
292
	$l_access_unavailable = "الدخول غير متوفر";
289
	$l_access_unavailable = "الدخول غير متوفر";
293
	$l_required_domain = "موقع إنترنيت مطلوب";
290
	$l_required_domain = "موقع إنترنيت مطلوب";
294
	$l_explain_acc_access = "مركز التحكم يمكنك من إدارة البوابة. يلزمك التوفر على حساب الادارة للدخول.";
291
	$l_explain_acc_access = "مركز التحكم يمكنك من إدارة البوابة. يلزمك التوفر على حساب الادارة للدخول.";
295
	$l_explain_access_deny = "محاولة لدخول موارد تحتوي على معلومات غير ملائمة المحتوى";
292
	$l_explain_access_deny = "محاولة لدخول موارد تحتوي على معلومات غير ملائمة المحتوى";
296
	$l_explain_net_pb = "بوابتك تكتشف ان الدخول على الانترنت غير متوفر";
293
	$l_explain_net_pb = "بوابتك تكتشف ان الدخول على الانترنت غير متوفر";
297
	$l_contact_access_deny = "المرجو الاتصال بضابط أمن (OSS / RSS) إذا اعتقدت ان هذه التصفية غير قانونية";
294
	$l_contact_access_deny = "المرجو الاتصال بضابط أمن (OSS / RSS) إذا اعتقدت ان هذه التصفية غير قانونية";
298
	$l_contact_net_pb = "المرجو الاتصال بمدير المعلومات أو مورد الأنترنت للمزيد من المعلومات";
295
	$l_contact_net_pb = "المرجو الاتصال بمدير المعلومات أو مورد الأنترنت للمزيد من المعلومات";
299
	$l_welcome = "الصفحة الرسمية للبوابة الأسيرة الخاصة بك";
-
 
300
	$auto_save_sms_text = "تسجيل ذاتي على";
296
	$auto_save_sms_text = "تسجيل ذاتي على";
301
	$l_sms_access = "<a href=\"https://$hostname/autoregistrationinfo.php\">SMS $auto_save_sms_text</a>";
297
	$l_sms_access = "<a href=\"https://$hostname/autoregistrationinfo.php\">SMS $auto_save_sms_text</a>";
302
	$l_install_certif = "<a href=\"$cert_add/certificat_alcasar_ca.der\">ركب جذر الشهادة</a>";
298
	$l_install_certif = "<a href=\"$cert_add/certificat_alcasar_ca.der\">ركب جذر الشهادة</a>";
303
	$install_cert_text = "تركيب شهادة السلطة؛ جذر الكزار";
299
	$install_cert_text = "تركيب شهادة السلطة؛ جذر الكزار";
304
	$l_install_certif_more = "<a href=\"$cert_add/certificat_alcasar_ca.der\">ALCASAR $install_cert_text</a>";
300
	$l_install_certif_more = "<a href=\"$cert_add/certificat_alcasar_ca.der\">ALCASAR $install_cert_text</a>";
305
	$exchange_data_text = "يمَكن من تبادل البيانات المؤمّنة بين محطة الاستفسار و بوابة الكزار الأسيرة";
301
	$exchange_data_text = "يمَكن من تبادل البيانات المؤمّنة بين محطة الاستفسار و بوابة الكزار الأسيرة";
306
	$cert_not_saved_text = "إذا لم يتم تسجيل هذه الشهادة على محطة الاستفسار الخاصة بك، فمن الممكن ان يتم إصدار تنبيهات أمنية من متصحفك";
302
	$cert_not_saved_text = "إذا لم يتم تسجيل هذه الشهادة على محطة الاستفسار الخاصة بك، فمن الممكن ان يتم إصدار تنبيهات أمنية من متصحفك";
307
	$l_certif_explain = "<br><br>.$cert_not_saved_text<br> .$exchange_data_text";
303
	$l_certif_explain = "<br><br>.$cert_not_saved_text<br> .$exchange_data_text";
308
	$l_certif_explain_help = "<a href=\"alcasar-certificat.pdf\" target=\"_blank\">مساعدة إضافية </a>";
304
	$l_certif_explain_help = "<a href=\"alcasar-certificat.pdf\" target=\"_blank\">مساعدة إضافية </a>";
309
	$l_category = "فئة :";
305
	$l_category = "فئة :";
310
	if ((isset ($user[4])) && ($user[4] == "0")){
306
	if ((isset ($user[4])) && ($user[4] == "0")){
311
		$l_logout_explain = "و لا جلسة استفسار للإنترنت مفتوحة حاليا على نظامك";
307
		$l_logout_explain = "و لا جلسة استفسار للإنترنت مفتوحة حاليا على نظامك";
312
		$close_session_text = "فتح جلسة الإنترنت";
308
		$close_session_text = "فتح جلسة الإنترنت";
313
		$l_logout = "<a href=\"http://$hostname/index.php?url=$redirect_link\">$close_session_text</a>";
309
		$l_logout = "<a href=\"http://$hostname/index.php?url=$redirect_link\">$close_session_text</a>";
314
	}
310
	}
315
	else{
311
	else{
316
		if ($user[5] != $user[0]){ # authentication exception or not
312
		if ($user[5] != $user[0]){ # authentication exception or not
317
			$close_session_text = "إقفال جلسة المستخدم المتصل حاليا";
313
			$close_session_text = "إقفال جلسة المستخدم المتصل حاليا";
318
			$user_logged_text = "المستخدم متصل";
314
			$user_logged_text = "المستخدم متصل";
319
			$disconnect_user_text = "قطع الاتصال على المستخدم";
315
			$disconnect_user_text = "قطع الاتصال على المستخدم";
320
			$l_logout_explain = "Ferme la session de l'usager actuellement connecté. <br><br>Utilisateur connecté : <a href=\"http://$hostname:3990/logoff\" title=\"Deconnecter l'utilisateur $user[5]\"><b>$user[5]</b></a><br><br>$nb_connection_history dernières connexions :$connection_history";
316
			$l_logout_explain = "Ferme la session de l'usager actuellement connecté. <br><br>Utilisateur connecté : <a href=\"http://$hostname:3990/logoff\" title=\"Deconnecter l'utilisateur $user[5]\"><b>$user[5]</b></a><br><br>$nb_connection_history dernières connexions :$connection_history";
321
			$logout_internet_text = "قطع الاتصال على الإنترنت";
317
			$logout_internet_text = "قطع الاتصال على الإنترنت";
322
			$l_logout = "<a href=\"http://$hostname:3990/logoff\">$logout_internet_text</a>";
318
			$l_logout = "<a href=\"http://$hostname:3990/logoff\">$logout_internet_text</a>";
323
		}
319
		}
324
		else{
320
		else{
325
			$your_system_text = "نظامك";
321
			$your_system_text = "نظامك";
326
			$auth_except_text = "على توثيق استثنائي";
322
			$auth_except_text = "على توثيق استثنائي";
327
			$last_conn_text = "اتصالات مشاركة";
323
			$last_conn_text = "اتصالات مشاركة";
328
			$l_logout_explain = "$connection_history :$last_conn_text $nb_connection_history<br><br>$auth_except_text ($user[5]) $your_system_text";
324
			$l_logout_explain = "$connection_history :$last_conn_text $nb_connection_history<br><br>$auth_except_text ($user[5]) $your_system_text";
329
			$l_logout = "معلومات على الاتصالات ";
325
			$l_logout = "معلومات على الاتصالات ";
330
		}
326
		}
331
	}
327
	}
332
	$change_pass_text = "غير كلمتك السرية";
328
	$change_pass_text = "غير كلمتك السرية";
333
	$l_password_change = "<a href=\"https://$hostname/pass\">$change_pass_text</a>";
329
	$l_password_change = "<a href=\"https://$hostname/pass\">$change_pass_text</a>";
334
	$redirect_pass_text = "يوجهك على صفحة تغيير الكلمة السرية لحساب الإنترنت الخاص بك";
330
	$redirect_pass_text = "يوجهك على صفحة تغيير الكلمة السرية لحساب الإنترنت الخاص بك";
335
	$valid_account_text = "يجب ان يكون حساب الإنترنت الخاص بك صالحاً";
331
	$valid_account_text = "يجب ان يكون حساب الإنترنت الخاص بك صالحاً";
336
	$l_password_change_explain = "$valid_account_text<br><br>.$redirect_text";
332
	$l_password_change_explain = "$valid_account_text<br><br>.$redirect_text";
337
	$redirect_sms_text = "يوجهك على الصفحة التفسيرية للتسجيل الذاتي بطريقة";
333
	$redirect_sms_text = "يوجهك على الصفحة التفسيرية للتسجيل الذاتي بطريقة";
338
	$login_text = "تسجيل الدخول";
334
	$login_text = "تسجيل الدخول";
339
	$your_phone_text = "رقم الهاتف الخاص بك";
335
	$your_phone_text = "رقم الهاتف الخاص بك";
340
	$pass_text = "كلمة السر";
336
	$pass_text = "كلمة السر";
341
	$your_message_text = "رسالتك";
337
	$your_message_text = "رسالتك";
342
	$l_sms_explain = "$your_message_text <strong>$pass_text</strong><br>$your_phone_text <strong>$login_text</strong><br><br>$redirect_sms_text";
338
	$l_sms_explain = "$your_message_text <strong>$pass_text</strong><br>$your_phone_text <strong>$login_text</strong><br><br>$redirect_sms_text";
343
	$previous_text = "الصفحة السابقة";
339
	$previous_text = "الصفحة السابقة";
344
	$l_back_page = "<a href=\"javascript:history.back()\">$previous_text</a>";
340
	$l_back_page = "<a href=\"javascript:history.back()\">$previous_text</a>";
345
	$l_service_sms = "نشطة SMS خدمة";
341
	$l_service_sms = "نشطة SMS خدمة";
346
	$l_service_sms_n = "غير نشطة SMS خدمة";
342
	$l_service_sms_n = "غير نشطة SMS خدمة";
347
	$l_acc_sms = "تسجيل ذاتي عن طريق SMS";
343
	$l_acc_sms = "تسجيل ذاتي عن طريق SMS";
348
	$l_explain_warn = "المسؤول أنشأ أرشيفاً تحتوي على سجلات الاتصال في إطار تحقيق قضائي";
344
	$l_explain_warn = "المسؤول أنشأ أرشيفاً تحتوي على سجلات الاتصال في إطار تحقيق قضائي";
349
	$understand_text = "أنا متفهم و أريد ان أواصل التصفح";
345
	$understand_text = "أنا متفهم و أريد ان أواصل التصفح";
350
	if(isset($_GET['url'])){
346
	if(isset($_GET['url'])){
351
		$l_continue_link = "<a href='index.php?redirect=1&url=$_GET[url]' class='button'>$understand_text</a>";
347
		$l_continue_link = "<a href='index.php?redirect=1&url=$_GET[url]' class='button'>$understand_text</a>";
352
	}
348
	}
353
	else{
349
	else{
354
		$l_continue_link = "<a href='index.php' class='button'>$understand_text</a>";
350
		$l_continue_link = "<a href='index.php' class='button'>$understand_text</a>";
355
	}
351
	}
356
	$l_title_warn = "عزيزي المستعمل, ";
352
	$l_title_warn = "عزيزي المستعمل, ";
357
	$l_explain_warn_name = "شخص مسمىٰ ";
353
	$l_explain_warn_name = "شخص مسمىٰ ";
358
	$l_explain_warn_ip = "تحت هذا IP: ";
354
	$l_explain_warn_ip = "تحت هذا IP: ";
359
	$l_explain_warn_date = "إطّلع على سجلات الاتصال الخاصة بك في";
355
	$l_explain_warn_date = "إطّلع على سجلات الاتصال الخاصة بك في";
360
	$l_explain_warn_reason = "السبب المسرّح به: ";
356
	$l_explain_warn_reason = "السبب المسرّح به: ";
361
}
357
}
362
else{
358
else{
363
	$l_access_denied = "Access control";
359
	$l_access_denied = "Access control";
364
	$l_access_welcome = "Welcome on ALCASAR";
360
	$l_access_welcome = "Welcome on ALCASAR";
365
	$l_access_unavailable = "ACCESS UNAVAILABLE";
361
	$l_access_unavailable = "ACCESS UNAVAILABLE";
366
	$l_required_domain = "Required WEB site";
362
	$l_required_domain = "Required WEB site";
367
	$l_explain_acc_access = "This center control the portal. You must have an administrative account.";
363
	$l_explain_acc_access = "This center control the portal. You must have an administrative account.";
368
	$l_explain_access_deny = "You try to connect to a resource whose content is deemed to contain inappropriate information.";
364
	$l_explain_access_deny = "You try to connect to a resource whose content is deemed to contain inappropriate information.";
369
	$l_explain_net_pb = "Your portal has just detected that the Internet access is down";
365
	$l_explain_net_pb = "Your portal has just detected that the Internet access is down";
370
	$l_contact_access_deny = "Contact your security system manager if you think this filtering is abusive.";
366
	$l_contact_access_deny = "Contact your security system manager if you think this filtering is abusive.";
371
	$l_contact_net_pb = "Contact your network responsive or your Internet provider for more information";
367
	$l_contact_net_pb = "Contact your network responsive or your Internet provider for more information";
372
	$l_welcome = "Your captive portal main page";
-
 
373
	$l_sms_access = "<a href=\"https://$hostname/autoregistrationinfo.php\">Auto Registration by SMS</a>";
368
	$l_sms_access = "<a href=\"https://$hostname/autoregistrationinfo.php\">Auto Registration by SMS</a>";
374
	$l_install_certif = "<a href=\"$cert_add/certificat_alcasar_ca.der\">Install ALCASAR AC Certificate</a>";
369
	$l_install_certif = "<a href=\"$cert_add/certificat_alcasar_ca.der\">Install ALCASAR AC Certificate</a>";
375
	$l_install_certif_more = "<a href=\"$cert_add/certificat_alcasar_ca.der\">Install ALCASAR AC Certificate</a>";
370
	$l_install_certif_more = "<a href=\"$cert_add/certificat_alcasar_ca.der\">Install ALCASAR AC Certificate</a>";
376
	$l_certif_explain = "Allow secure data exchange between your computer and ALCASAR portal.<BR>If this certificate isn't incorporated in your computer, some security alerts should appear in your browser.<br><br>";
371
	$l_certif_explain = "Allow secure data exchange between your computer and ALCASAR portal.<BR>If this certificate isn't incorporated in your computer, some security alerts should appear in your browser.<br><br>";
377
	$l_certif_explain_help = "<a href=\"alcasar-certificat.pdf\" target=\"_blank\">Complementary help</a>";
372
	$l_certif_explain_help = "<a href=\"alcasar-certificat.pdf\" target=\"_blank\">Complementary help</a>";
378
	$l_category = "category :";
373
	$l_category = "category :";
379
	if ((isset ($user[4])) && ($user[4] == "0")){
374
	if ((isset ($user[4])) && ($user[4] == "0")){
380
		$l_logout_explain = "No Internet consultation session is actualy open on your system";
375
		$l_logout_explain = "No Internet consultation session is actualy open on your system";
381
		$l_logout = "<a href=\"http://$hostname/index.php?url=$redirect_link\">Open an Internet session</a>";
376
		$l_logout = "<a href=\"http://$hostname/index.php?url=$redirect_link\">Open an Internet session</a>";
382
	}
377
	}
383
	else{
378
	else{
384
		if ($user[5] != $user[0]){ # authentication exception or not
379
		if ($user[5] != $user[0]){ # authentication exception or not
385
			$l_logout_explain = "Close the session of the user currently connected.<br> User logged-on : <a href=\"http://$hostname:3990/logoff\" title=\"Disconnect user $user[5]\"><b>$user[5]</b></a><br><br>$nb_connection_history last connections :$connection_history";
380
			$l_logout_explain = "Close the session of the user currently connected.<br> User logged-on : <a href=\"http://$hostname:3990/logoff\" title=\"Disconnect user $user[5]\"><b>$user[5]</b></a><br><br>$nb_connection_history last connections :$connection_history";
386
			$l_logout = "<a href=\"http://$hostname:3990/logoff\">Logoff from internet</a>";
381
			$l_logout = "<a href=\"http://$hostname:3990/logoff\">Logoff from internet</a>";
387
		}
382
		}
388
		else{
383
		else{
389
			$l_logout_explain = "Your system ($user[5]) is in exception of authentication.<br><br>$nb_connection_history Last logins :$connection_history";
384
			$l_logout_explain = "Your system ($user[5]) is in exception of authentication.<br><br>$nb_connection_history Last logins :$connection_history";
390
			$l_logout = "Connections information";
385
			$l_logout = "Connections information";
391
		}
386
		}
392
	}
387
	}
393
	$l_password_change = "<a href=\"https://$hostname/pass\">Change your password</a>";
388
	$l_password_change = "<a href=\"https://$hostname/pass\">Change your password</a>";
394
	$l_password_change_explain = "Redirect you on password change page.<br><br> You should already have an Internet access account.";
389
	$l_password_change_explain = "Redirect you on password change page.<br><br> You should already have an Internet access account.";
395
	$l_sms_explain = "Redirect you on auto registration page.<br><br><strong>Login:</strong> your phone number<br><strong>Password:</strong> SMS content";
390
	$l_sms_explain = "Redirect you on auto registration page.<br><br><strong>Login:</strong> your phone number<br><strong>Password:</strong> SMS content";
396
	$l_back_page = "<a href=\"javascript:history.back()\">Previous page</a>";
391
	$l_back_page = "<a href=\"javascript:history.back()\">Previous page</a>";
397
	$l_service_sms = "SMS service enable";
392
	$l_service_sms = "SMS service enable";
398
	$l_service_sms_n = "SMS service disable";
393
	$l_service_sms_n = "SMS service disable";
399
	$l_acc_sms = "Auto registration by SMS";
394
	$l_acc_sms = "Auto registration by SMS";
400
	$l_explain_warn = "The administrator created an archive which contains your imputabilities logs for a judicial investigation.";
395
	$l_explain_warn = "The administrator created an archive which contains your imputabilities logs for a judicial investigation.";
401
	if(isset($_GET['url'])){
396
	if(isset($_GET['url'])){
402
		$l_continue_link = "<a href='index.php?redirect=1&url=$_GET[url]' class='button'>I understand and I wish to continue.</a>";
397
		$l_continue_link = "<a href='index.php?redirect=1&url=$_GET[url]' class='button'>I understand and I wish to continue.</a>";
403
	}
398
	}
404
	else{
399
	else{
405
		$l_continue_link = "<a href='index.php' class='button'>I understand and I wish to continue.</a>";
400
		$l_continue_link = "<a href='index.php' class='button'>I understand and I wish to continue.</a>";
406
	}
401
	}
407
	$l_title_warn="Dear user,";
402
	$l_title_warn="Dear user,";
408
	$l_explain_warn_name="Someone called ";
403
	$l_explain_warn_name="Someone called ";
409
	$l_explain_warn_ip="with this IP : ";
404
	$l_explain_warn_ip="with this IP : ";
410
	$l_explain_warn_date="has read your connexion logs at ";
405
	$l_explain_warn_date="has read your connexion logs at ";
411
	$l_explain_warn_reason="For this reason : ";
406
	$l_explain_warn_reason="For this reason : ";
412
}
407
}
413
 
408
 
414
$l_title = ($direct_access ? $l_access_welcome : ($network_pb ? $l_access_unavailable : $l_access_denied));
409
$l_title = ($direct_access ? $l_access_welcome : ($network_pb ? $l_access_unavailable : $l_access_denied));
415
$l_explain = ($direct_access ? $l_explain_acc_access : ($network_pb ? $l_explain_net_pb : $l_explain_access_deny));
410
$l_explain = ($direct_access ? $l_explain_acc_access : ($network_pb ? $l_explain_net_pb : $l_explain_access_deny));
416
 
411
 
417
# set the icons
412
# set the icons
418
$img_rep = "/images/";
413
$img_rep = "/images/";
419
$img_organisme = "organisme.png";
414
$img_organisme = "organisme.png";
420
$img_access = "globe_acces_70.png";
415
$img_access = "globe_acces_70.png";
421
$img_connect = "globe_70.png";
416
$img_connect = "globe_70.png";
422
$img_warning = "globe_warning_70.png";
417
$img_warning = "globe_warning_70.png";
423
$img_pwd = "cle_ombre.png";
418
$img_pwd = "cle_ombre.png";
424
$img_certificate = "certificat.png";
419
$img_certificate = "certificat.png";
425
$img_acc = "logo-alcasar_70.png";
420
$img_acc = "logo-alcasar_70.png";
426
$img_sms = "sms.png";
421
$img_sms = "sms.png";
427
$img_false = "interdit.png";
422
$img_false = "interdit.png";
428
$img_adm = "adm.png";
423
$img_adm = "adm.png";
429
$img_internet = $img_connect;
424
$img_internet = $img_connect;
430
 
425
 
431
if ((isset ($user[4])) && ($user[4] == "0")){
426
if ((isset ($user[4])) && ($user[4] == "0")){
432
	if (! $network_pb){
427
	if (! $network_pb){
433
		$img_internet = $img_access;
428
		$img_internet = $img_access;
434
	}
429
	}
435
	else{
430
	else{
436
		$img_internet = $img_warning;
431
		$img_internet = $img_warning;
437
	}
432
	}
438
}
433
}
439
else{
434
else{
440
	$img_internet = $img_connect;
435
	$img_internet = $img_connect;
441
}
436
}
442
 
437
 
443
# cleaning the cache
438
# cleaning the cache
444
header("Expires: Tue, 01 Jan 2000 00:00:00 GMT");
439
header("Expires: Tue, 01 Jan 2000 00:00:00 GMT");
445
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
440
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
446
header("Cache-Control: no-store, no-cache, must-revalidate, max-age=0");
441
header("Cache-Control: no-store, no-cache, must-revalidate, max-age=0");
447
header("Cache-Control: post-check=0, pre-check=0", false);
442
header("Cache-Control: post-check=0, pre-check=0", false);
448
header("Pragma: no-cache");
443
header("Pragma: no-cache");
449
?>
444
?>
450
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
445
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
451
<html>
446
<html>
452
<head>
447
<head>
453
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
448
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
454
<title>ALCASAR - <?php echo $l_title; ?></title>
449
<title>ALCASAR - <?php echo $l_title; ?></title>
455
<meta http-equiv="Cache-control" content="no-cache">
450
<meta http-equiv="Cache-control" content="no-cache">
456
<meta http-equiv="Pragma" content="no-cache">
451
<meta http-equiv="Pragma" content="no-cache">
457
<?php
452
<?php
458
	echo "<style>";
453
	echo "<style>";
459
	include("css/style_intercept.css");
454
	include("css/style_intercept.css");
460
	echo "</style>";
455
	echo "</style>";
461
?>
456
?>
462
 
457
 
463
<script type="text/javascript">
458
<script type="text/javascript">
464
	function valoriserDiv5(param){
459
	function valoriserDiv5(param){
465
		document.getElementById("box_info").innerHTML = param.innerHTML;
460
		document.getElementById("box_info").innerHTML = param.innerHTML;
466
	}
461
	}
467
</script>
462
</script>
468
</head>
463
</head>
469
<body onload="valoriserDiv5(text_conn);">
464
<body onload="valoriserDiv5(text_conn);">
470
<?php
465
<?php
471
if ($direct_access || $display_menu){
466
if ($direct_access || $display_menu){
472
	echo "
467
	echo "
473
	<div id=\"cadre_titre\" class=\"titre_controle\">
468
	<div id=\"cadre_titre\" class=\"titre_controle\">
474
		<p id=\"acces_controle\" class=\"titre_controle\">$l_title</p>";
469
		<p id=\"acces_controle\" class=\"titre_controle\">$l_title</p>";
475
	if ($network_pb) {
470
	if ($network_pb) {
476
		echo "	<span>$l_explain_net_pb</span>";
471
		echo "	<span>$l_explain_net_pb</span>";
477
	}
472
	}
478
}
473
}
479
else{ # the user is intercepted
474
else{ # the user is intercepted
480
	exec("sudo /usr/sbin/ipset list not_filtered | grep $remote_ip | wc -l 2>&1", $ipset_not_filtered);
475
	exec("sudo /usr/sbin/ipset list not_filtered | grep $remote_ip | wc -l 2>&1", $ipset_not_filtered);
481
	# if user is in "ipset_not_filtered" then he must refresh its dns cache (we are in the interception process)
476
	# if user is in "ipset_not_filtered" then he must refresh its dns cache (we are in the interception process)
482
	if ($ipset_not_filtered[0] == '1'){
477
	if (($ipset_not_filtered[0] == '1') && (!$network_pb)){
483
		echo "<script>window.location.reload(true)</script>"; # force DNS request
478
		echo "<script>window.location.reload(true)</script>"; # force DNS request
484
	}
479
	}
485
	# if user need to be warned that someone reads his logs
480
	# if user need to be warned that someone reads his logs
486
	if (isset($_GET['warn']) && isset($_GET['url']) && $_GET['warn'] == '1'){
481
	if (isset($_GET['warn']) && isset($_GET['url']) && $_GET['warn'] == '1'){
487
		echo "
482
		echo "
488
		<div id=\"cadre_titre\" class=\"titre_refus\">
483
		<div id=\"cadre_titre\" class=\"titre_refus\">
489
		<p id=\"acces_controle\" class=\"titre_refus\">$l_title_warn</p>";
484
		<p id=\"acces_controle\" class=\"titre_refus\">$l_title_warn</p>";
490
	}
485
	}
491
	else{ # the user is blacklisted (or whitelisted)
486
	else{ # the user is blacklisted (or whitelisted)
492
		echo "
487
		echo "
493
		<div id=\"cadre_titre\" class=\"titre_refus\">
488
		<div id=\"cadre_titre\" class=\"titre_refus\">
494
		<p id=\"acces_controle\" class=\"titre_refus\">$l_title</p>";
489
		<p id=\"acces_controle\" class=\"titre_refus\">$l_title</p>";
495
	}
490
	}
496
}
491
}
497
?>
492
?>
498
 
493
 
499
		<div id="boite_logo">
494
		<div id="boite_logo">
500
			<img src="<?php echo "$img_rep$img_organisme"; ?>">
495
			<img src="<?php echo "$img_rep$img_organisme"; ?>">
501
		</div>
496
		</div>
502
	</div>
497
	</div>
503
		<div id="contenu_acces">
498
		<div id="contenu_acces">
504
			<div id="box_url">
499
			<div id="box_url">
505
<?php 
500
<?php 
506
# search here in the blacklist categories if we want to display it (if ((! $direct_access) && (! $network_pb)){}
501
# search here in the blacklist categories if we want to display it (if ((! $direct_access) && (! $network_pb)){}
507
?>
502
?>
508
			</div>
503
			</div>
509
<?php
504
<?php
510
# Check if the SMS service is enable
505
# Check if the SMS service is enable
511
$service_SMS_status="false";
506
$service_SMS_status="false";
512
if ($service_SMS_status == "true"){
507
if ($service_SMS_status == "true"){
513
	$sms_div='
508
	$sms_div='
514
		<div class="box_menu" id="box_acc" onmouseover="valoriserDiv5(text_acc);">
509
		<div class="box_menu" id="box_acc" onmouseover="valoriserDiv5(text_acc);">
515
			<span>'.$l_sms_access.'</span>
510
			<span>'.$l_sms_access.'</span>
516
			<img src="'.$img_rep.''.$img_sms.'">
511
			<img src="'.$img_rep.''.$img_sms.'">
517
		</div>
512
		</div>
518
';
513
';
519
 
514
 
520
$sms_div_over='
515
$sms_div_over='
521
		<div class="div-cache" id="text_acc">
516
		<div class="div-cache" id="text_acc">
522
			<h2>'.$l_sms_access.'</h2>
517
			<h2>'.$l_sms_access.'</h2>
523
			<p>'.$l_sms_explain.'</p>
518
			<p>'.$l_sms_explain.'</p>
524
			<p><font color="green"><center>'.$l_service_sms.'</center></font></p>
519
			<p><font color="green"><center>'.$l_service_sms.'</center></font></p>
525
			<img src="'.$img_rep.''.$img_sms.'">
520
			<img src="'.$img_rep.''.$img_sms.'">
526
		</div>
521
		</div>
527
';
522
';
528
}
523
}
529
else {
524
else {
530
	$sms_div='';
525
	$sms_div='';
531
	$sms_div_over='';
526
	$sms_div_over='';
532
}
527
}
533
if ($direct_access || $display_menu){
528
if ($direct_access || $display_menu){
534
	echo "
-
 
535
		<div id=\"box_bienvenue\">
529
	if (!$network_pb){
536
				$l_welcome
530
	       	echo "
537
		</div>
-
 
538
		<div class=\"box_menu\" id=\"box_conn\" onmouseover=\"valoriserDiv5(text_conn);\">
531
		<div class=\"box_menu\" id=\"box_conn\" onmouseover=\"valoriserDiv5(text_conn);\">
539
			<span>$l_logout</span>
532
			<span>$l_logout</span>
540
			<img src=\"$img_rep$img_internet\">
533
			<img src=\"$img_rep$img_internet\">
541
		</div>
534
		</div>";
-
 
535
	}
-
 
536
	echo "
542
		<div class=\"box_menu\" id=\"box_certif\" onmouseover=\"valoriserDiv5(text_certif);\">
537
		<div class=\"box_menu\" id=\"box_certif\" onmouseover=\"valoriserDiv5(text_certif);\">
543
			<span>$l_install_certif</span>
538
			<span>$l_install_certif</span>
544
			<img src=\"$img_rep$img_certificate\">
539
			<img src=\"$img_rep$img_certificate\">
545
		</div>
540
		</div>
546
		<div class=\"box_menu\" id=\"box_mdp\" onmouseover=\"valoriserDiv5(text_mdp);\">
541
		<div class=\"box_menu\" id=\"box_mdp\" onmouseover=\"valoriserDiv5(text_mdp);\">
547
			<img src=\"$img_rep$img_pwd\">
542
			<img src=\"$img_rep$img_pwd\">
548
			<span>$l_password_change</span>
543
			<span>$l_password_change</span>
549
		</div>		
544
		</div>		
550
		$sms_div
545
		$sms_div
551
		<div class=\"div-cache\" id=\"text_conn\">
546
		<div class=\"div-cache\" id=\"text_conn\">
552
			<h2>$l_logout</h2>
547
			<h2>$l_logout</h2>
553
			<p>$l_logout_explain</p>
548
			<p>$l_logout_explain</p>
554
			<img src=\"$img_rep$img_internet\">
549
			<img src=\"$img_rep$img_internet\">
555
		</div>
550
		</div>
556
		<div class=\"div-cache\" id=\"text_certif\">
551
		<div class=\"div-cache\" id=\"text_certif\">
557
			<h2>$l_install_certif_more</h2>
552
			<h2>$l_install_certif_more</h2>
558
			<p>$l_certif_explain $l_certif_explain_help</p>
553
			<p>$l_certif_explain $l_certif_explain_help</p>
559
			<img src=\"$img_rep$img_certificate\">				
554
			<img src=\"$img_rep$img_certificate\">				
560
		</div>
555
		</div>
561
		<div class=\"div-cache\" id=\"text_mdp\">
556
		<div class=\"div-cache\" id=\"text_mdp\">
562
			<h2>$l_password_change</h2>
557
			<h2>$l_password_change</h2>
563
			<p>$l_password_change_explain</p>
558
			<p>$l_password_change_explain</p>
564
			<img src=\"$img_rep$img_pwd\">
559
			<img src=\"$img_rep$img_pwd\">
565
		</div>
560
		</div>
566
		$sms_div_over
561
		$sms_div_over
567
		<div id=\"box_info\">
562
		<div id=\"box_info\">
568
		</div>";
563
		</div>";
569
}
564
}
570
else {
565
else {
571
	# user need to be warned that someone reads his logs
566
	# user need to be warned that someone reads his logs
572
	if(isset($_GET['warn']) && isset($_GET['url']) && $_GET['warn'] == '1'){
567
	if(isset($_GET['warn']) && isset($_GET['url']) && $_GET['warn'] == '1'){
573
		$filename="/var/www/html/acc/backup/log_info.txt";
568
		$filename="/var/www/html/acc/backup/log_info.txt";
574
		$l_explain_warn="";
569
		$l_explain_warn="";
575
		if(file_exists($filename)){
570
		if(file_exists($filename)){
576
			$fichier = fopen($filename, "r");
571
			$fichier = fopen($filename, "r");
577
			$content = file($filename);
572
			$content = file($filename);
578
			foreach($content as $line){
573
			foreach($content as $line){
579
				$infos=explode("|||", $line);
574
				$infos=explode("|||", $line);
580
				$log_date=$infos[0];	
575
				$log_date=$infos[0];	
581
				$log_user=$infos[1];	
576
				$log_user=$infos[1];	
582
				$log_reason=$infos[2];	
577
				$log_reason=$infos[2];	
583
				$log_ip=$infos[3];	
578
				$log_ip=$infos[3];	
584
			}
579
			}
585
			$l_explain_warn="$l_explain_warn_name$log_user ( $l_explain_warn_ip$log_ip ) $l_explain_warn_date$log_date $l_explain_warn_reason$log_reason";
580
			$l_explain_warn="$l_explain_warn_name$log_user ( $l_explain_warn_ip$log_ip ) $l_explain_warn_date$log_date $l_explain_warn_reason$log_reason";
586
		}
581
		}
587
		else{
582
		else{
588
			echo "Log error!";
583
			echo "Log error!";
589
		}
584
		}
590
		echo "
585
		echo "
591
			<div id=\"box_refuse\">
586
			<div id=\"box_refuse\">
592
				<img src=\"$img_rep$img_warning\">
587
				<img src=\"$img_rep$img_warning\">
593
				<p>$l_explain_warn</p>
588
				<p>$l_explain_warn</p>
594
			</div>
589
			</div>
595
			<div id=\"liens_redir\">
590
			<div id=\"liens_redir\">
596
				<p>$l_continue_link</p>
591
				<p>$l_continue_link</p>
597
			</div>";
592
			</div>";
598
	}
593
	}
599
	else{
594
	else{
600
		echo "
595
		echo "
601
			<div id=\"box_refuse\">
596
			<div id=\"box_refuse\">
602
				<img src=\"$img_rep$img_false\">
597
				<img src=\"$img_rep$img_false\">
603
				<p>$l_explain</p>
598
				<p>$l_explain</p>
604
			</div>
599
			</div>
605
			<div id=\"liens_redir\">
600
			<div id=\"liens_redir\">
606
				<p>$l_back_page</p>
601
				<p>$l_back_page</p>
607
			</div>";
602
			</div>";
608
	}
603
	}
609
}
604
}
610
	if (($network_pb)&&(! $direct_access)) {
605
	if (($network_pb)&&(! $direct_access)) {
611
		echo "	<span>Diagnostic : $diagnostic</span>";
606
		echo "	<span>Diagnostic : $diagnostic</span>";
612
	}
607
	}
613
	echo "</div>";
608
	echo "</div>";
614
	if($direct_access){ # display the admin logo (wheel) at the bottom right
609
	if($direct_access){ # display the admin logo (wheel) at the bottom right
615
		echo "<div id=\"corner\">";
610
		echo "<div id=\"corner\">";
616
		echo "<div id=\"adm\" class=\"corn\">";
611
		echo "<div id=\"adm\" class=\"corn\">";
617
		echo "<a href=\"https://$hostname/acc/\"><img src=\"$img_rep$img_adm\"></a>";
612
		echo "<a href=\"https://$hostname/acc/\"><img src=\"$img_rep$img_adm\"></a>";
618
		echo "</div>";
613
		echo "</div>";
619
		echo "</div>";
614
		echo "</div>";
620
	}
615
	}
621
?>
616
?>
622
	</body>
617
	</body>
623
</html>
618
</html>
624
 
619