Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feature: FreeRADIUS application monitoring (#7818)
* Update unbound.inc.php * Update unbound.inc.php * Create unbound_cache.inc.php * Update AUTHORS.md * Update apps.inc.php * Update bind.inc.php * Update bind.inc.php * Update bind.inc.php * Update bind.inc.php * Update tiles.php * Update Applications.md * Update Applications.md * Update Applications.md * Update Applications.md * Update Applications.md * Update Applications.md * Update apps.inc.php * Create freeradius_access.inc.php * Update functions.inc.php * Create freeradius_auth.inc.php * Create freeradius_accounting.inc.php * Create freeradius_proxy_access.inc.php * Create freeradius_proxy_auth.inc.php * Create freeradius_proxy_acct.inc.php * Create freeradius_queue.inc.php * Update and rename freeradius_accounting.inc.php to freeradius_acct.inc.php * Update apps.inc.php * Create freeradius.inc.php * Create freeradius.inc.php * Update freeradius.inc.php * Update freeradius.inc.php * Update freeradius.inc.php * Update freeradius.inc.php * Update freeradius.inc.php * Update Applications.md * Update Applications.md * Update freeradius_access.inc.php * Update freeradius_acct.inc.php * Update freeradius_access.inc.php * Update freeradius_auth.inc.php * Update freeradius_access.inc.php * Update freeradius_acct.inc.php * Update freeradius_proxy_access.inc.php * Update freeradius_proxy_acct.inc.php * Update freeradius_proxy_auth.inc.php * Update freeradius_queue.inc.php * Update freeradius_queue.inc.php * Update freeradius.inc.php * Update freeradius.inc.php * Update freeradius.inc.php * Update freeradius_acct.inc.php * Update freeradius_acct.inc.php * Update freeradius_access.inc.php * Update freeradius_access.inc.php * Update freeradius_auth.inc.php * Update freeradius_proxy_access.inc.php * Update freeradius_proxy_acct.inc.php * Update freeradius_proxy_auth.inc.php * Update freeradius_queue.inc.php
- Loading branch information
Showing
12 changed files
with
466 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
html/includes/graphs/application/freeradius_access.inc.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<?php | ||
require 'includes/graphs/common.inc.php'; | ||
$i = 0; | ||
$scale_min = 0; | ||
$nototal = 1; | ||
$unit_text = 'Per Sec.'; | ||
$rrd_filename = rrd_name($device['hostname'], array('app', 'freeradius-access', $app['app_id'])); | ||
$fr_access_array = array( | ||
'requests' => 'Requests', | ||
'accepts' => 'Accepts', | ||
'rejects'=> 'Rejects', | ||
'challenges' => 'Challenges' | ||
); | ||
$colours = 'mixed'; | ||
$rrd_list = array(); | ||
if (rrdtool_check_rrd_exists($rrd_filename)) { | ||
foreach ($fr_access_array as $ds => $descr) { | ||
$rrd_list[$i]['filename'] = $rrd_filename; | ||
$rrd_list[$i]['descr'] = $descr; | ||
$rrd_list[$i]['ds'] = $ds; | ||
$i++; | ||
} | ||
} else { | ||
echo "file missing: $rrd_filename"; | ||
} | ||
require 'includes/graphs/generic_multi_line.inc.php'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
require 'includes/graphs/common.inc.php'; | ||
$i = 0; | ||
$scale_min = 0; | ||
$nototal = 1; | ||
$unit_text = 'Per Sec.'; | ||
$rrd_filename = rrd_name($device['hostname'], array('app', 'freeradius-acct', $app['app_id'])); | ||
$fr_acct_array = array( | ||
'requests' => 'Requests', | ||
'responses' => 'Responses', | ||
'duplicate_requests' => 'Duplicate Requests', | ||
'malformed_requests' => 'Malformed Requests', | ||
'invalid_requests' => 'Invalid Requests', | ||
'dropped_requests' => 'Dropped Requests', | ||
'unknown_types' => 'Unknown Types' | ||
); | ||
$colours = 'mixed'; | ||
$rrd_list = array(); | ||
if (rrdtool_check_rrd_exists($rrd_filename)) { | ||
foreach ($fr_acct_array as $ds => $descr) { | ||
$rrd_list[$i]['filename'] = $rrd_filename; | ||
$rrd_list[$i]['descr'] = $descr; | ||
$rrd_list[$i]['ds'] = $ds; | ||
$i++; | ||
} | ||
} else { | ||
echo "file missing: $rrd_filename"; | ||
} | ||
require 'includes/graphs/generic_multi_line.inc.php'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<?php | ||
require 'includes/graphs/common.inc.php'; | ||
$i = 0; | ||
$scale_min = 0; | ||
$nototal = 1; | ||
$unit_text = 'Per Sec.'; | ||
$rrd_filename = rrd_name($device['hostname'], array('app', 'freeradius-auth', $app['app_id'])); | ||
$fr_auth_array = array( | ||
'responses' => 'Responses', | ||
'duplicate_requests' => 'Duplicate Requests', | ||
'malformed_requests' => 'Malformed Requests', | ||
'invalid_requests' => 'Invalid Requests', | ||
'dropped_requests' => 'Dropped Requests', | ||
'unknown_types' => 'Unknown Types' | ||
); | ||
$colours = 'mixed'; | ||
$rrd_list = array(); | ||
if (rrdtool_check_rrd_exists($rrd_filename)) { | ||
foreach ($fr_auth_array as $ds => $descr) { | ||
$rrd_list[$i]['filename'] = $rrd_filename; | ||
$rrd_list[$i]['descr'] = $descr; | ||
$rrd_list[$i]['ds'] = $ds; | ||
$i++; | ||
} | ||
} else { | ||
echo "file missing: $rrd_filename"; | ||
} | ||
require 'includes/graphs/generic_multi_line.inc.php'; |
26 changes: 26 additions & 0 deletions
26
html/includes/graphs/application/freeradius_proxy_access.inc.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<?php | ||
require 'includes/graphs/common.inc.php'; | ||
$i = 0; | ||
$scale_min = 0; | ||
$nototal = 1; | ||
$unit_text = 'Per Sec.'; | ||
$rrd_filename = rrd_name($device['hostname'], array('app', 'freeradius-proxy_access', $app['app_id'])); | ||
$fr_proxy_access_array = array( | ||
'requests' => 'Requests', | ||
'accepts' => 'Accepts', | ||
'rejects'=> 'Rejects', | ||
'challenges' => 'Challenges' | ||
); | ||
$colours = 'mixed'; | ||
$rrd_list = array(); | ||
if (rrdtool_check_rrd_exists($rrd_filename)) { | ||
foreach ($fr_proxy_access_array as $ds => $descr) { | ||
$rrd_list[$i]['filename'] = $rrd_filename; | ||
$rrd_list[$i]['descr'] = $descr; | ||
$rrd_list[$i]['ds'] = $ds; | ||
$i++; | ||
} | ||
} else { | ||
echo "file missing: $rrd_filename"; | ||
} | ||
require 'includes/graphs/generic_multi_line.inc.php'; |
29 changes: 29 additions & 0 deletions
29
html/includes/graphs/application/freeradius_proxy_acct.inc.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
require 'includes/graphs/common.inc.php'; | ||
$i = 0; | ||
$scale_min = 0; | ||
$nototal = 1; | ||
$unit_text = 'Per Sec.'; | ||
$rrd_filename = rrd_name($device['hostname'], array('app', 'freeradius-proxy_acct', $app['app_id'])); | ||
$fr_proxy_acct_array = array( | ||
'requests' => 'Requests', | ||
'responses' => 'Responses', | ||
'duplicate_requests' => 'Duplicate Requests', | ||
'malformed_requests' => 'Malformed Requests', | ||
'invalid_requests' => 'Invalid Requests', | ||
'dropped_requests' => 'Dropped Requests', | ||
'unknown_types' => 'Unknown Types' | ||
); | ||
$colours = 'mixed'; | ||
$rrd_list = array(); | ||
if (rrdtool_check_rrd_exists($rrd_filename)) { | ||
foreach ($fr_proxy_acct_array as $ds => $descr) { | ||
$rrd_list[$i]['filename'] = $rrd_filename; | ||
$rrd_list[$i]['descr'] = $descr; | ||
$rrd_list[$i]['ds'] = $ds; | ||
$i++; | ||
} | ||
} else { | ||
echo "file missing: $rrd_filename"; | ||
} | ||
require 'includes/graphs/generic_multi_line.inc.php'; |
28 changes: 28 additions & 0 deletions
28
html/includes/graphs/application/freeradius_proxy_auth.inc.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<?php | ||
require 'includes/graphs/common.inc.php'; | ||
$i = 0; | ||
$scale_min = 0; | ||
$nototal = 1; | ||
$unit_text = 'Per Sec.'; | ||
$rrd_filename = rrd_name($device['hostname'], array('app', 'freeradius-proxy_auth', $app['app_id'])); | ||
$fr_proxy_auth_array = array( | ||
'responses' => 'Responses', | ||
'duplicate_requests' => 'Duplicate Requests', | ||
'malformed_requests' => 'Malformed Requests', | ||
'invalid_requests' => 'Invalid Requests', | ||
'dropped_requests' => 'Dropped Requests', | ||
'unknown_types' => 'Unknown Types' | ||
); | ||
$colours = 'mixed'; | ||
$rrd_list = array(); | ||
if (rrdtool_check_rrd_exists($rrd_filename)) { | ||
foreach ($fr_proxy_auth_array as $ds => $descr) { | ||
$rrd_list[$i]['filename'] = $rrd_filename; | ||
$rrd_list[$i]['descr'] = $descr; | ||
$rrd_list[$i]['ds'] = $ds; | ||
$i++; | ||
} | ||
} else { | ||
echo "file missing: $rrd_filename"; | ||
} | ||
require 'includes/graphs/generic_multi_line.inc.php'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
require 'includes/graphs/common.inc.php'; | ||
$i = 0; | ||
$scale_min = 0; | ||
$nototal = 1; | ||
$unit_text = 'Per Sec.'; | ||
$rrd_filename = rrd_name($device['hostname'], array('app', 'freeradius-queue', $app['app_id'])); | ||
$fr_queue_array = array( | ||
'len_internal' => 'Len Internal', | ||
'len_proxy' => 'Len Proxy', | ||
'len_auth' => 'Len Auth', | ||
'len_acct' => 'Len Acct', | ||
'len_detail' => 'Len Detail', | ||
'pps_in' => 'PPS In', | ||
'pps_out' => 'PPS Out' | ||
); | ||
$colours = 'mixed'; | ||
$rrd_list = array(); | ||
if (rrdtool_check_rrd_exists($rrd_filename)) { | ||
foreach ($fr_queue_array as $ds => $descr) { | ||
$rrd_list[$i]['filename'] = $rrd_filename; | ||
$rrd_list[$i]['descr'] = $descr; | ||
$rrd_list[$i]['ds'] = $ds; | ||
$i++; | ||
} | ||
} else { | ||
echo "file missing: $rrd_filename"; | ||
} | ||
require 'includes/graphs/generic_multi_line.inc.php'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
global $config; | ||
$graphs = array( | ||
'freeradius_access' => 'FreeRADIUS - Access', | ||
'freeradius_auth' => 'FreeRADIUS - Auth', | ||
'freeradius_acct' => 'FreeRADIUS - Acct', | ||
'freeradius_proxy_access' => 'FreeRADIUS - Proxy Access', | ||
'freeradius_proxy_auth' => 'FreeRADIUS - Proxy Auth', | ||
'freeradius_proxy_acct' => 'FreeRADIUS - Proxy Acct', | ||
'freeradius_queue' => 'FreeRADIUS - Queue' | ||
); | ||
foreach ($graphs as $key => $text) { | ||
$graph_type = $key; | ||
$graph_array['height'] = '100'; | ||
$graph_array['width'] = '215'; | ||
$graph_array['to'] = $config['time']['now']; | ||
$graph_array['id'] = $app['app_id']; | ||
$graph_array['type'] = 'application_'.$key; | ||
echo '<div class="panel panel-default"> | ||
<div class="panel-heading"> | ||
<h3 class="panel-title">'.$text.'</h3> | ||
</div> | ||
<div class="panel-body"> | ||
<div class="row">'; | ||
include 'includes/print-graphrow.inc.php'; | ||
echo '</div>'; | ||
echo '</div>'; | ||
echo '</div>'; | ||
} |
Oops, something went wrong.