mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-29 15:39:33 +00:00
Added ability to query alerts from Python
This commit is contained in:
parent
25baf5df5e
commit
792e79a429
6 changed files with 176 additions and 11 deletions
|
|
@ -26,6 +26,7 @@ enable_debug = False
|
|||
epoch_end = int(time.time())
|
||||
epoch_begin = epoch_end - 3600
|
||||
maxhits = 10
|
||||
host_ip = "192.168.1.1"
|
||||
|
||||
##########
|
||||
|
||||
|
|
@ -122,6 +123,9 @@ except ValueError as e:
|
|||
try:
|
||||
my_historical = Historical(my_ntopng)
|
||||
|
||||
if(True):
|
||||
my_historical.self_test(iface_id, host_ip)
|
||||
|
||||
print("\n\n==========================\nTop X Remote Hosts Traffic")
|
||||
top_x_remote_ipv4_hosts(my_historical, epoch_begin, epoch_end, maxhits)
|
||||
print("\n\n==========================\nTop X Remote Host/Ports Traffic")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue