diff --git a/pandora_console/general/firts_task/collections.php b/pandora_console/general/firts_task/collections.php new file mode 100755 index 0000000000..796a2b092b --- /dev/null +++ b/pandora_console/general/firts_task/collections.php @@ -0,0 +1,44 @@ + + +
+
+

This is a Table

+
+
+
+

Heading 1

+
+
+

Heading 2

+
+
+

Heading 3

+
+
+
+ +
+

Row 1 Column 2

+
+
+

Row 1 Column 3

+
+
+
+
+

Row 2 Column 1

+
+
+

Row 2 Column 2

+
+
+

Row 2 Column 3

+
+
+
diff --git a/pandora_console/general/firts_task/fields_manager.php b/pandora_console/general/firts_task/fields_manager.php new file mode 100755 index 0000000000..0183930a98 --- /dev/null +++ b/pandora_console/general/firts_task/fields_manager.php @@ -0,0 +1,44 @@ + + +
+
+

This is a Table

+
+
+
+

Heading 1

+
+
+

Heading 2

+
+
+

Heading 3

+
+
+
+ +
+

Row 1 Column 2

+
+
+

Row 1 Column 3

+
+
+
+
+

Row 2 Column 1

+
+
+

Row 2 Column 2

+
+
+

Row 2 Column 3

+
+
+
diff --git a/pandora_console/general/firts_task/map_builder.php b/pandora_console/general/firts_task/map_builder.php new file mode 100755 index 0000000000..70fcbb153e --- /dev/null +++ b/pandora_console/general/firts_task/map_builder.php @@ -0,0 +1,44 @@ + + +
+
+

This is a Table

+
+
+
+

Heading 1

+
+
+

Heading 2

+
+
+

Heading 3

+
+
+
+ +
+

Row 1 Column 2

+
+
+

Row 1 Column 3

+
+
+
+
+

Row 2 Column 1

+
+
+

Row 2 Column 2

+
+
+

Row 2 Column 3

+
+
+
diff --git a/pandora_console/general/firts_task/network_map.php b/pandora_console/general/firts_task/network_map.php new file mode 100755 index 0000000000..0d8b9f79fc --- /dev/null +++ b/pandora_console/general/firts_task/network_map.php @@ -0,0 +1,44 @@ + + +
+
+

This is a Table

+
+
+
+

Heading 1

+
+
+

Heading 2

+
+
+

Heading 3

+
+
+
+ +
+

Row 1 Column 2

+
+
+

Row 1 Column 3

+
+
+
+
+

Row 2 Column 1

+
+
+

Row 2 Column 2

+
+
+

Row 2 Column 3

+
+
+
diff --git a/pandora_console/general/firts_task/recon_view.php b/pandora_console/general/firts_task/recon_view.php new file mode 100755 index 0000000000..639262a5d7 --- /dev/null +++ b/pandora_console/general/firts_task/recon_view.php @@ -0,0 +1,27 @@ + + +
+
+
+
+
+
+ __('Recon server')));?> +
+
+

+

ICMP (pings), + SNMP (detecting the topology of networks and their interfaces), and other customized + type. You can define your own customized recon script.'); ?>

+
+ +
+
+
+
diff --git a/pandora_console/general/firts_task/service_list.php b/pandora_console/general/firts_task/service_list.php new file mode 100755 index 0000000000..0de64ad7e1 --- /dev/null +++ b/pandora_console/general/firts_task/service_list.php @@ -0,0 +1,44 @@ + + +
+
+

This is a Table

+
+
+
+

Heading 1

+
+
+

Heading 2

+
+
+

Heading 3

+
+
+
+ +
+

Row 1 Column 2

+
+
+

Row 1 Column 3

+
+
+
+
+

Row 2 Column 1

+
+
+

Row 2 Column 2

+
+
+

Row 2 Column 3

+
+
+
diff --git a/pandora_console/general/firts_task/snmp_filters.php b/pandora_console/general/firts_task/snmp_filters.php new file mode 100755 index 0000000000..f3c24b3f5c --- /dev/null +++ b/pandora_console/general/firts_task/snmp_filters.php @@ -0,0 +1,44 @@ + + +
+
+

This is a Table

+
+
+
+

Heading 1

+
+
+

Heading 2

+
+
+

Heading 3

+
+
+
+ +
+

Row 1 Column 2

+
+
+

Row 1 Column 3

+
+
+
+
+

Row 2 Column 1

+
+
+

Row 2 Column 2

+
+
+

Row 2 Column 3

