diff --git a/DBDiff/proxy.sql b/DBDiff/proxy.sql
index 7c9b832..700c248 100644
--- a/DBDiff/proxy.sql
+++ b/DBDiff/proxy.sql
@@ -19,7 +19,7 @@ INSERT INTO `rewrite` (`id`, `from_url`, `to_url`, `attivo`) VALUES
(4, 'pannello_vbc/chkpasswd_proxy.php', 'proxy/ext/chkpasswd_proxy.php', 1);
ALTER TABLE `proxy_utenti` ADD `primo` DATETIME NULL AFTER `modifica`;
-ALTER TABLE `proxy_utenti` ADD `ultimo` DATETIME NULL AFTER `ultimo`;
+ALTER TABLE `proxy_utenti` ADD `ultimo` DATETIME NULL AFTER `primo`;
ALTER TABLE `proxy_utenti` ADD `tempo` DECIMAL(20,2) NOT NULL DEFAULT '0' AFTER `attivo`;
ALTER TABLE `proxy_utenti` CHANGE `ip` `ip` VARCHAR(15) CHARACTER SET utf8 COLLATE utf8_general_ci NULL;
REVOKE ALL PRIVILEGES ON `pannello_vbc`.`proxy_utenti` FROM 'pannello_proxy'@'%'; GRANT SELECT, UPDATE (`primo`, `ultimo`, `attivo`) ON `pannello_vbc`.`proxy_utenti` TO 'pannello_proxy'@'%';
diff --git a/condes/condes_utenti.php b/condes/condes_utenti.php
index 93a6f0a..881bb92 100755
--- a/condes/condes_utenti.php
+++ b/condes/condes_utenti.php
@@ -44,9 +44,9 @@ $query = " SELECT
";
$res = mysql_query( $query, $DB_ID );
-while ($dato = mysql_fetch_array ( $res )) {
-$tabella = new html (0,"90%",array(3,2,15,2,15,2,15,2,15,2,15,2,0));
+$tabella = new html (0,"90%",array(3,2,15,2,15,2,15,2,15,0));
+while ($dato = mysql_fetch_array ( $res )) {
?>
|
@@ -58,30 +58,19 @@ $tabella = new html (0,"90%",array(3,2,15,2,15,2,15,2,15,2,15,2,0));
|
 |
Utente |
-  |
- Creazione |
-  |
- Ultima Modifica |
-  |
- Ultimo accesso |
-  |
- Numero accessi |
-
-
|  |
-
+ Creazione |
+  |
+ Ultima Modifica |
+  |
+ Ultimo accesso |
+  |
|
-  |
|
-  |
|
-  |
|
-  |
- |
-  |
riga ();
diff --git a/firewall/firewall_gest.php b/firewall/firewall_gest.php
new file mode 100755
index 0000000..c08eb4e
--- /dev/null
+++ b/firewall/firewall_gest.php
@@ -0,0 +1,145 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/firewall/firewall_macchine.php b/firewall/firewall_macchine.php
new file mode 100755
index 0000000..f0fb0f7
--- /dev/null
+++ b/firewall/firewall_macchine.php
@@ -0,0 +1,101 @@
+
+
+
+
+
+
+
+
+
+
+ |
+  |
+  |
+ IP |
+  |
+ Nome |
+  |
+ Ultima Modifica |
+  |
+
+
+
+ |
+  |
+ |
+  |
+ |
+
+riga ();
+}
+$tabella->close();
+view_footer();
+?>
diff --git a/firewall/firewall_macchine_ext.php b/firewall/firewall_macchine_ext.php
new file mode 100755
index 0000000..f528688
--- /dev/null
+++ b/firewall/firewall_macchine_ext.php
@@ -0,0 +1,83 @@
+
+
+riga();
+$query = " SELECT
+ id,
+ data,
+ attivo,
+ ip,
+ nome
+ FROM
+ firewall_macchine_ext
+ ORDER BY
+ INET_ATON(ip) ASC
+ ";
+
+$res = mysql_query( $query, $DB_ID );
+while ($dato = mysql_fetch_array ( $res )) {
+?>
+
+
+
+
+
+
+
+ |
+  |
+  |
+ IP |
+  |
+ Nome |
+  |
+ Ultima Modifica |
+  |
+
+
+
+ |
+  |
+ |
+  |
+ |
+
+riga ();
+}
+$tabella->close();
+view_footer();
+?>
diff --git a/firewall/firewall_regole_versoesterno.php b/firewall/firewall_regole_versoesterno.php
new file mode 100755
index 0000000..7dc5df6
--- /dev/null
+++ b/firewall/firewall_regole_versoesterno.php
@@ -0,0 +1,148 @@
+
+
+
+
+
+
+
+
+
+
+ |
+  |
+  |
+ Utenza |
+  |
+ Regola |
+  |
+ Perm |
+  |
+
+
+
+ |
+ |
+ |
+
+riga();
+}
+$tabella->close();
+view_footer();
+?>
diff --git a/firewall/firewall_regolesterno.php b/firewall/firewall_regolesterno.php
new file mode 100755
index 0000000..82c13f1
--- /dev/null
+++ b/firewall/firewall_regolesterno.php
@@ -0,0 +1,163 @@
+
+
+riga();
+$query = " SELECT
+ firewall_versoesterno.id,
+ firewall_versoesterno.nome,
+ proxy_pool.ip AS int_ip,
+ proxy_pool.nome AS int_nome,
+ firewall_versoesterno.int_port,
+ firewall_macchine_ext.ip AS ext_ip,
+ firewall_macchine_ext.nome AS ext_nome,
+ firewall_versoesterno.ext_port,
+ DATE_FORMAT(firewall_versoesterno.data, '%d.%m.%Y %H:%i:%s') AS data,
+ firewall_versoesterno.attivo
+ FROM
+ firewall_versoesterno
+ JOIN
+ firewall_macchine
+ ON
+ firewall_versoesterno.id_firewall_macchine = firewall_macchine.id
+ JOIN
+ proxy_pool
+ ON
+ firewall_macchine.id_proxy_pool = proxy_pool.id
+ JOIN
+ firewall_macchine_ext
+ ON
+ firewall_versoesterno.id_firewall_macchine_ext = firewall_macchine_ext.id
+ ORDER BY
+ firewall_versoesterno.nome
+ ";
+
+$res = mysql_query( $query, $DB_ID );
+while ($dato = mysql_fetch_array ( $res )) {
+?>
+
+
+
+
+
+
+
+ |
+  |
+  |
+ |
+  |
+ |
+ |
+  |
+ |
+ |
+  |
+ |
+  |
+
+
+
+ |
+ |
+
+riga();
+}
+$tabella->close();
+view_footer();
+?>
diff --git a/firewall/index.php b/firewall/index.php
index f8ccc8a..73a19e2 100755
--- a/firewall/index.php
+++ b/firewall/index.php
@@ -1,17 +1,123 @@
$valore) {
+ if (preg_match ("/^new-(\d+)/", $id, $ris)) $new[$ris[1]] = $valore;
+ if (preg_match ("/^old-(\d+)/", $id, $ris)) $old[$ris[1]] = $valore;
+ }
+ foreach ($new as $id => $valore) {
+ if ($new[$id] == $old[$id]) continue;
+
+ if ($valore >1)
+ $stato = 1;
+ else
+ $stato = $valore;
+
+ $query = " SELECT
+ firewall_versoesterno_regole.id_firewall_versoesterno
+ FROM
+ firewall_versoesterno_regole
+ WHERE
+ firewall_versoesterno_regole.id = $id
+ ";
+
+ $res = mysql_query( $query, $DB_ID );
+ $dato = mysql_fetch_array ( $res );
+
+ $query = " UPDATE
+ firewall_versoesterno_regole
+ SET
+ stato = $valore,
+ modifica = NOW()
+ WHERE
+ id_firewall_versoesterno = ".$dato['id_firewall_versoesterno'];
+ $res = mysql_query( $query, $DB_ID );
+
+ $query = " INSERT INTO
+ firewall_logs
+ SET
+ id_utenti = ".$UTENTE['id'].",
+ tabella = 'versoesterno',
+ id_regole = $id,
+ stato = $valore,
+ data = NOW()
+ ";
+ $res = mysql_query( $query, $DB_ID );
+ }
+}
+
+$tabella = new html (0,"90%",array(15,2,20,2,5,0));
?>
+
+close ();
+view_footer();
+?>