If anyone is still using this (I am - in conjunction with around 30 Hue lights), I have a working local device handler. However, I wasn’t able to invoke physicalgraph.device.HubAction directly to the hub (it’s cert isn’t valid), so I’ve written a proxy web service to translate the traffic to non-SSL.
Anyone out there found a better way? It works perfectly - all local. But, it does require a local host for the proxy service, which I don’t like.
I wrote TCP support to see if there is a possibility to rollback to local processing (as it was when I bought it) so that we can have the integration with ST. I would encourage all to do the same and maybe we can get create some pressure at TCP.
I would like to try this out when I get some time - I also have several TCP bulbs and want them working in SmartThings again! For now I just use the scheduler via the TCP app on my phone to control them.
In seeing how Wink use to support local control, there was a point where the Wink setup process wanted me to push the button on the TCP hub to allow full local control. At the time I didn’t get that part working, so Wink was using the TCP control over the web. Now it doesn’t work via Wink, but could we use something like that for local control via ST?
I know that ST doesn’t support https traffic for local control, but does pushing the button on the TCP hub to authenticate with other devices alter this any?
A user recently posted a copy of the old firmware and downgrade/restore instructions on github.
WARNING: this is not for the faint of heart/technically challenged. The brief steps are: run an SSL webserver, redirect the requests for some greenwavereality.com domains to your webserver, serve the old firmware.
I was able to use this to de-brick a hub that I brought online a few weeks ago for the first time since before the firmware fiasco.
I now successfully have a restored hub and my lights are all working again. Investment recouped. Getting it integrated with ST… is the next challenge.
Looking now for a local integration for the old-style firmware, but would be interested/willing to upgrade/run a local proxy if it means smoother/more reliable integration.
Also, not sure how much effort has been put into it, but in poking around on the firmware for -the tcp device- it seems to be a Jennic 5618 zigbee radio, so it shouldnt be too unpossible to figure out how to speak directly with these units now that we have access to the device…
studio:~ adam$ ssh root@tcp-hub The authenticity of host 'tcp-hub (192.168.1.7)' can't be established. ECDSA key fingerprint is SHA256:DDPLwW889ZCIzPdc/iOl2m/ZqjsJdFl5riEbc9uPHcI. Are you sure you want to continue connecting (yes/no)? yes Warning: Permanently added 'tcp-hub,192.168.1.7' (ECDSA) to the list of known hosts. root@tcp-hub's password: ~ # pwd /root ~ # uname -a Linux lighting 3.5.3 #1 PREEMPT Tue Dec 3 10:44:29 CET 2013 ppc GNU/Linux ~ # date Wed Dec 31 16:31:28 PST 1969 ~ # Connection to tcp-hub closed. studio:~ adam$ date Mon Aug 8 23:30:44 PDT 2016 studio:~ adam$
@dev_sec Is there somewhere we can find the code for your local device handler? I now have my devices running successfully locally on the legacy firmware without SSL, so with some minor tweaks I should be able to make a seamless integration without a proxy (for my specific use-case)
BTW someone on the Vera forums has a fully working implementation of control via php. I’m running this on my synology NAS and I can view / control all of my TCP bulbs via a web page either local or remotely.
I tried the node.js implementation on the NAS but couldn’t get it to work, but this version appears to work flawlessly.
It’s not a real solution to the ST integration, but at least you can control your bulbs remotely again, and with enough effort I’m sure someone can finagle a solution even if it’s using this as a proxy.
I would also like LAN interaction with the Hub. SmartThings refusing to allow us to connect to a self signed cert is nuts. If only they allowed us the option to accept any cert then this wouldn’t be too hard to fix. Instead they cut off support
I didn’t want to run anything at my house 24/7 so to get around ST’s security I gave my TCP Connected hub a fixed IP, forwarded the port through my router for HTTPS access. Then I configured a THINGHTTP to bounce between ST and my hub. I didn’t fully hash out the discovery that is implemented in the Connect app. I manually gave the smartapp my THINGHTTP details, and the secret/token from the hub using https://github.com/therivenman/pygop to get the token.
Altogether, I am not sure saving my sunk costs was worth it. However, so far it has been working for about a week.
With all due credit to those have figured things out before, here is a bash script for any who may find it useful. The username and password get you a token that will work for further calls but need not be your real TCP/Greenwave credentials. Press the button on the unit, first. Given your TCP connected gateway IP, it will spit out a token and device IDs of your connected bulbs. In previous experimentation I have also proxied out certificate of the TCP gateway using HAProxy so that https is no longer needed. But as I’m new to ST, it does not yet buy me any advantage because I was already controlling locally (and remotely) via curl -k commands. But I would like to see better ST local integration. Controlling locally is also much quicker as others have pointed out.
Typical command to turn on a bulb (use value 0 for off):
token=n9xxxxxxxxxx----xxx—xx–x-x-x-1244 #replace with your own token
gatewayip=192.168.x.x #replace with your tcp connected gateway IP
bulbdid=219777xxxxxxxx #replace with your own DID curl -k "https://$gatewayip/gwr/gop.php?cmd=DeviceSendCommand&data=<gip><version>1</version><token>$token</token><did>$bulbdid</did><value>1</value></gip>&fmt=xml" > /dev/null 2>&1
There is a command for dimming also but I have not made use of it. Also, if there is is interest in my haproxy config, I will try and re-find it.
Hi, I’m trying to downgrade the gateway. but I have problems with certificate when run python https.py
it request me Enter PEM pass phrase:
Do You known what I need to enter?
If I enter any phrase or just enter I got the error
ssl.SSLError: [SSL] PEM lib (ssl.c:2718)