2012-02-06 Ramon Novoa <rnovoa@artica.es>

* operation/netflow/nf_live_view.php: Added ACL checks for filter
	  creation.



git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@5498 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
ramonn 2012-02-06 17:16:38 +00:00
parent 85e6fd471b
commit a42bacb5be
2 changed files with 12 additions and 5 deletions

View File

@ -1,3 +1,8 @@
2012-02-06 Ramon Novoa <rnovoa@artica.es>
* operation/netflow/nf_live_view.php: Added ACL checks for filter
creation.
2012-02-06 Miguel de Dios <miguel.dedios@artica.es>
* godmode/agentes/module_manager.php: only added a comment for to explain

View File

@ -66,7 +66,7 @@ $start_date = $end_date - $period;
ui_print_page_header (__('Netflow live view'), "images/networkmap/so_cisco_new.png", false, "", false, array ());
// Save user defined filter
if ($save != '') {
if ($save != '' && check_acl ($config["id_user"], 0, "AW")) {
// Save filter args
$filter['filter_args'] = netflow_get_filter_arguments ($filter);
@ -80,7 +80,7 @@ if ($save != '') {
}
}
// Update current filter
else if ($update != '' && $filter_id > 0) {
else if ($update != '' && check_acl ($config["id_user"], 0, "AW")) {
// Do not update the filter name and group
$filter_copy = $filter;
unset ($filter_copy['id_name']);
@ -195,9 +195,11 @@ echo '<form method="post" action="index.php?sec=netf&sec2=operation/netflow/nf_l
html_print_table ($table);
html_print_submit_button (__('Draw'), 'draw_button', false, 'class="sub upd"');
html_print_submit_button (__('Save as new filter'), 'save_button', false, 'class="sub upd" onClick="return defineFilterName();"');
if ($filter_id > 0) {
html_print_submit_button (__('Update current filter'), 'update_button', false, 'class="sub upd"');
if (check_acl ($config["id_user"], 0, "AW")) {
html_print_submit_button (__('Save as new filter'), 'save_button', false, 'class="sub upd" onClick="return defineFilterName();"');
if ($filter_id > 0) {
html_print_submit_button (__('Update current filter'), 'update_button', false, 'class="sub upd"');
}
}
echo'</form>';