mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
* Security fix: unauthorized access Affects nginx users: Moved php files outside of public html directory (Apache was protected by .htaccess) Affects all users: Some files did not check for authentication and could disclose some info. Better checks before including files from user input * git mv html/includes/ includes/html git mv html/pages/ includes/html/
70 lines
2.3 KiB
PHP
70 lines
2.3 KiB
PHP
<?php
|
|
|
|
if (rrdtool_check_rrd_exists(get_port_rrdfile_path($device['hostname'], $port['port_id']))) {
|
|
$iid = $id;
|
|
echo '<div class="panel panel-default">
|
|
<div class="panel-heading">
|
|
<h3 class="panel-title">Interface Traffic</h3>
|
|
</div>';
|
|
$graph_type = 'port_bits';
|
|
|
|
echo '<div class="panel-body">';
|
|
include 'includes/html/print-interface-graphs.inc.php';
|
|
echo '</div></div>';
|
|
|
|
echo '<div class="panel panel-default">
|
|
<div class="panel-heading">
|
|
<h3 class="panel-title">Interface Packets</h3>
|
|
</div>';
|
|
$graph_type = 'port_upkts';
|
|
|
|
echo '<div class="panel-body">';
|
|
include 'includes/html/print-interface-graphs.inc.php';
|
|
echo '</div></div>';
|
|
|
|
echo '<div class="panel panel-default">
|
|
<div class="panel-heading">
|
|
<h3 class="panel-title">Interface Non Unicast</h3>
|
|
</div>';
|
|
|
|
$graph_type = 'port_nupkts';
|
|
echo '<div class="panel-body">';
|
|
include 'includes/html/print-interface-graphs.inc.php';
|
|
echo '</div></div>';
|
|
|
|
echo '<div class="panel panel-default">
|
|
<div class="panel-heading">
|
|
<h3 class="panel-title">Interface Errors</h3>
|
|
</div>';
|
|
|
|
$graph_type = 'port_errors';
|
|
|
|
echo '<div class="panel-body">';
|
|
include 'includes/html/print-interface-graphs.inc.php';
|
|
echo '</div></div>';
|
|
|
|
if (rrdtool_check_rrd_exists(get_port_rrdfile_path($device['hostname'], $port['port_id'], 'poe'))) {
|
|
echo '<div class="panel panel-default">
|
|
<div class="panel-heading">
|
|
<h3 class="panel-title">PoE</h3>
|
|
</div>';
|
|
$graph_type = 'port_poe';
|
|
|
|
echo '<div class="panel-body">';
|
|
include 'includes/html/print-interface-graphs.inc.php';
|
|
echo '</div></div>';
|
|
}
|
|
|
|
if (rrdtool_check_rrd_exists(get_port_rrdfile_path($device['hostname'], $port['port_id'], 'dot3'))) {
|
|
echo '<div class="panel panel-default">
|
|
<div class="panel-heading">
|
|
<h3 class="panel-title">Ethernet Errors</h3>
|
|
</div>';
|
|
$graph_type = 'port_etherlike';
|
|
|
|
echo '<div class="panel-body">';
|
|
include 'includes/html/print-interface-graphs.inc.php';
|
|
echo '</div></div>';
|
|
}
|
|
}
|