barcar / visonic_control

PHP scripts to arm, disarm and check status of Visonic PowerMaster 30 security alarm via web service connected to PowerLink 3
GNU General Public License v3.0
3 stars 3 forks source link

visonic_control

STOP: Visonic changed their API (to v8 according to https://visonic.tycomonitor.com/rest_api/version) so this approach no longer works. This project might be your best bet going forward: https://github.com/And3rsL/VisonicAlarm2. Their commits reference upgrading to API v8


This project consists of basic PHP scripts to arm, disarm and check status of a Visonic PowerMaster security alarm by emulating the Visonic Go app talking to the RESTful web service which is connected to a PowerLink 3 module in the alarm.

These scripts are quick and dirty - I'm sure somebody with better PHP skills can improve them but they get the job done. The workings of the web service were determined via the Charles Web Debugging Proxy monitoring the Visonic Go app.

Of course this is unsupported by Visonic - they don't publish their REST API. It is also unsupported by me. I accept no liability for your use of the scripts nor for any loss or damage resulting from security breaches at your property.

Of particular note is that all SSL checking is disabled when connecting to the Visonic service. This is clearly a VERY BAD IDEA. But it works.

pre-requisites

It goes without saying that anybody with access to the web server can arm and disarm your alarm so take a moment to think about that risk and make sure it is secured appropriately.

usage

docker run --rm -ti -p 8099:80 -e USER_CODE=XXXX -e PANEL_WEB_NAME=XXXXX -e HOST=XXXXX -e USER_ID=`uuidgen chrisns/visonic

Point your browser at one of the PHP files to activate the required function namely:

Where neccesary the PHP script will call the login or status scripts to achieve the required function.

further enhancements

Use Home Assistant (https://home-assistant.io) to create a Command Line Switch which you can then control with Amazon Echo (Alexa) or via HomeBridge (https://github.com/nfarina/homebridge) with Apple Siri. So you can say "Turn on burglar alarm" to arm your system via Alexa.

You might like to configure Home Assistant Command Line Switch to only allow Alexa to arm the system so that strangers can't walk into your home and tell Alexa to disarm it.

You could probably do something similar with FauxMo (https://github.com/makermusings/fauxmo) which is a fake WeMo switch. I haven't tried that but can't see why it wouldn't work.

behind the scenes