+
+
+
diff --git a/pandora_console/general/firts_task/tags.php b/pandora_console/general/firts_task/tags.php new file mode 100755 index 0000000000..53108b4467 --- /dev/null +++ b/pandora_console/general/firts_task/tags.php @@ -0,0 +1,44 @@ + + +
+
+

This is a Table

+
+
+
+

Heading 1

+
+
+

Heading 2

+
+
+

Heading 3

+
+
+
+ +
+

Row 1 Column 2

+
+
+

Row 1 Column 3

+
+
+
+
+

Row 2 Column 1

+
+
+

Row 2 Column 2

+
+
+

Row 2 Column 3

+
+
+
diff --git a/pandora_console/general/main_menu.php b/pandora_console/general/main_menu.php index 63f98df5db..dbed853ccc 100644 --- a/pandora_console/general/main_menu.php +++ b/pandora_console/general/main_menu.php @@ -34,7 +34,7 @@ if ($autohidden_menu) { // Menu container prepared to autohide menu echo '
'; -echo '
:: '.__('Operation').' ::
'; +//echo '
:: '.__('Operation').' ::
'; require ("operation/menu.php"); //Check all enterprise ACL used in godmenu items to print menu headers @@ -47,12 +47,12 @@ if (check_acl ($config['id_user'], 0, "AW") || check_acl ($config['id_user'], 0, "EW") || check_acl ($config['id_user'], 0, "DW")) { - echo '
:: '.__('Administration').' ::
'; + //echo '
:: '.__('Administration').' ::
'; } require ("godmode/menu.php"); -require ("links_menu.php"); +//require ("links_menu.php"); echo '
'; //menu_container @@ -67,9 +67,10 @@ if (isset($config['fixed_header'])) { $config_fixed_header = $config['fixed_header']; } ?> + + + diff --git a/pandora_console/godmode/servers/servers.build_table.php b/pandora_console/godmode/servers/servers.build_table.php index c2f3274361..34aa45c9bd 100644 --- a/pandora_console/godmode/servers/servers.build_table.php +++ b/pandora_console/godmode/servers/servers.build_table.php @@ -37,7 +37,7 @@ if ($servers === false) { return; } -$table->width = '98%'; +$table->width = '100%'; $table->size = array (); $table->style = array (); @@ -50,7 +50,7 @@ $table->align[4] = 'center'; $table->align[5] = 'center'; $table->align[8] = 'center'; -$table->title = __('Tactical server information'); +//$table->title = __('Tactical server information'); $table->titleclass = 'tabletitle'; $table->titlestyle = 'text-transform:uppercase;'; @@ -162,5 +162,5 @@ if ($tiny) { unset($table->head[8]); } -html_print_table ($table); +ui_toggle(html_print_table ($table,true), __('Tactical server information')); ?> diff --git a/pandora_console/images/icono_exclamacion.png b/pandora_console/images/icono_exclamacion.png new file mode 100755 index 0000000000..896f2396e8 Binary files /dev/null and b/pandora_console/images/icono_exclamacion.png differ diff --git a/pandora_console/images/icono_grande_reconserver.png b/pandora_console/images/icono_grande_reconserver.png new file mode 100755 index 0000000000..aa2caff45a Binary files /dev/null and b/pandora_console/images/icono_grande_reconserver.png differ diff --git a/pandora_console/include/styles/firts_task.css b/pandora_console/include/styles/firts_task.css new file mode 100755 index 0000000000..72d4752b4b --- /dev/null +++ b/pandora_console/include/styles/firts_task.css @@ -0,0 +1,52 @@ +.new_task +{ + margin-top: 30px; + left: 20px; + padding-top: 0.5px; + width: 60%; + height: 35em; + background-color: #FFF; + border-radius: 3px 3px 3px 3px; +} + +.title_task +{ + background: url(../../images/icono_exclamacion.png) no-repeat scroll 280px 50% #82B92E; + padding: 10px 5px 6px 300px; + margin: 5px 5px 10px 5px; + font-weight: bold; + color: #FFF; + border-radius: 3px 3px 3px 3px; +} + +.image_task +{ + margin: 30px 0px 0px 50px; + background-color: #FFF; +} + +.text_task +{ + width: 45em; + float: right; + padding-right: 100px; + margin-top: -120px; +} + +.button_task +{ + margin-top:10px; + background-color: #82B92E; + padding: 10px 10px 10px 10px; + font-weight: bold; + color: #FFF; + border:none; +} +#description_task +{ + font-size: 12px; +} + +#fuerte{ + font-size: 12px; +} diff --git a/pandora_console/include/styles/menu.css b/pandora_console/include/styles/menu.css index d739baa922..9d0703c42b 100644 --- a/pandora_console/include/styles/menu.css +++ b/pandora_console/include/styles/menu.css @@ -17,8 +17,8 @@ */ .menu { - border-width: 1px 0 0 0px; - border-style: solid; + border-width: 0px 0px 0px 0px; + border-style: none; border-color: #777; } .menu ul { @@ -27,8 +27,8 @@ margin: 0; } .menu li.selected, .menu li.not_selected { - border: 0px solid black; - border-bottom: 1px solid #d4d4d4; + border: 0px none black; + border-bottom: 0px none #d4d4d4; margin: 0; } .menu li.selected { @@ -39,35 +39,22 @@ /*background-color: inherit;*/ color: #FFFFFF; /*font-weight: bold;*/ - display:block; /* This makes it so that the whole li is clickable */ + /* This makes it so that the whole li is clickable */ text-decoration:none; - padding: 9px; - margin-left: 28px; } +.menu .godmode li { + background-color: #B2B2B2 !important; +} + +li:hover ul { display: block; } + .submenu_text{ background-repeat: no-repeat !important; - padding: 8px 0px 8px 17px; - margin-left: 10px; + padding: 10px; + margin-left: 0px; color: #fff; -} - -.submenu_text_middle{ - background-image: url(../../images/submenu_tree_middle.png) !important; -} - -.submenu_text_last{ - background-image: url(../../images/submenu_tree_last.png) !important; -} - -.submenu2_text_middle{ - background-image: url(../../images/submenu2_tree_middle.png) !important; - padding-left: 25px; -} - -.submenu2_text_last{ - background-image: url(../../images/submenu2_tree_last.png) !important; - padding-left: 25px; + width: 88%; } .menu li.subselected a{ @@ -76,21 +63,35 @@ .menu a:hover { text-decoration:none; - border:1px; + border:0px; } .submenu { font-family: Georgia,"Times New Roman","Bitstream Charter",Times,serif; - margin: 0px 10px 0px 0; + margin: 0px 0px 0px 0px; + position: absolute; + z-index: 999; + left: 60px; + min-height: 30px; + height: 30px; + width: 160px; } + +.submenu2{ + position: absolute; + z-index: 999; + left: 160px; +} + +.sub_subMenu{ + min-height: 30px !important; + height: 30px; + width: 160px; +} + .submenu li a { background-color: #222; - margin-left: 0px; - /*padding-left: 29px;*/ - display:block; - border-width: 0px 0px 0px 0px; - border-style: solid; + border-style: none; border-color: #666; - padding: 0px; } .submenu2 li a { @@ -107,11 +108,11 @@ .menu li img.toggle { visibility: hidden; float:right; - margin: -20px 0px 0 0; /* Positions it back where it should be */ + /* Positions it back where it should be */ border-left: 1px; } .menu li.has_submenu > img.toggle{ - visibility: visible; + #visibility: visible; z-index: 1; /* Positions it on top of the rest */ } @@ -135,6 +136,7 @@ background-color: #daedae; background-position: 4px 4px; background-repeat: no-repeat; + cursor: pointer; } .menu li.links { @@ -144,86 +146,89 @@ /* Icons specified here */ #icon_oper-networkconsole { - background-image: url(../../images/op_network.png); + background: url(../../images/op_network.png) no-repeat 50% 50%; } #icon_oper-agents { - background-image: url(../../images/op_monitoring.png); + border-top-right-radius: 5px; + border-right-style: solid; + border-right-width: 0px; + background: url(../../images/op_monitoring.png) no-repeat 50% 50%; } #icon_oper-events { - background-image: url(../../images/op_events.png); + background: url(../../images/op_events.png) no-repeat 50% 50%; } /* users */ #icon_oper-users { - background-image: url(../../images/op_workspace.png); + background: url(../../images/op_workspace.png) no-repeat 50% 50%; } /* trap console */ #icon_oper-snmpc, #icon_god-snmpc { - background-image: url(../../images/op_snmp.png); + background: url(../../images/op_snmp.png) no-repeat 50% 50%; } #icon_oper-reporting { - background-image: url(../../images/op_reporting.png); + background: url(../../images/op_reporting.png) no-repeat 50% 50%; } #icon_oper-gismaps { - background-image: url(../../images/op_gis.png); + background: url(../../images/op_gis.png) no-repeat 50% 50%; } #icon_oper-netflow { - background-image: url(../../images/op_netflow.png); + background: url(../../images/op_netflow.png) no-repeat 50% 50%; } #icon_oper-extensions, #icon_god-extensions { - background-image: url(../../images/extensions.png); + background: url(../../images/extensions.png) no-repeat 50% 50%; } /* Godmode images */ #icon_god-gismaps { - background-image: url(../../images/gm_gis.png); + background: url(../../images/gm_gis.png) no-repeat 50% 50%; } #icon_god-agents { - background-image: url(../../images/gm_monitoring.png); + background: url(../../images/gm_monitoring.png) no-repeat 50% 50%; } #icon_god-massive { - background-image: url(../../images/gm_massive_operations.png); + background: url(../../images/gm_massive_operations.png) no-repeat 50% 50%; } #icon_god-services { - background-image: url(../../images/box.png); + background: url(../../images/box.png) no-repeat 50% 50%; } #icon_god-modules { - background-image: url(../../images/gm_modules.png); + background: url(../../images/gm_modules.png) no-repeat 50% 50%; } #icon_god-alerts { - background-image: url(../../images/gm_alerts.png); + background: url(../../images/gm_alerts.png) no-repeat 50% 50%; } #icon_god-dbmaint { - background-image: url(../../images/gm_db.png); + background: url(../../images/gm_db.png) no-repeat 50% 50%; } #icon_god-users { - background-image: url(../../images/gm_users.png); + background: url(../../images/gm_users.png) no-repeat 50% 50%; } #icon_god-reporting { - background-image: url(../../images/reporting_edit.png); + background: url(../../images/reporting_edit.png) no-repeat 50% 50%; } #icon_god-servers { - background-image: url(../../images/gm_servers.png); + background: url(../../images/gm_servers.png) no-repeat 50% 50%; } #icon_god-audit { - background-image: url(../../images/gm_log.png); + background: url(../../images/gm_log.png) no-repeat 50% 50%; } #icon_god-netflow { - background-image: url(../../images/gm_netflow.png); + background: url(../../images/gm_netflow.png) no-repeat 50% 50%; } #icon_god-setup { - background-image: url(../../images/gm_setup.png); + background: url(../../images/gm_setup.png) no-repeat 50% 50%; } #icon_god-policies { - background-image: url(../../images/gm_policies.png); + background: url(../../images/gm_policies.png) no-repeat 50% 50%; } #icon_oper-inventory { - background-image: url(../../images/page_white_text.png); + background: url(../../images/page_white_text.png) no-repeat 50% 50%; } #icon_god-tag { - background-image: url(../../images/tag_red.png); + background: url(../../images/tag_red.png) no-repeat 50% 50%; } #icon_god-events { - background-image: url(../../images/gm_events.png); + background: url(../../images/gm_events.png) no-repeat 50% 50%; } #menu_container { @@ -232,3 +237,40 @@ left: -80px; background-color: #AAA; } + + +ul { + margin: 0; + padding: 0; + list-style: none; + } + +ul li { + position: relative; + } + +li ul { + position: absolute; + left: 149px; /* Set 1px less than menu width */ + top: 0; + display: none; +} + +/* Styles for Menu Items */ +ul li a { + display: block; + text-decoration: none; + color: #777; + background: #fff; /* IE6 Bug */ + padding: 5px; + border: 1px solid #ccc; + border-bottom: 0; +} + +/* Fix IE. Hide from IE Mac \*/ +* html ul li { float: left; height: 1%; } +* html ul li a { height: 1%; } +/* End */ + +ul li a:hover { color: #E2144A; background: #f9f9f9; } /* Hover Styles */ +li ul li a { padding: 2px 5px; } /* Sub Menu Styles */ diff --git a/pandora_console/include/styles/pandora.css b/pandora_console/include/styles/pandora.css index 9f87bb2574..65f631accf 100755 --- a/pandora_console/include/styles/pandora.css +++ b/pandora_console/include/styles/pandora.css @@ -40,7 +40,7 @@ body { } div#page { - background: #fafafa; + background: #FFF; background-image: none; } @@ -220,31 +220,22 @@ div#db_ftxt { } div#container { margin: 0 auto; - width: 960px; + min-width: 960px; text-align: left; #border-left: solid 2px #000; #border-right: solid 2px #000; #border-top: solid 2px #000; #margin-top: 5px; - background: #fafafa; + height: 2000px; + background: #FFF; } div#page { width: 960px; clear: both; } div#main { - background: #fafafa; - background-image: none; - width: 785px; - min-height: 700px; - float: right; - padding-left: 0px; - padding-top: 0px; - padding-bottom: 20px; - margin-bottom: 25px; - margin-top: 0px; - margin-left: 0px; - margin-right: 0px; + width: 90%; + margin: 0px 0px 0px 7%; } div#main_help { width: 100%; @@ -317,8 +308,9 @@ div#menu_container { } div#menu { - width: 175px; + width: 60px; float: left; + margin-top: 10px; } div#head { @@ -326,8 +318,11 @@ div#head { width: 100%; height: 62px; padding-top: 0px; - margin-bottom: 8px; + margin-bottom: 20px; background-color: #274C00; + border-bottom-style: solid; + border-bottom-width: 5px; + border-color: #80BA27; } .fixed_header { @@ -866,18 +861,18 @@ th { } tr.datos, tr.datost, tr.datosb , tr.datos_id, tr.datosf9 { - background-color: #eaeaea; + #background-color: #eaeaea; } tr.datos2, tr.datos2t, tr.datos2b, tr.datos2_id , tr.datos2f9 { - background-color: #f2f2f2; + #background-color: #f2f2f2; } tr.datos:hover, tr.datost:hover, tr.datosb:hover, tr.datos_id:hover, tr.datosf9:hover, tr.datos2:hover, tr.datos2t:hover, tr.datos2b:hover, tr.datos2_id:hover, tr.datos2f9:hover { - background-color: #efefef; + #background-color: #efefef; } /* Checkbox styles */ @@ -1087,15 +1082,16 @@ div.title_line { background: #FAFAFA; } #menu_tab_frame_view { - background: #FAFAFA; + background: #FFF; } #menu_tab_frame, #menu_tab_frame_view { display: block !important; - border-bottom: 1px solid #b3b3b3; + border-bottom: 2px solid #80BA27; /* float:left; */ - margin-left: -8px; - min-height: 25px; + margin-left: 0px !important; + max-height: 31px; + min-height: 31px; padding-right: 28px; width: 100%; } @@ -1219,8 +1215,9 @@ div.title_line { } #menu_tab_left li a, #menu_tab_left li span { /* text-transform: uppercase; */ - padding: 3px 5px 2px 0px; + padding: 0px 0px 0px 0px; color: #fff; + font-size: 9pt; font-weight: bold; line-height: 18px; } @@ -1238,18 +1235,18 @@ div.title_line { #menu_tab_left ul.mn li.view { background: #82b92e; - max-width: 450px; - min-width: 300px; - padding: 2px 5px 0px; + max-width: 20%; + min-width: 15%; + padding: 5px 5px 0px; + text-align: center; + -moz-border-top-right-radius: 3px; + -webkit-border-top-right-radius: 3px; + border-top-right-radius: 3px; - -moz-border-top-right-radius: 5px; - -webkit-border-top-right-radius: 5px; - border-top-right-radius: 5px; - - -moz-border-top-left-radius: 5px; - -webkit-border-top-left-radius: 5px; - border-top-left-radius: 5px; - margin-left:0px; + -moz-border-top-left-radius: 3px; + -webkit-border-top-left-radius: 3px; + border-top-left-radius: 3px; + margin-left:0px !important; overflow-y: hidden; } @@ -1372,17 +1369,17 @@ span.rmess, span.nrmess { table.databox { background-color: #f9faf9; - border-spacing: 2px; - -moz-box-shadow: 1px 1px 1px #DDD !important; - -webkit-box-shadow: 1px 1px 1px #DDD !important; - box-shadow: 1px 1px 1px #DDD !important; + border-spacing: 0px; + -moz-box-shadow: 0px 0px 0px #DDD !important; + -webkit-box-shadow: 0px 0px 0px #DDD !important; + box-shadow: 0px 0px 0px #DDD !important; } .databox td, .databox th { - -moz-border-radius: 4px; - -webkit-border-radius: 4px; - border-radius: 4px; - border: 0px solid #fff; + -moz-border-radius: 0px; + -webkit-border-radius: 0px; + border-radius: 0px; + border: 0px none #fff; } .databox th { @@ -1898,12 +1895,7 @@ div.warn { padding: 2px 1px 6px 25px; } -.menu li, .menu li.selected, .menu li.not_selected { - display: block; - min-height: 33px; - border-bottom: 1px solid #424242; - vertical-align: middle; -} + .submenu_not_selected { font-weight: normal !important; @@ -1912,6 +1904,7 @@ div.warn { /* Submenus havent borders */ .submenu_not_selected, .submenu_selected, .submenu2 { border: 0px !important; + min-height: 0px !important; } /* Pandora width style theme */ @@ -1923,13 +1916,6 @@ div#page { width: auto; } div#main { - width: auto; - float: none; - margin-top: 10px; - margin-left: 185px; - margin-right: 10px; - padding-bottom: 10px; - background: #ECECEC; min-width: 720px; } div#head { @@ -1960,7 +1946,8 @@ div#steps_clean { width: 100%; padding-right: 0px; margin-left: 0px !important; - height: 27px; + margin-bottom: 15px; + height: 31px; } div#events_list { float: left; @@ -2271,12 +2258,6 @@ td.datos_greyf9, td.datos_bluef9, td.datos_greenf9, td.datos_redf9, td.datos_yel background-color: #fff !important; } -.submenu li, submenu_selected { - min-height: 25px !important; - /*height: 25px !important;*/ - padding-bottom: 0px; -} - ul.operation li a:hover { #font-weight: bold; } @@ -2331,12 +2312,22 @@ li.links a:hover { .menu li, .menu li.selected, .menu .li.not_selected { border-radius: 0px 0px 0px 0px; background-color: #373737 !important; + display: block; + min-height: 50px; + border-bottom: 0px none #424242; + vertical-align: middle; } #menu_tab li.separator { /* Empty */ } +.operation{ + border-top-right-radius: 5px; + border-right-style: solid; + border-right-width: 0px; +} + input#text-id_parent.ac_input, input, textarea, select { background-color: #ffffff !important; border: 1px solid #cbcbcb; diff --git a/pandora_console/operation/menu.php b/pandora_console/operation/menu.php index 3452f0166b..12cc674fab 100644 --- a/pandora_console/operation/menu.php +++ b/pandora_console/operation/menu.php @@ -124,46 +124,51 @@ if (check_acl ($config['id_user'], 0, "RR")) { $sub["godmode/reporting/map_builder"]["refr"] = 60; } - $sub2 = array (); + $layouts = db_get_all_rows_in_table ('tlayout', 'name'); if ($layouts === false) { $layouts = array (); } - $id = (int) get_parameter ('id', -1); - - $firstLetterNameVisualToShow = array('_', ',', '[', '('); - - $sub2 = array(); - - foreach ($layouts as $layout) { - if (! check_acl ($config["id_user"], $layout["id_group"], "AR")) { - continue; - } - $name = io_safe_output($layout['name']); - if (empty($name)) { - $firstLetter = ''; - } - else { - $firstLetter = $name[0]; - } - if (!in_array($firstLetter, $firstLetterNameVisualToShow)) { - continue; - } - $sub2["operation/visual_console/render_view&id=".$layout["id"]]["text"] = mb_substr ($name, 0, 19); - $sub2["operation/visual_console/render_view&id=".$layout["id"]]["title"] = $name; - if (!empty($config['vc_refr'])) { - $sub2["operation/visual_console/render_view&id=".$layout["id"]]["refr"] = $config['vc_refr']; - } - elseif (((int)get_parameter('refr', 0)) > 0) { - $sub2["operation/visual_console/render_view&id=".$layout["id"]]["refr"] = (int)get_parameter('refr', 0); - } - else { - $sub2["operation/visual_console/render_view&id=".$layout["id"]]["refr"] = 0; + else{ + $sub2 = array (); + $id = (int) get_parameter ('id', -1); + + $firstLetterNameVisualToShow = array('_', ',', '[', '('); + + $sub2 = array(); + + foreach ($layouts as $layout) { + if (! check_acl ($config["id_user"], $layout["id_group"], "AR")) { + continue; + } + $name = io_safe_output($layout['name']); + if (empty($name)) { + $firstLetter = ''; + } + else { + $firstLetter = $name[0]; + } + if (!in_array($firstLetter, $firstLetterNameVisualToShow)) { + continue; + } + $sub2["operation/visual_console/render_view&id=".$layout["id"]]["text"] = mb_substr ($name, 0, 19); + $sub2["operation/visual_console/render_view&id=".$layout["id"]]["title"] = $name; + if (!empty($config['vc_refr'])) { + $sub2["operation/visual_console/render_view&id=".$layout["id"]]["refr"] = $config['vc_refr']; + } + elseif (((int)get_parameter('refr', 0)) > 0) { + $sub2["operation/visual_console/render_view&id=".$layout["id"]]["refr"] = (int)get_parameter('refr', 0); + } + else { + $sub2["operation/visual_console/render_view&id=".$layout["id"]]["refr"] = 0; + } } + $sub["godmode/reporting/map_builder"]["sub2"] = $sub2; } - $sub["godmode/reporting/map_builder"]["sub2"] = $sub2; + + $sub["godmode/reporting/graphs"]["text"] = __('Custom graphs'); //Set godomode path diff --git a/pandora_console/operation/servers/recon_view.php b/pandora_console/operation/servers/recon_view.php index 0c2abf0526..b062a89fee 100644 --- a/pandora_console/operation/servers/recon_view.php +++ b/pandora_console/operation/servers/recon_view.php @@ -13,169 +13,169 @@ // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. - // Load global vars global $config; check_login (); -require_once ($config["homedir"] . '/include/functions_graph.php'); -require_once ($config["homedir"] . '/include/functions_servers.php'); -require_once ($config['homedir'] . "/include/functions_network_profiles.php"); - -if (check_acl ($config['id_user'], 0, "AW")) { - $options['manage']['text'] = "" . html_print_image("images/setup.png", true, array('title' => __('Manage'))) . ""; -} - -$options[]['text'] = "" . html_print_image("images/refresh_mc.png", true, array('title' => __('Refresh'))) . ""; - - -ui_print_page_header (__('Recon View'), "images/op_recon.png", false, "", false, $options); - - if (! check_acl ($config['id_user'], 0, "PM")) { db_pandora_audit("ACL Violation", "Trying to access recon task viewer"); require ("general/noaccess.php"); return; } - -$modules_server = 0; -$total_modules = 0; -$total_modules_data = 0; - -// -------------------------------- -// FORCE A RECON TASK -// -------------------------------- -if (check_acl ($config['id_user'], 0, "PM")) { - if (isset ($_GET["force"])) { - $id = (int) get_parameter_get ("force", 0); - - servers_force_recon_task($id); - } -} - - //Get all recon servers $servers = db_get_all_rows_sql('SELECT * FROM tserver WHERE server_type = 3'); if ($servers === false) { $servers = array (); - + return; } - -foreach ($servers as $serverItem) { - $id_server = $serverItem["id_server"]; - - - $server_name = servers_get_name ($id_server); - $recon_tasks = db_get_all_rows_field_filter ("trecon_task", "id_recon_server", $id_server); - - // Show network tasks for Recon Server - if ($recon_tasks === false) { - $recon_tasks = array (); +else{ + $recon_task = db_get_all_rows_sql('SELECT * FROM trecon_task'); + if ($recon_task === false) { + ui_print_page_header (__('Recon View'), "images/op_recon.png", false, "", false); + require_once ($config['homedir'] . "/general/firts_task/recon_view.php"); + return; } + else{ + require_once ($config["homedir"] . '/include/functions_graph.php'); + require_once ($config["homedir"] . '/include/functions_servers.php'); + require_once ($config['homedir'] . "/include/functions_network_profiles.php"); - $table->cellpadding = 4; - $table->cellspacing = 4; - $table->width = "99%"; - $table->class = "databox"; - $table->head = array (); - $table->data = array (); - $table->align = array (); - - $table->head[0] = __('Force'); - $table->align[0] = "center"; - - $table->head[1] = __('Task name'); - $table->align[1] = "center"; - - $table->head[2] = __('Interval'); - $table->align[2] = "center"; - - $table->head[3] = __('Network'); - $table->align[3] = "center"; - - $table->head[4] = __('Status'); - $table->align[4] = "center"; - - $table->head[5] = __('Template'); - $table->align[5] = "center"; - - $table->head[6] = __('Progress'); - $table->align[6] = "center"; - - $table->head[7] = __('Updated at'); - $table->align[7] = "center"; - - $table->head[8] = __('Edit'); - $table->align[8] = "center"; - - foreach ($recon_tasks as $task) { - $data = array (); - - if($task["disabled"] == 0) { - $data[0] = ''; - $data[0] .= html_print_image ("images/target.png", true, array ("title" => __('Force'))); - $data[0] .= ''; - } - else { - $data[0] = ''; - } - - $data[1] = ''. $task["name"].''; - - $data[2] = human_time_description_raw ($task["interval_sweep"]); - - if ($task["id_recon_script"] == 0){ - $data[3] = $task["subnet"]; - } - else { - $data[3] = __("N/A"); - } - - if ($task["status"] <= 0) { - $data[4] = __('Done'); - } - else { - $data[4] = __('Pending'); + if (check_acl ($config['id_user'], 0, "AW")) { + $options['manage']['text'] = "" . html_print_image("images/setup.png", true, array('title' => __('Manage'))) . ""; } - if ($task["id_recon_script"] == 0){ - // Network recon task - $data[5] = html_print_image ("images/network.png", true, array ("title" => __('Network recon task')))."  "; - $data[5] .= network_profiles_get_name ($task["id_network_profile"]); - } - else { - // APP recon task - $data[5] = html_print_image ("images/plugin.png", true). "  "; - $data[5] .= db_get_sql (sprintf("SELECT name FROM trecon_script WHERE id_recon_script = %d", $task["id_recon_script"])); - } - - if ($task["status"] <= 0 || $task["status"] > 100) { - $data[6] = "-"; - } - else { - $data[6] = progress_bar($task['status'], 100, 20, __('Progress').':'.$task["status"].'%', 1); - } - - $data[7] = ui_print_timestamp ($task["utimestamp"], true); + $options[]['text'] = "" . html_print_image("images/refresh_mc.png", true, array('title' => __('Refresh'))) . ""; - if (check_acl ($config["id_user"], $task["id_group"], "PM")) { - $data[8] = ''.html_print_image ("images/wrench_orange.png", true).''; + ui_print_page_header (__('Recon View'), "images/op_recon.png", false, "", false, $options); + + $modules_server = 0; + $total_modules = 0; + $total_modules_data = 0; + + // -------------------------------- + // FORCE A RECON TASK + // -------------------------------- + if (check_acl ($config['id_user'], 0, "PM")) { + if (isset ($_GET["force"])) { + $id = (int) get_parameter_get ("force", 0); + servers_force_recon_task($id); + } } - else { - $data[8] = ''; + + foreach ($servers as $serverItem) { + $id_server = $serverItem["id_server"]; + $server_name = servers_get_name ($id_server); + $recon_tasks = db_get_all_rows_field_filter ("trecon_task", "id_recon_server", $id_server); + + // Show network tasks for Recon Server + if ($recon_tasks === false) { + $recon_tasks = array (); + } + + $table->cellpadding = 4; + $table->cellspacing = 4; + $table->width = "99%"; + $table->class = "databox"; + $table->head = array (); + $table->data = array (); + $table->align = array (); + + $table->head[0] = __('Force'); + $table->align[0] = "center"; + + $table->head[1] = __('Task name'); + $table->align[1] = "center"; + + $table->head[2] = __('Interval'); + $table->align[2] = "center"; + + $table->head[3] = __('Network'); + $table->align[3] = "center"; + + $table->head[4] = __('Status'); + $table->align[4] = "center"; + + $table->head[5] = __('Template'); + $table->align[5] = "center"; + + $table->head[6] = __('Progress'); + $table->align[6] = "center"; + + $table->head[7] = __('Updated at'); + $table->align[7] = "center"; + + $table->head[8] = __('Edit'); + $table->align[8] = "center"; + + foreach ($recon_tasks as $task) { + $data = array (); + + if($task["disabled"] == 0) { + $data[0] = ''; + $data[0] .= html_print_image ("images/target.png", true, array ("title" => __('Force'))); + $data[0] .= ''; + } + else { + $data[0] = ''; + } + + $data[1] = ''. $task["name"].''; + + $data[2] = human_time_description_raw ($task["interval_sweep"]); + + if ($task["id_recon_script"] == 0){ + $data[3] = $task["subnet"]; + } + else { + $data[3] = __("N/A"); + } + + if ($task["status"] <= 0) { + $data[4] = __('Done'); + } + else { + $data[4] = __('Pending'); + } + + if ($task["id_recon_script"] == 0){ + // Network recon task + $data[5] = html_print_image ("images/network.png", true, array ("title" => __('Network recon task')))."  "; + $data[5] .= network_profiles_get_name ($task["id_network_profile"]); + } + else { + // APP recon task + $data[5] = html_print_image ("images/plugin.png", true). "  "; + $data[5] .= db_get_sql (sprintf("SELECT name FROM trecon_script WHERE id_recon_script = %d", $task["id_recon_script"])); + } + + if ($task["status"] <= 0 || $task["status"] > 100) { + $data[6] = "-"; + } + else { + $data[6] = progress_bar($task['status'], 100, 20, __('Progress').':'.$task["status"].'%', 1); + } + + $data[7] = ui_print_timestamp ($task["utimestamp"], true); + + if (check_acl ($config["id_user"], $task["id_group"], "PM")) { + $data[8] = ''.html_print_image ("images/wrench_orange.png", true).''; + } + else { + $data[8] = ''; + } + array_push ($table->data, $data); + } + + if (empty ($table->data)) { + echo '
'.__("Server") . " " . $server_name . " " . __("has no recon tasks assigned").'
'; + } + else { + html_print_table ($table); + } + unset ($table); } - - array_push ($table->data, $data); } - - if (empty ($table->data)) { - echo '
'.__("This server has no recon tasks assigned").'
'; - } - else { - html_print_table ($table); - } - unset ($table); } ?>