| 10,10 → 10,8 |
| /******************** |
| * TEST CONF FILES * |
| *********************/ |
| $domain_allowed_list="/usr/local/etc/alcasar-uamdomain"; |
| $url_allowed_list="/usr/local/etc/alcasar-uamallowed"; |
| define ("DOMAIN_ALLOWED_LIST", $domain_allowed_list); |
| define ("IP_ALLOWED_LIST", $url_allowed_list); |
| define ("DOMAIN_ALLOWED_LIST", "/usr/local/etc/alcasar-uamdomain"); |
| define ("IP_ALLOWED_LIST", "/usr/local/etc/alcasar-uamallowed"); |
| $conf_files=array(DOMAIN_ALLOWED_LIST,IP_ALLOWED_LIST); |
| foreach ($conf_files as $file){ |
| if (!file_exists($file)){ |
| 21,6 → 19,8 |
| if (!is_readable($file)){ |
| exit("Can't read the file ".$file);} |
| } |
| $domain_allowed_list="/usr/local/etc/alcasar-uamdomain"; |
| $url_allowed_list="/usr/local/etc/alcasar-uamallowed"; |
| # Choice of language |
| $Language = 'en'; |
| if(isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])){ |
| 37,7 → 37,7 |
| $l_trusted_ip = "adresses IP de confiance"; |
| $l_trusted_equipments = "Equipements de consultation de confiance"; |
| $l_comment = "Commentaires"; |
| $l_trusted_domain_explain = "Gérez ici les noms de domaine Internet pouvant être joints sans authentification"; |
| $l_trusted_domain_explain = "Gérez ici les noms de domaine Internet pouvant être joints sans authentification"; |
| $l_trusted_equipments_explain = "Pour qu'un équipement du réseau de consultation puisse accéder à Internet sans être interceptés : créer un utilisateur dont le nom de login est l'@MAC de l'équipement et le mot de passe est 'password'" ; |
| $l_trusted_ip_explain = "Gérez ici les adresses IP de systèmes ou de réseaux pouvant être joints sans authentification"; |
| $l_submit = "Enregistrer"; |
| 193,11 → 193,11 |
| <table width="100%" border=1 cellspacing=0 cellpadding=1> |
| <tr><td colspan=2 align="center"> |
| <? |
| echo "$l_trusted_domain_explain</td></tr>\n"; |
| echo "<tr><td align='center' valign='middle'>\n"; |
| echo "<FORM action='$_SERVER[PHP_SELF]' method='POST'>\n"; |
| echo "$l_trusted_domain_explain</td></tr>"; |
| echo "<tr><td align='center' valign='middle'>"; |
| echo "<table cellspacing=2 cellpadding=2 border=1>"; |
| echo "<tr align='center' bgcolor='#d0ddb0'><td>$l_domain<td>$l_comment_explain<td>$l_remove</tr>\n"; |
| echo "<FORM action='$_SERVER[PHP_SELF]' method='POST'>"; |
| echo "<tr align='center' bgcolor='#d0ddb0'><td>$l_domain<td>$l_comment_explain<td>$l_remove</tr>"; |
| // Read the "Domain alowed" file |
| $tab=file(DOMAIN_ALLOWED_LIST); |
| if ($tab) # the file isn't empty |
| 216,7 → 216,7 |
| else echo " "; |
| echo "<td>"; |
| echo "<input type='checkbox' name='del-$domain[1]'>"; |
| echo "</tr>\n"; |
| echo "</tr>"; |
| } |
| } |
| } |
| 237,7 → 237,7 |
| <td>exemple1 : mydomain<br><?echo "$l_comment_explain2";?><td></tr> |
| <tr><td><input type='text' name='add_uamdomain' size='20'> |
| <td><input type='text' name='add_domain_comment' size='15'> |
| <input type='hidden' name='choix' value='new_uamdomain'></td> |
| <input type='hidden' name='choix' value='new_uamdomain'> |
| <td><input type='submit' onClick="this.disabled=true; this.value='<?echo $l_load;?>';submit();" value='<?echo "$l_add_to_list";?>'> |
| </tr></table> |
| </form> |
| 250,11 → 250,11 |
| <table width="100%" border=1 cellspacing=0 cellpadding=1> |
| <tr><td colspan=2 align="center"> |
| <? |
| echo "$l_trusted_ip_explain</td></tr>\n"; |
| echo "<tr><td align='center' valign='middle'>\n"; |
| echo "<FORM action='$_SERVER[PHP_SELF]' method='POST'>\n"; |
| echo "$l_trusted_ip_explain</td></tr>"; |
| echo "<tr><td align='center' valign='middle'>"; |
| echo "<table cellspacing=2 cellpadding=2 border=1>"; |
| echo "<tr align='center' bgcolor='#d0ddb0'><td>$l_trusted_ip<td>$l_comment<td>$l_remove</tr>\n"; |
| echo "<FORM action='$_SERVER[PHP_SELF]' method='POST'>"; |
| echo "<tr align='center' bgcolor='#d0ddb0'><td>$l_trusted_ip<td>$l_comment<td>$l_remove</tr>"; |
| // Read the "ip alowed" file |
| $tab=file(IP_ALLOWED_LIST); |
| if ($tab) # the file isn't empty |
| 272,7 → 272,7 |
| echo trim($ip_allowed[1]); |
| else echo " "; |
| echo "<td><input type='checkbox' name='del-$ip[1]'>"; |
| echo "</tr>\n"; |
| echo "</tr>"; |
| } |
| } |
| } |
| 292,12 → 292,13 |
| <tr><td>exemple1 : 170.25.23.10 <br>exemple2 : 15.20.20.0/16</td> |
| <td>my_web_server <br>my_dmz<td></tr> |
| <tr><td><input type='text' name='add_ip' size='20'></td> |
| <td><input type='text' name='add_ip_comment' size='15'> |
| <input type='hidden' name='choix' value='new_ip'></td> |
| <td><input type='text' name='add_ip_comment' size='15'></td> |
| <input type='hidden' name='choix' value='new_ip'> |
| <td><input type='submit' onClick="this.disabled=true; this.value='<?echo $l_load;?>';submit();" value='<?echo "$l_add_to_list";?>'></td> |
| </tr></table> |
| </td></tr> |
| </table> |
| </form> |
| </table> |
| <table width="100%" border="0" cellspacing="0" cellpadding="0"> |
| <tr><th><?php echo "$l_trusted_equipments";?></th></tr> |
| <tr bgcolor="#FFCC66"><td><img src="/images/pix.gif" width="1" height="2"></td></tr> |