XyloSiteMonitor

Artifact Content
Login

Artifact 65b0e271315fe797e606d01aaf29e5d9cee6313714e2208b1129ff9d58c84ee6:

Wiki page [XyloSiteMonitor] by xylon 2018-11-03 22:01:57.
D 2018-11-03T22:01:57.182
L XyloSiteMonitor
P fd068bb5f3beab8a968de458472b09d0544cf68ea3bc5f21692feb9821ac1038
U xylon
W 5050
Websites to be tested are defined in a beautiful [https://en.wikipedia.org/wiki/YAML|YAML] format. XyloSiteMonitor reads these definitions and tests every combination of IPversion, TLS vs no-TLS and www vs no-www.

It produces a nice report and can be told to pass the report to a local mail-server.

Here's some example yaml, that tests Free Software UK:

<verbatim>
- name: Free Software UK
  expected string: Free Software UK
  canonical address: https://www.freesoftwareuk.org.uk/
  urls:
  - url: www.freesoftwareuk.org.uk
    tests:
    - action: return string
      protocols:
        - TLS
    - action: redirect
      protocols:
        - no-TLS
  - url: freesoftwareuk.org.uk
    tests:
    - action: redirect
      protocols:
        - TLS
        - no-TLS
</verbatim>

This translates into all 8 checks required and produces the following output:

<verbatim>
IPv4, does "www.freesoftwareuk.org.uk" return string over "TLS"?                                                                                                                                                   
 Test Success!                                                                                                                                                                                                     
IPv6, does "www.freesoftwareuk.org.uk" return string over "TLS"?                                                                                                                                                   
 Test Success!                                                                                                                                                                                                     
IPv4, does "www.freesoftwareuk.org.uk" redirect over "no-TLS"?                                                                                                                                                     
 Test Success!                                                                                                                                                                                                     
IPv6, does "www.freesoftwareuk.org.uk" redirect over "no-TLS"?                                                                                                                                                     
 Test Success!                                                                                                                                                                                                     
IPv4, does "freesoftwareuk.org.uk" redirect over "TLS"?                                                                                                                                                            
 Test Success!                                                                                                                                                                                                     
IPv6, does "freesoftwareuk.org.uk" redirect over "TLS"?                                                                                                                                                            
 Test Success!                                                                                                                                                                                                     
IPv4, does "freesoftwareuk.org.uk" redirect over "no-TLS"?                                                                                                                                                         
 Test Success!                                                                                                                                                                                                     
IPv6, does "freesoftwareuk.org.uk" redirect over "no-TLS"?                                                                                                                                                         
 Test Success!

Summary:                                                                                                                                                                                                           
8 tests passed                                                                                                                                             
0 tests failed
</verbatim>

To monitor all 10 of my websites like this requires 64 checks. To get this many checks with UptimeRobot would require a Pro plan and it wouldn't allow me to test IPv4 vs 6. To get this many checks with PingDom would require an "Advanced" plan for £48 GBP per month (ROFL).

If you don't like YAML this probably isn't for you because it's wholy based on YAML.

At this time it always tests both IPv4 and IPv6 and this cannot be changed.

To find out the options please run:

<verbatim>
./xylositemonitor.py --help
</verbatim>
Z af46f0c938b1b48415bc50272afb9e96