Commit Graph

183 Commits

Author SHA1 Message Date
Tim Zandbergen 3daa804d5f
SECURITY: Replaced mt_rand with random_bytes
https://huntr.dev/bounties/2-phpservermon/phpservermon/
CWE-1241: Use of Predictable Algorithm in Random Number Generator
2021-06-23 22:06:34 +02:00
Michael 88708240c7
Add error message for missing/invalid header (#1017)
* add error message for missing/invalid header

* Code cleanup

- simplify the check
  - do not invert the result of `preg_match()`
  - do not set the `$result` in loop, it is already set after the loop
- fix the order of code, first set `$this->error` then `$result`
2021-05-31 04:02:20 +02:00
TimZ99 de7c62cbce
Fixed typo in array - related to jabber
Fixes #1049.
2021-04-15 02:52:27 +02:00
Michael 600f63097e
Add more variables for webhook json (#1016)
* Add more variables for webhook json

To allow status specific icons and a special Text defined in the json, not only provide #message as variable, but also #server_ip, #server_label, #server_last_offline_duration and #status.

* Add #server_error as additional variable for webhooks
2021-04-15 02:00:06 +02:00
wienfuchs e5b76ca49e
add feature "add url" to email and telegram (#1085)
Resolved #967.

* add feature "add url" to email and telegram

* Added missing brackets

* Changed $body to correct var $message

And changed PHP_EOL to <br>.

* Changed text a little

* Add dutch translation

Co-authored-by: TimZ99 <TimZ99@users.noreply.github.com>
2021-04-15 01:50:44 +02:00
TimZ99 f1df99c5ae
Moved update script to 3.6.0 2020-08-26 15:59:46 +02:00
TimZ99 e599c18f0b
Merge remote-tracking branch 'origin/develop' into feature/public_page
# Conflicts:
#	README.rst
#	config.php.sample
#	src/includes/psmconfig.inc.php
#	src/lang/en_US.lang.php
#	src/psm/Module/User/Controller/UserController.php
#	src/psm/Util/Install/Installer.php
2020-08-24 22:27:51 +02:00
TimZ99 b94d66bfc0
Added user on upgrade 2020-08-18 17:50:22 +02:00
Daniel Krusky d0f5d18fc4
Added support for Discord using Webhooks (#971)
* Added support for Discord using Webhooks

* Bumped version

* Fixed broken upgrade

* Moved discord below Jabber

* Fixed broken comment

* Added missing translation

* Updated version

* Typo

* Moved Discord under Jabber

* Fixed icons

* Moved Webhook and discord after Jabber

Co-authored-by: Tim <TimZ99@users.noreply.github.com>
2020-08-12 21:33:44 +02:00
milux 9fe598d774
Increased graph data processing speed (#944) 2020-08-12 21:23:47 +02:00
wienfuchs c090a398d1
change rtime to numerical to avoid DB update conflicts (#963) 2020-08-12 21:11:50 +02:00
Malte Grosse 14f6e491cf
webhook support (#951)
* added webhook support

* Added missing upgrade lines

* Removed todo

* Removed linebreak

* Moved webhook below Jabber

* Fixed description not showing

* Moved webhook below jabber

* Indentation and table name fix

* Bumped version

* Fixed “header already sent” error

Co-authored-by: TimZ99 <TimZ99@users.noreply.github.com>
2020-08-12 19:27:13 +02:00
wienfuchs 7deac0815a
changing Windows ping routine back to socket usage, leaving Linux changes made (#938)
* use openssl_x509_parse to parse certinfo (avoid literal case conflict)

* use OS specific ping (CLI/socket)

* Moved Windows and non-Windows check to a private class


Co-authored-by: TimZ99 <TimZ99@users.noreply.github.com>
2020-05-25 18:10:10 +02:00
Tim f02d55635e
Changed ping6 to ping -6 for windows (#936)
Resolving #935.
2020-05-25 14:39:30 +02:00
wienfuchs 07abc7d294
use OS specific ping count parameter (#932)
* use OS specific ping count parameter

* Reorganized and complied with PSR-12

Co-authored-by: TimZ99 <TimZ99@users.noreply.github.com>
2020-05-24 23:40:19 +02:00
wienfuchs 96d0c3fa57
use openssl_x509_parse to parse certinfo (avoid literal case conflict) (#931) 2020-05-24 23:31:19 +02:00
Tim ea33ba07ca
Updated ping check (#919)
Check if transmitted and received packets is equal.
2020-05-18 22:05:19 +02:00
Tim a19127721c
Display time in ms instead of seconds (#918) 2020-05-18 19:58:33 +02:00
Mateusz Małek 2fd9702485
Add ability to set custom site title (#922) 2020-05-18 19:45:44 +02:00
TimZ99 c0e0b260d5
Indent to space 2020-05-17 21:03:42 +02:00
wienfuchs 7bee25cc1e
Re-adding support PHP 5.5.9/7.0.x (#915)
Resolves #908.
2020-05-15 16:55:57 +02:00
TimZ99 76687d8c45
Bumped version to 3.5.0 2020-05-01 02:36:18 +02:00
Petr Suchy af5334a073
Jabber (XMPP) notifications (#852)
Added Jabber/XMPP notifications.
Closes #829.
2020-04-19 15:31:40 +02:00
Flávio Gomes da Silva Lisboa b346cd9c4d
Fixed fail to ping IPv6 #879 (#880)
Fixes #879.
2020-04-19 14:41:29 +02:00
Petr Suchy 3193665ef8
Encrypt email_smtp_password (#854)
Fixes #853.
Email_smtp_password is saved encrypted and not as plain text.


Co-authored-by: Tim <TimZ99@users.noreply.github.com>
2020-02-09 17:45:08 +01:00
TimZ99 ed6ef89df5
Hotfix - sslCheck warning days
Minimum amount of days the ssl cert needs to be valid before expiration wasn't used.
2020-02-09 15:16:23 +01:00
TimZ99 7ffc75598a
Refactor 2020-02-09 15:10:07 +01:00
Ing. Petr Suchy 5934e9a25c
*fix - checkSsl should check PHP_VERSION and not PHP_RELEASE_VERSION 2020-02-07 08:03:12 +01:00
Ing. Petr Suchy 8fa1bf6c0d
*edit - check ssl just when other error is not already in 2020-02-07 07:59:50 +01:00
Tim 45d1c03e5a
Feature/ssl cert expiration check (#831)
Added ssl expiration to warning state.
2020-02-04 16:44:48 +01:00
Petr Suchy 442f9d115e
Added Separate check when server is down (#844)
Future request - separate checks when down.
Closes #755.
2020-02-04 16:41:34 +01:00
TimZ99 0550ff7dcf
Added ping error 2020-01-15 10:33:47 +01:00
TimZ99 6ba4b59239
Changed ping from socket to exec function
As there are a lot of problems with permissions and ping, the function now uses exec(). Resolved #405, #576, #614, #748.

Co-Authored-By: Sean Perryman <se@nperryman.com>
Co-Authored-By: Luke C <crawford.luke@outlook.com>
2020-01-14 20:12:40 +01:00
TimZ99 a9f0f64c78
Public server page 2019-12-13 14:13:04 +01:00
Tim 07243f4cb5
Merge branch 'develop' into patch-1 2019-12-12 18:32:29 +01:00
TimZ99 97f8a6d637
Refactor
Removed unreachable code

Removed useless method overriding
2019-12-12 17:52:36 +01:00
Jeremy GHYS b7426291f8
Fix Server Downtime is displayed incorrectly
Server Downtime is displayed in correctly when receiveing e-mails about it.
2019-12-12 17:26:42 +01:00
TimZ99 2c51ad12f7
Implementing the PSR12 standard
Using PHPCS and PHPSBF.
2019-12-11 21:27:04 +01:00
TimZ99 7f5e698752
Fixed #811 DB wrong field type on fresh install.
Added the first part with #770. Forgot to  add it to the fresh install function.

Also removed the default value for TEXT as TEXT can't have a default value.

Co-Authored-By: Matěj Kmínek <matej.kminek@attendees.eu>
2019-12-10 19:43:42 +01:00
TimZ99 420211f61f
Fixed #816 url validation 2019-12-10 18:09:56 +01:00
ICTman1076 93ceb42a10 Hopefully fix #704 (#791)
* Fix #704 - use regex instead of PHP's own function

* Updated .ltd length to 12

For domains like .company .services .business.
2019-11-29 23:44:26 +01:00
TimZ99 0198d76a75
Added default timeout
Fixes #794.
2019-10-09 22:03:53 +02:00
TimZ99 a8eaedc817
Fixed undefined index
Fixes #787.
2019-09-30 17:50:20 +02:00
TimZ99 b399327c4b
Fixed week/month/year graph
Fixes #774.
2019-09-25 23:40:06 +02:00
TimZ99 4ebe934b2e
Added timeout to services
Fixes #775.
2019-09-25 23:35:37 +02:00
TimZ99 1b0d86b361
Corrected query
Fixes #781.
2019-09-24 18:23:57 +02:00
Arkhee dd3bc35009
"Last online" stuck on "never" when checking some websites (#770)
Fixes #765

* // PATCH Arkhee : fix/last-online-stuck-on-never-if-webpage-too-large
  // The update un "servers" table does not work
  // Symptom : "Last online" stays stuck on "never"
  // Reason: last_output contains the full webpage, too long for the query
  // _This may depend on mysql configuration on the server_, explaining why some have the problem or not
  // Field is 255 Chars, and request does not work anyway is loaded web page is too large in last_output
  // So force truncate to 250 or less before query

* Spelling

* Update varchar to text

* Update tot 3.4.1

* Update tot 3.4.1

* Update README.rst

* Updated to 5000 characters
2019-09-17 19:20:41 +02:00
Michael 6761776a8f
Allow HTTP/2 status responses (#695)
Fixed #672 and resolved #669.
2019-05-19 03:14:26 +02:00
TimZ99 32c17f372b
Added uptime and avg latency 2019-05-19 02:01:27 +02:00
TimZ99 b3de673c6a
Removed old todo's 2019-05-19 02:01:27 +02:00