Subversion Repositories ALCASAR

Rev

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

Rev 359 Rev 389
Line 69... Line 69...
69
}
69
}
70
if (isset($_POST['choix'])){ $choix=$_POST['choix']; } else { $choix=""; }
70
if (isset($_POST['choix'])){ $choix=$_POST['choix']; } else { $choix=""; }
71
switch ($choix)
71
switch ($choix)
72
{
72
{
73
case 'BL_On' :
73
case 'BL_On' :
74
	exec ("sudo /usr/local/sbin/alcasar-bl.sh -on");
74
	exec ("sudo /usr/local/sbin/alcasar-bl.sh --on");
75
	break;
75
	break;
76
case 'BL_Off' :
76
case 'BL_Off' :
77
	exec ("sudo /usr/local/sbin/alcasar-bl.sh -off");
77
	exec ("sudo /usr/local/sbin/alcasar-bl.sh --off");
78
	break;
78
	break;
79
case 'MAJ_bl' :
79
case 'MAJ_bl' :
80
	exec ("sudo /usr/local/sbin/alcasar-bl.sh -download");
80
	exec ("sudo /usr/local/sbin/alcasar-bl.sh --download");
81
	exec ("sudo /usr/local/sbin/alcasar-bl.sh -reload");
81
	exec ("sudo /usr/local/sbin/alcasar-bl.sh --reload");
82
	break;
82
	break;
83
case 'MAJ_cat' :
83
case 'MAJ_cat' :
84
	$tab=file($bl_categories_enabled);	
84
	$tab=file($bl_categories_enabled);	
85
	if ($tab)
85
	if ($tab)
86
		{
86
		{
Line 94... Line 94...
94
				}
94
				}
95
			}
95
			}
96
		fclose($pointeur);
96
		fclose($pointeur);
97
		}
97
		}
98
	else {echo "$l_error_open_file $bl_categories_enabled";}
98
	else {echo "$l_error_open_file $bl_categories_enabled";}
99
	exec ("sudo /usr/local/sbin/alcasar-bl.sh -reload");
99
	exec ("sudo /usr/local/sbin/alcasar-bl.sh --reload");
100
	break;
100
	break;
101
case 'MAJ_OSSI' :
101
case 'MAJ_OSSI' :
102
	$fichier=fopen("/etc/dansguardian/lists/blacklists/ossi/domains","w+");
102
	$fichier=fopen("/etc/dansguardian/lists/blacklists/ossi/domains","w+");
103
	fputs($fichier, $_POST['OSSI_bl_domains']);
103
	fputs($fichier, $_POST['OSSI_bl_domains']);
104
	fclose($fichier);
104
	fclose($fichier);
Line 113... Line 113...
113
	unset($_POST['OSSI_bl_urls']);
113
	unset($_POST['OSSI_bl_urls']);
114
	$fichier=fopen("/etc/dansguardian/lists/exceptionurllist","w+");
114
	$fichier=fopen("/etc/dansguardian/lists/exceptionurllist","w+");
115
	fputs($fichier, $_POST['OSSI_wl_urls']);
115
	fputs($fichier, $_POST['OSSI_wl_urls']);
116
	fclose($fichier);
116
	fclose($fichier);
117
	unset($_POST['OSSI_wl_urls']);
117
	unset($_POST['OSSI_wl_urls']);
118
	exec ("sudo /usr/local/sbin/alcasar-bl.sh -reload");
118
	exec ("sudo /usr/local/sbin/alcasar-bl.sh --reload");
119
	break;
119
	break;
120
}
120
}
121
?>
121
?>
122
</TABLE>
122
</TABLE>
123
<TABLE width="100%" border=0 cellspacing=0 cellpadding=0>
123
<TABLE width="100%" border=0 cellspacing=0 cellpadding=0>