Commit Graph

4847 Commits

Author SHA1 Message Date
Bitency
2ba7093d9c api: Added ability to call get_graph_by_port_hostname() with hostname or id (#6936)
* Fix bug get_graph_by_port_hostname() only hostname

From the documentation:

Function: get_graph_by_port_hostname top
Get a graph of a port for a particular device.

hostname can be either the device hostname or id

But the function is only works with a hostname and not with a ID.
I have modified a few things that solve the problem.

* Update api_functions.inc.php
2017-07-04 22:41:22 +01:00
Aldemir Akpinar
9c957ee1d4 webui: Minor visual changes in schedule maintenance window and its modal (#6934)
* webui: minor visual changes in schedule maintenance window and it's modal

* Removed unnecessary comments

* Auto close alerts
2017-07-04 22:29:54 +01:00
Tony Murray
b56c6b6adf fix: fdb tables multiple IPs and IPs from other devices adding extra rows (#6930)
Fix missing IPs because the ARP entries are on different port_id
Update arp discovery to use snmpwalk_group() additional fix in that function
Fix removal of arp entries
Fix a debug output type in fdb discovery
2017-07-04 22:27:43 +01:00
Tony Murray
20b08cf595 refactor: finish logic and definition separation (#6883)
Clean up rewrites to only have function definitions
Move authentication initialization into a function
2017-07-03 15:38:58 -05:00
Tony Murray
f02b551145 feature: Improved install experience (#6915)
always check that the base sql has been imported.
async db building
After this merge, we could move install.php to the end of the install documentation.  Makes a more natural flow.
2017-07-01 21:28:29 +01:00
Tony Murray
08c21b5734 remove some extra html tags (#6925) 2017-06-30 07:45:18 +01:00
Aldemir Akpinar
b378d9e762 webui: Set correct button text when editing an alert template (#6916) 2017-06-29 22:03:43 -05:00
Tony Murray
e8dd72e8db feature: Support fdb table on generic devices (#6902)
* feature: support fdb table on generic devices
refactored code to use snmpwalk_group
refactored ajax table code to use joins and reduce extra queries
add indexes for device_id and port_id, drop primary index
Make all columns sortable
Fix a few other small issues

* Add index for vlan_id since that field can be searched by the user

* fix whitespace

* Rename 197.sql to 198.sql

* set row count for table
2017-06-29 21:03:56 +01:00
Tony Murray
5f8729b1a0 refactor: update the default config generated by install.php (#6914) 2017-06-29 07:09:22 +01:00
Dubby85
0fd7f3f5ed Fix for API services bug #6894 (#6895)
* Fixed an issue with the output including all services from a host that had a single matched service  regardless of whether they matched the filter.

* Cleaned up some bits

* Updated based on murrants suggestions

* A couple small cleanups
2017-06-28 01:00:46 -05:00
rzig
1ba6381d61 security: Enable support for secure cookies (#6868)
* Enable secure cookies for authentication

Enables secure cookies for authentication when HTTPS is used.

* Add line with example secure session cookies

* Fix comment line that's too long

* Remove session secure cookie config

* Added secure cookie config to init.php

Commented out because having this enabled will prevent the server from sending cookies over HTTPS.

* Enable secure cookies if config value provided

* Make code formatting consistent

* Remove secure cookie config

* Use $config['secure_cookies'] to set cookies

* Add default option to turn secure cookies on

* Fix formatting issues

* Set secure cookies to default to false

* Add info about secure cookies

* Fix formatting

* Remove trailing whitespace

* move secure cookie default config to defaults.inc.php

* Remove trailing whitespace

* Fix formatting

* Remove empty line by rrd config

* Remove whitespace
2017-06-26 14:21:21 +01:00
Tony Murray
bf0df7266a feature: Added fdb discovery module (#6887)
revert the context_name changes to snmp.inc.php and use the same method as other parts of the code
2017-06-26 13:58:17 +01:00
Neil Lathwood
54365985a6 Revert "feature: fdb tables (#6616)" (#6886)
This reverts commit 81ddab86af.
2017-06-25 07:04:04 +01:00
Lorenzo Zafra
81ddab86af feature: fdb tables (#6616)
* feature: FDB TABLES for ios and timos

* Fixed coding style issues

* renamed fdb.sql to 191.sql

* fixed travisCI issue

* FDB table discovery working on IOS

* Fixed bug: failing to insert fdb entries into database

* Fix phpcbf issue

* moved sql schema

* rename sql schema

* Add (tentative) FDB support for HP Comware switches

* build schema

* schema changes

* run build schema.......

* FBD Table discovery working on HP ComWare

* FBD Table discovery working on HP ComWare

* Add FDB support for HP Comware

* Discovery regex fix, tested and works for cisco 3750, 2960, 6509

* Use vlan_id instead of raw vlan. Remove Nokia implementation as vlans are not being discovered for it at the moment.

* Use vlan_id instead of vlan.

* Add debug messages, comware support

* Sorry.. phpunit isnt working for me

* Use a file structure instead of if statement per OS

* Make inserts to vlan table if entry does not exist.

* Rename sql schema file

* Use existing context name

Improve output and database synchronization

Remove chromephp and if ios

rename sqlfile

add comware back

update schema

* Delete TIMETRA-CHASSIS-MIB

* Delete TIMETRA-FILTER-MIB

* change index to bigint to be safe
2017-06-24 22:07:31 -05:00
algebur
62cde819a0 webui: Added "system name" for the "Services list" (#6873)
* Update devices.inc.php

* Update devices.inc.php

* Add "system name" to "hostname"

It is easy to watch hosts using system names and IP addresses

* Deleted -H for checking srevice

How wrote this code? 
I could not use additional plugins, because system adds "-H" when plugin runs. But some plugins don't use "-H"

* changed to original file

* Update services.inc.php
2017-06-23 22:17:01 +01:00
dnapper
02a7949c5e newdevice: Added Support for Benu OS (#6857)
* Added Basic OS support for Benu

* Benu OS take 2

* Benu OS take 3

* Benu round 4 - this time for real

* added benu sensors

* reamed to benuos, renamed mibs, sensor rewrite pending

* upated sensors to use snmp_get_multi

* rename yaml

* rename yaml

* updated mempool discover to use multi get, fixed whitepaces, removed old commented out code from polling

* changed detection from sysDescr to sysObjectId

* Update benuos.yaml

* Update benuos.inc.php

* Update benuos.inc.php

* Update benuos.inc.php

* Update benuos.inc.php
2017-06-22 21:45:18 +01:00
network-guy
b3c88925d4 webui: Allow editing and deleting of lapsed alert schedules (#6878) 2017-06-22 20:29:04 +01:00
Tony Murray
52fabcb770 api: Add search by os to list_devices (#6861) 2017-06-19 19:49:43 +02:00
Lorenzo Zafra
283392c9a7 newdevice: Added support for Chatsworth PDU (legacy old pdus not sure model number) (#6833)
* newdevice: AXIS Audio Appliance

* newdevice: chatsworth pdus

* Renamed chatsworth to chatsworth-pdu
2017-06-17 15:31:01 +01:00
Aldemir Akpinar
572277bfaa Also fix the graph generating code for NfSen rrds (#6835)
* Also fix the graph generating code for NfSen rrds

* Updated NfSen document as well
2017-06-14 20:32:30 +01:00
Neil Lathwood
19cdf8f684 newdevice: Added support for Schneider PowerLogic (#6809) 2017-06-13 16:20:12 -05:00
FTBZ
3a62c83642 newdevice: Added additional sensors to Axis camera (#6827)
newdevice: Added additional sensors to Axis camera (#6827)
2017-06-13 21:37:01 +01:00
Aldemir Akpinar
0ede9525b0 feature: Added support to use IP addresses for NfSen filenames (#6824)
feature: Added support to use IP addresses for NfSen filenames (#6824)
2017-06-13 21:35:33 +01:00
Aldemir Akpinar
57c9151363 webui: Add bootgrid for authlog page, and fix poll-log searchbar layout on smaller screens (#6805) 2017-06-09 19:50:56 +01:00
Neil Lathwood
4f4719b66a webui: Updated all tables to have the same set number of items showing (#6798) 2017-06-08 22:10:30 -05:00
Neil Lathwood
1d70d3e96a newdevice: Added detection for Atal Ethernetprobe (#6778)
* newdevice: Added detection for Atal Ethernetprobe

* updated to ethernetprobe2

* added temp and humidity sensors
2017-06-08 19:05:10 +01:00
Freddie Cash
dd97ba1046 Update bind.inc.php (#6795)
Fix spelling mistake:  Quiries --> Queries
2017-06-06 23:09:11 +01:00
crcro
96f066189e feature: Added pi-hole application support (#6782)
* added data to webui

* added last step on docs

* fix scrutinizer issue

* fix blank lines
2017-06-05 23:00:09 +01:00
Aaron Goulet
8c4efc83e1 refactor: Updated graphs to use safer RRD check (#6781)
Graphs that were using `file_exists()` to check for the presence of RRD
files now use `rrdtool_check_rrd_exists()` instead. This is a fix for
distributed poller configurations that are running `rrdcached` on a
different host.
2017-06-05 22:49:04 +01:00
Neil Lathwood
3fbdc749e0 webui: Allow iframe in notes widget (#6773)
* webui: Allow iframe in notes widget

* added height+width to notes widget
2017-06-03 17:14:16 +01:00
CZ
f784228e93 newdevice: Added support for Adva FSP150CC and FSP3000R7 Series (#6696)
* ADVA device support
- sensors for temperature, voltage, current and dbm
- ADVA mibs for FSP150CC and FSP3000R7

* sysObjectId - changed to level above instead of two entries

* OS for FSP150 and FSP3000R7 now in two seperate OS definitions
- split the files
- removed sysObjectId check for each
- removed hardcoded sensor limits
- removed more generic MIBs

* standardized variables / corrected declarations

* added missing MIB, style check code

* - corrected 'current' readings by adding $devisor
- changed rrdfile names to sensorname+$index
- moved LLDP-V2 mibs to main mib directory
2017-06-02 21:07:55 +01:00
Slashdoom
fbf157c053 webui: Load google maps js library only if globe map widget is used
webui: Load google maps js library only if globe map widget is used
2017-06-02 21:02:50 +01:00
network-guy
dc498be4f0 newdevice: Added Current Connections Graph for Cisco WSA (#6734)
* Added current connections graph for AsyncOS devices

* Fixed issues with AsyncOS connections polling and add name to AUTHORS file

* Update 194.sql
2017-06-02 20:58:02 +01:00
Seti
750b183361 webui: Fix nav bar Linebreaks (#6770)
On width between 1199px and 1280px there is a navibar linebreak, and on
some lists there are controlles hidden.
2017-06-02 19:57:27 +01:00
Maciej Kaczkowski
528350177d newdevice: Arris C4c (#6662)
* newdevice:  Arris C4c, convert arris.png to arris.svg, added temperature sensors

* removed debug

* converted snmp_walk to snmpwalk_cache_oid_num

* added test, fixed formatting

* fixed logo

* removed height and width from logo

* revert arris.svg
2017-06-01 18:46:13 -05:00
pblasquez
cc38930007 feature: Added elasticsearch transport and docs (#6687)
* Add elasticsearch transport and docs

* Fix formatting

* Fix formatting

* Remove librenms string from sql file

* Add missing states

* Use ifAlias not ifDescr

* Update Alerting.md

* Remove unused es_enabled flag

* Fix storage column names

* Fix processor columns

* Rename 194.sql to 193.sql
2017-06-01 12:16:39 +01:00
Chris A. Evans
8c8d591d67 newdevice: Add basic support for CradlePoint WiPipe Cellular Broadband Routers (#6695)
* Add basic support for CradlePoint Ceullular Broadband Rotuers

 	new file:   html/images/os/cradlepoint.png
 	new file:   includes/definitions/wipipe.yaml
 	new file:   includes/discovery/sensors/dbm/wipipe.inc.php
 	new file:   includes/discovery/sensors/pre-cache/wipipe.inc.php
 	new file:   includes/discovery/sensors/state/wipipe.inc.php
 	new file:   includes/polling/os/wipipe.inc.php

* Added snmprec test file

* Updated definitions file

* Updated copyright blocks and comments

* Added WIPIPE-MIB#

*  	renamed:    tests/snmpsim/wipipe.smmprec -> tests/snmpsim/wipipe.snmprec

*  	copied:     html/images/os/cradlepoint.png -> html/images/logos/cradlepoint.png
 	modified:   html/images/os/cradlepoint.png
 	modified:   includes/definitions/wipipe.yaml
 	modified:   includes/discovery/sensors/pre-cache/wipipe.inc.php
 	modified:   includes/polling/os/wipipe.inc.php

* Changes requested by laf

 	modified:   includes/discovery/sensors/dbm/wipipe.inc.php
 	modified:   includes/discovery/sensors/pre-cache/wipipe.inc.php
 	modified:   includes/polling/os/wipipe.inc.php

* Reworked devFWUpgradeStatus state sensor
 	modified:   includes/discovery/sensors/state/wipipe.inc.php

* Fixed hardware/OS version detection
 	modified:   includes/polling/os/wipipe.inc.php

* moved mib file to correct location
2017-05-31 21:45:31 +01:00
crcro
5af3048a76 fix: Ensure rrdtool web settings aren't overwrote by defaults (#6698)
* fix for web settings

* revert db config

* revert description

* ensure rrdtool path is set
2017-05-30 19:44:40 +01:00
SLMitch
dbaad709fe fix: add column title under device bgp tab (#6747)
* add column title

* Change column name

Change the column name to `Family` to be consistent
2017-05-30 07:54:43 -05:00
Søren Rosiak
88a490a969 newdevice: Add support for Halon Gateway (#6716)
newdevice: Add support for Halon Gateway
2017-05-24 00:00:43 -05:00
Nick Peelman
88e71a58c1 webui: make login form more mobile-friendly (#6707)
* make login form more mobile-friendly

Disable autocomplete, autocorrect, autocapitalize, and spellcheck on username and password input forms.

* Update logon.inc.php
2017-05-23 23:58:38 -05:00
Neil Lathwood
d48be5f507 newdevice: Added detection for Cisco EPC devices (#6690)
* newdevice: Added detection for Cisco EPC devices

* updated test file

* added dbm support

* added snr support
2017-05-23 10:28:44 -05:00
Neil Lathwood
14a143a6a7 fix: Fixed http-auth not honouring http_auth_guest (#6699)
* fix: Fixed http-auth not honouring http_auth_guest

* Always fall back to http_auth_guest.
Make sure $username is set, otherwise, we won't try to authenticate.

* reverted elseif to default to http-auth-guest

* Update authenticate.inc.php

simplify logic
2017-05-23 08:40:57 +01:00
Tony Murray
4d0c75343e fix: Two-Factor Authentication (#6672)
* fix: Two-Factor Auth
Moved library to a class to take advantage of namespacing and auto loading.
Update the two factor code to use the AuthenticationException for error messages.
Fix remember me to work with 2fa.

* missing change
2017-05-18 22:08:10 +01:00
Tony Murray
f43ad4629c remove eval() (#6648) 2017-05-17 22:38:00 +01:00
Tony Murray
155d9de8dc fix: two-factor auth and restore some auth speed regressions (#6649) 2017-05-15 23:13:07 -05:00
Tony Murray
683a10e723 fix: Improve authentication load time and security (#6615)
* fix: minimize session open time
page/graphs speedup part 2

Write close the session as soon as we no longer need to write to it. Prevents the session from blocking other requests.
Do not run through full authentication functions if the session is already authenticated.
Removes password from the session as well as some items to prevent session fixation from #4608.

WARNING: This will cause issues for ad/ldap users who do not have a bind user configured!

* Do no erase username when using cookie auth.
Properly close the session in ajax_setresolution.php

* write close the session as soon as possible in ajax_setresolution.php

* Remove session regeneration. It is not compatible with the current code and would require more changes.

* Totally refactor authentication.  Extract code to functions for re-use and improved readability

* Use exceptions for authentication and error logging
Tested: mysql, ad_auth with and without bind user

* fix a couple scrutinizer issues

* fix reauthenticate in radius
2017-05-15 22:18:23 -05:00
Neil Lathwood
612186dabf alerting: Added option to enable/disable option for sending alerts to normal users (#6590)
* alerting: Added option to enable/disable option for sending alerts to normal users

* Update notifications.rss

* added missing sql

* Fix schema

* Update notifications.rss
2017-05-15 23:35:26 +01:00
Tony Murray
74c7611bca newdevice: Make TiMOS detection more generic, rebrand to Nokia (#6645)
Includes all product lines SR, SAS, ESS
2017-05-15 23:07:14 +01:00
Neil Lathwood
0338734fe7 feature: Added script (scripts/test-template.php) to test alert templates (#6631)
* feature: Added script (scripts/test-template.php) to test alert templates

* moved remaining functions, fixed php 5.3 and include dir

* added docs on use for test-template script
2017-05-13 06:46:08 -05:00