Page 10 of 14

Re: Nest Thermostat plug-in

Posted: Wed Apr 02, 2014 1:58 pm
by abuttino
At 9:54 am, I ran this:

09:54:30 Python Script
09:54:30 2014-04-02 09:54:19.511000

It's been connected for about 2 days with no interaction, like me restarting the plugin or eventghost.

It seems to have been a hiccup on my end

EDIT: Had it happen again last night for some reason. At least it's kinda sparse.

Re: Nest Thermostat plug-in

Posted: Thu Apr 10, 2014 5:59 pm
by funat120mph
Dragon470 wrote: Help wanted:
* Humidistat functions are implemented but not tested as I don't have anyone to test for me.
* Secondary or Alternate heat sources are not implemented as I don't have anyone to test for me.
* If anyone has a multi nest configuration I would like to test this setup.
Hi Dragon, I have a multi nest config and would like to help out. I have the plugin working but only on one of the two thermostats. Everything works but I only see nest updates in my office nest and not my home nest. This is a two location setup each location has one nest. I have another account with a single location with two nests. In each situation I only receive nest updates from one of the two thermostats. How do you select which thermostat has priority?

Re: Nest Thermostat plug-in

Posted: Sat Apr 12, 2014 3:25 pm
by abuttino
Just a report....

The newest plugin with weather stopped working. However, the older plugin still works.

Is this just me?

Re: Nest Thermostat plug-in

Posted: Sat Apr 12, 2014 6:20 pm
by Dragon470
I do have periods that the plugin doesn't/won't connect to nest. I usually just disable the plugin and then enable it in about an hour. I am trying to work out why this happens. I have checked with pinging the specified nest server when I can not connect and it works every time. I don't know if there is a maintenance time period or what.

Well I do have the newest version running fine. I do have a few extra connection checkers in mine for logging only though.

I do look forward to being able to redo the plugin for better multi-nest setups when I hear back from funat120mph.

Re: Nest Thermostat plug-in

Posted: Sun Apr 20, 2014 10:42 pm
by abuttino
I'm having a lot of login failures lately.

Code: Select all

14:32:00   ---> Welcome to EventGhost <---
14:32:05   Nest: Unable to retrieve data
14:32:05   ************Nest*****************
14:32:05   *
14:32:05   *
14:32:05   *
14:32:05   Initial Retrieval or Login failed
14:32:05   Terminating plugin
14:32:05   Restart plugin to regain functionality
14:32:05   Nest.InitialError

and this with the weather enabled plugin:

Code: Select all

14:07:19   Failed to Login to Nest
14:07:19   Nest.LoginError
14:07:20   Failed to Login to Nest
14:07:20   Nest.LoginError
Have not been able to get online with the thermostat since wed.

Waited hours at a time, still nothing.

Any assistance would be greatly appreciated.

Re: Nest Thermostat plug-in

Posted: Sun Apr 20, 2014 11:22 pm
by Dragon470
I already know and will have a Alpha out in just a little bit. The Alpha has the older login that has proven to be more reliable for me. The rest of the Alpha build has a redesigned muti-structure/thermostat support. I hope funat120mph can test if fully.

Re: Nest Thermostat plug-in

Posted: Mon Apr 21, 2014 1:44 pm
by funat120mph
I've installed the Alpha plugin. It looks like both locations and t-stats are being read by the plugin. I don't see where there is any differentiation for which nest is sending the data. For example, I changed the temp for one stat to 70 and another to 80.

The log shows this.

Code: Select all

Nest.target_temperature ['', '70.0007']
and this.

Code: Select all

Nest.target_temperature ['', '79.9992']
I also don't see the away status in the logs like it showed before.

Re: Nest Thermostat plug-in

Posted: Mon Apr 21, 2014 3:29 pm
by abuttino
This worked for about an hour then stopped..

Code: Select all

11:28:05   Nest: Login to Nest sucessful
11:28:05   Nest: Unable to retrieve data
11:28:05   ************Nest*****************
11:28:05   *
11:28:05   *
11:28:05   *
11:28:05   Initial Retrieval or Login failed
11:28:05   Terminating plugin
11:28:05   Restart plugin to regain functionality
11:28:05   Nest.InitialError
11:28:06   Nest: Login to Nest sucessful
11:28:07   Nest: Unable to retrieve data
11:28:07   ************Nest*****************

Re: Nest Thermostat plug-in

Posted: Mon Apr 21, 2014 4:30 pm
by funat120mph
I am still connected to nest. About three hours now.

Re: Nest Thermostat plug-in

Posted: Mon Apr 21, 2014 5:17 pm
by atmarosi
Just loaded up the latest and greatest from the first post (Nest plugin dated 4-20-2014) here is my output:
10:15:03 Plugin: Nest Thermostat
10:15:04 Nest: Login to Nest sucessful
10:15:04 Nest: Unable to retrieve data
10:15:04 ************Nest*****************
10:15:04 *
10:15:04 *
10:15:04 *
10:15:04 Initial Retrieval or Login failed
10:15:04 Terminating plugin
10:15:04 Restart plugin to regain functionality

Re: Nest Thermostat plug-in

Posted: Mon Apr 21, 2014 7:05 pm
by abuttino
This seems to be a very weird issue, only haunting certain accounts..

Cannot figure out the logic behind this at all.

Re: Nest Thermostat plug-in

Posted: Mon Apr 21, 2014 8:39 pm
by abuttino
Ok, I did my own spoof of the headers on firefox and got a ton of info with

"https://transport02-rts03-iad01.transpo ... r.myuserid"

All of the info I got was accurate.

Code: Select all

{"user_alert_dialog":{"XXXXXXXXXXX":{"$version":1376320037,"$timestamp":1371680607000,"dialog_data":"","dialog_id":"confirm-pairing"}},"track":{"XXXXXXXXXXXX":{"$version":502088205,"$timestamp":1398111431551,"online":true,"last_connection":1398111431551,"last_ip":"XXXXXXXXXXX"}},"message_center":{"XXXXXXXXXXX":{"$version":-395439623,"$timestamp":1397650405915,"messages":[{"id":"da9c3c50-c529-11e3-b60c-12313920a13b","key":"air_filter_reminder","priority":2,"timestamp":1397626930,"thread_id":0,"read":true,"dismissed":true,"parameters":["XXXXXXXXXXXXXXXXX","Home","Home","00000000-0000-0000-0000-000100000002","Hallway"]}]}},"utility":{"0c84b210-d773-11e2-9a67-12313b0cf507":{"$version":-1,"$timestamp":1}},"where":{"0c84b210-d773-11e2-9a67-12313b0cf507":{"$version":1512325367,"$timestamp":1383033321066,"wheres":[{"where_id":"00000000-0000-0000-0000-000100000001","name":"Basement"},{"where_id":"00000000-0000-0000-0000-00010000000d","name":"Bedroom"},{"where_id":"00000000-0000-0000-0000-000100000003","name":"Den"},{"where_id":"00000000-0000-0000-0000-000100000010","name":"Dining Room"},{"where_id":"00000000-0000-0000-0000-000100000006","name":"Downstairs"},{"where_id":"00000000-0000-0000-0000-000100000000","name":"Entryway"},{"where_id":"00000000-0000-0000-0000-00010000000b","name":"Family Room"},{"where_id":"00000000-0000-0000-0000-000100000002","name":"Hallway"},{"where_id":"00000000-0000-0000-0000-000100000008","name":"Kids Room"},{"where_id":"00000000-0000-0000-0000-00010000000a","name":"Kitchen"},{"where_id":"00000000-0000-0000-0000-00010000000c","name":"Living Room"},{"where_id":"00000000-0000-0000-0000-000100000005","name":"Master Bedroom"},{"where_id":"00000000-0000-0000-0000-00010000000e","name":"Office"},{"where_id":"00000000-0000-0000-0000-00010000000f","name":"Upstairs"}]}},"structure":{"0c84b210-d773-11e2-9a67-12313b0cf507":{"$version":-1092709595,"$timestamp":1398106678719,"away":false,"away_setter":0,"away_timestamp":1.39804410057E9,"country_code":"US","dr_reminder_enabled":true,"house_type":"family","hvac_safety_shutoff_enabled":true,"location":"Tampa, FL","measurement_scale":"imperial","name":"Home","num_thermostats":"1","postal_code":"XXXXX","renovation_date":"1950","street_address":"XXXXXXXXXXX","structure_area":74.322,"topaz_enhanced_auto_away_enabled":false,"touched_by":{},"user":"user.3XXXXXXXXXXXXXX","devices":["device.XXXXXXXXXXXXX"],"swarm":["device.XXXXXXXXXXXXXXX"],"fabric_ids":[]}},"message":{"XXXXXXXXXXXXXXXXX":{"$version":-1094642415,"$timestamp":1371680622000}},"tuneups":{"XXXXXXXXXXXXXXXX":{"$version":-1,"$timestamp":1}},"device":{"XXXXXXXXXXXXX":{"$version":-246269514,"$timestamp":1398110908239,"heatpump_setback_active":false,"touched_by":{},"emer_heat_enable":false,"switch_system_off":false,"local_ip":"10.0.0.107","away_temperature_high":27.8,"y2_type":"unknown","temperature_lock_high_temp":22.222,"cooling_source":"electric","leaf_threshold_cool":25.11,"note_codes":[],"fan_cooling_state":false,"heater_source":"electric","compressor_lockout_leaf":-17.8,"has_x3_heat":false,"target_humidity_enabled":false,"heat_x3_source":"electric","alt_heat_delivery":"forced-air","fan_mode":"auto","has_x2_heat":false,"sunlight_correction_active":false,"rssi":63.0,"emer_heat_delivery":"forced-air","pin_y2_description":"none","heatpump_savings":"off","humidity_control_lockout_end_time":0,"filter_reminder_level":0,"filter_reminder_enabled":true,"capability_level":4.0,"schedule_learning_reset":false,"has_x2_cool":false,"ob_orientation":"O","hvac_pins":"W1,Y1,C,Rh,G","cooling_delivery":"unknown","range_enable":true,"dual_fuel_breakpoint_override":"none","auto_away_enable":false,"lower_safety_temp_enabled":true,"has_fan":true,"dehumidifier_state":false,"nlclient_state":"","emer_heat_source":"electric","heatpump_ready":false,"cooling_x2_delivery":"unknown","available_locales":"en_US,fr_CA,es_US","current_version":"4.0.3","learning_state":"initial","has_fossil_fuel":false,"pin_rh_description":"power","pin_ob_description":"none","safety_temp_activating_hvac":false,"has_alt_heat":false,"fan_duty_cycle":3600,"pin_y1_description":"cool","humidifier_state":false,"gear_threshold_high":0.0,"backplate_serial_number":"01BA02AB111205NS","has_x2_alt_heat":false,"leaf_threshold_heat":1000.0,"heat_x3_delivery":"forced-air","learning_mode":false,"has_emer_heat":false,"leaf_learning":"ready","has_aux_heat":false,"aux_heat_source":"electric","filter_changed_set_date":1397668871,"backplate_bsl_info":"BSL","sunlight_correction_ready":true,"alt_heat_x2_source":"gas","pin_c_description":"power","humidifier_type":"unknown","pin_w2aux_description":"none","humidity_control_lockout_start_time":0,"sunlight_correction_enabled":true,"country_code":"US","fan_timer_timeout":0,"target_humidity":35.0,"heat_x2_delivery":"forced-air","gear_threshold_low":0.0,"lower_safety_temp":7.222,"cooling_x2_source":"electric","equipment_type":"electric","heat_pump_aux_threshold":10.0,"alt_heat_x2_delivery":"forced-air","heat_pump_comp_threshold":-31.5,"learning_days_completed_cool":2,"backplate_bsl_version":"1.1","current_schedule_mode":"COOL","hvac_wires":"Heat,Cool,Fan,Common Wire,Rh","fan_duty_end_time":0,"leaf":true,"type":"TBD","pin_g_description":"fan","click_sound":"on","aux_heat_delivery":"forced-air","away_temperature_low_enabled":true,"filter_changed_date":1397520000,"hvac_safety_shutoff_active":false,"heat_pump_comp_threshold_enabled":false,"preconditioning_ready":true,"has_dehumidifier":false,"fan_cooling_enabled":true,"leaf_away_high":28.88,"fan_cooling_readiness":"ready","temperature_scale":"F","device_locale":"en_US","preconditioning_active":false,"maint_band_upper":0.56,"error_code":"","battery_level":3.897,"fan_control_state":false,"away_temperature_high_enabled":true,"learning_days_completed_heat":0,"upper_safety_temp_enabled":true,"pin_star_description":"none","preconditioning_enabled":false,"dual_fuel_breakpoint":-1.0,"current_humidity":50,"postal_code":"33616","alt_heat_source":"gas","backplate_mono_version":"4.0.19","aux_lockout_leaf":10.0,"has_heat_pump":false,"heater_delivery":"forced-air","radiant_control_enabled":false,"auto_away_reset":false,"away_temperature_low":10.0,"temperature_lock":false,"has_air_filter":true,"upper_safety_temp":35.03,"time_to_target_training":"ready","dehumidifier_type":"unknown","humidity_control_lockout_enabled":false,"target_time_confidence":1.0,"fan_timer_duration":7200,"where_id":"00000000-0000-0000-0000-000100000002","temperature_lock_low_temp":20.0,"pin_w1_description":"heat","forced_air":true,"temperature_lock_pin_hash":"","auto_dehum_enabled":false,"leaf_type":1,"backplate_mono_info":"TFE (BP_DVT) 4.0.19 (root@bamboo) 2014-01-26 08:00:02","star_type":"unknown","has_dual_fuel":false,"maint_band_lower":0.56,"learning_time":3470,"creation_time":1337649231703,"has_humidifier":false,"learning_days_completed_range":0,"dehumidifier_orientation_selected":"unknown","leaf_schedule_delta":1.11,"logging_priority":"informational","user_brightness":"low","leaf_away_low":16.67,"pin_rc_description":"none","serial_number":"XXXXXXXXXXXX","auto_dehum_state":false,"mac_address":"18b43004c974","heat_x2_source":"electric","fan_duty_start_time":0,"time_to_target":0,"backplate_model":"Backplate-1.9a","model_version":"Diamond-1.12","heat_pump_aux_threshold_enabled":true,"ob_persistence":true}},"demand_response":{"XXXXXXXXXXXXXXXX":{"$version":-1,"$timestamp":1}},"user":{"XXXXXXXXXXXX":{"$version":1808534678,"$timestamp":1371682679000,"name":"XXXXXXX","structures":["structure.0c84b210-d773-11e2-9a67-12313b0cf507"]}},"link":{"XXXXXXXXXXXXX":{"$version":-1686825501,"$timestamp":1371680607000,"structure":"structure.0c84b210-d773-11e2-9a67-12313b0cf507"}},"device_alert_dialog":{"XXXXXXXXXXXXX":{"$version":1067191184,"$timestamp":1371680607000,"dialog_data":"","dialog_id":"confirm-pairing"}},"metadata":{"XXXXXXXXXXXXXXX":{"$version":-1,"$timestamp":1356998400000,"last_ip":"127.0.0.1","last_connection":1356998400000}},"user_settings":{"355866":{"$version":1078727904,"$timestamp":1386431444846,"email_verified":true,"tos_accepted_version":1381190400000,"receive_marketing_emails":true,"receive_nest_emails":true,"receive_support_emails":true,"max_structures":2,"max_thermostats":10,"max_thermostats_per_structure":10,"max_smoke_detectors_per_structure":18,"max_smoke_detectors":36,"tos_minimum_version":1381190400000,"tos_current_version":1381190400000,"lang":"en_US"}},"shared":{"XXXXXXXXXXXXXX":{"$version":840880350,"$timestamp":1398111431550,"touched_by":{},"auto_away":-1,"auto_away_learning":"training","hvac_heat_x3_state":false,"compressor_lockout_enabled":false,"hvac_alt_heat_state":false,"target_temperature_type":"cool","hvac_heater_state":false,"hvac_emer_heat_state":false,"can_heat":true,"compressor_lockout_timeout":0,"hvac_cool_x2_state":false,"target_temperature_high":24.0,"hvac_aux_heater_state":false,"hvac_heat_x2_state":false,"target_temperature_low":20.0,"target_temperature":25,"hvac_ac_state":false,"hvac_fan_state":false,"target_change_pending":false,"name":"Home","current_temperature":25.06,"hvac_alt_heat_x2_state":false,"can_cool":true}},"schedule":{"XXXXXXXXXXXXXXXXX":{"$version":1855558792,"$timestamp":1398106677444,"days":{"3":{"0":{"touched_by":1,"time":0,"touched_tzo":-14400,"entry_type":"continuation","temp":24.0,"type":"COOL","touched_at":1398106670}},"2":{"0":{"touched_by":1,"time":0,"touched_tzo":-14400,"entry_type":"continuation","temp":24.0,"type":"COOL","touched_at":1398106670}},"1":{"0":{"touched_by":1,"time":0,"touched_tzo":-14400,"entry_type":"continuation","temp":24.0,"type":"COOL","touched_at":1398106670}},"0":{"0":{"touched_by":1,"time":0,"touched_tzo":-14400,"entry_type":"continuation","temp":24.0,"type":"COOL","touched_at":1398106670}},"6":{"0":{"touched_by":1,"time":0,"touched_tzo":-14400,"entry_type":"continuation","temp":24.0,"type":"COOL","touched_at":1398106670}},"5":{"0":{"touched_by":1,"time":0,"touched_tzo":-14400,"entry_type":"continuation","temp":24.0,"type":"COOL","touched_at":1398106670}},"4":{"0":{"touched_by":1,"time":0,"touched_tzo":-14400,"entry_type":"continuation","temp":24.0,"type":"COOL","touched_at":1398106670}}},"name":"Home Current Schedule","schedule_mode":"COOL","ver":2}}}

Re: Nest Thermostat plug-in

Posted: Tue Apr 22, 2014 12:39 am
by Dragon470
I really don't understand the loss of connection again. I can login, but not get status information. I am getting the all the initial login info. In my testing I am getting error:

SSLError: [Errno 1] _ssl.c:480: error:0D0C50A1:asn1 encoding routines:ASN1_item_verify:unknown message digest algorithm

from the get_status function.

Any of my google searches yield stuff about openssl implementations. I do not even know if eventghost is using a form of openssl. If I try:

Code: Select all

import ssl

print ssl.OPENSSL_VERSION
I get error consistent with a custom ssl implementation not openssl. I would like to know what ssl implementation eventghost does use. I would take an suggestion on how to proceed.

As a side note. All 3 IE, Firefox and Chrome all connect just fine. To me this indicates either a new security procedure or something wrong with the ssl within eventghost.


As far as the missing information from the events, that appears to me that you don't have names set to your thermostats. You can check in the get_object action. I have names for both the thermostats and a name for my structure. This can be done on the website or possibly on the thermostat directly.

It seams this was an oversight by me. Maybe I should add in the structure id and serial number for those who don't have the names entered.

Re: Nest Thermostat plug-in

Posted: Tue Apr 22, 2014 1:18 am
by abuttino
I'm doing some research, I'll let you know what I come up with..

I also got the login data from doing a "print res" in the login def.

Re: Nest Thermostat plug-in

Posted: Tue Apr 22, 2014 2:42 am
by abuttino
What I have found out by a security programmer..

They most likely changed the cypher suite. My guess is that they did this in response to HeartBleed, but is still quite annoying..

I am trying to figure this out but what we need to do is use DHE_RSA for exchange. I'll look in the requests folder/the site it came from; for anything that would give a clue to changing the cypher suite.

The new cypher suite can be found on the browser lock or:
"TLS 1.0, AES_128_CBC With sha1 message auth and DHE_RSA for key exchange"

If in fact that SSL is broken all around, would you consider PycURL

EDIT1:After Googling till my eyes are bleeding, this is about the best I can find:
https://gist.github.com/tomstrummer/6510373

EDIT2:There is a pyopenssl.py in the requests/packages/urllib3/contrib folder.
The Nest transport server uses:
TLS_RSA_WITH_AES_128_CBC_SHA (0x2f) 128
TLS_DHE_RSA_WITH_AES_128_CBC_SHA (0x33) DH 768 bits (p: 96, g: 96, Ys: 96) FS WEAK 128
TLS_RSA_WITH_3DES_EDE_CBC_SHA (0xa) 112
TLS_DHE_RSA_WITH_3DES_EDE_CBC_SHA (0x16) DH 768 bits (p: 96, g: 96, Ys: 96) FS WEAK 112

One of which, there is a cipher suite in that library.

EDIT3: Trying to import pyopenssl from packages.urllib3.contrib gives me TONS of error about modules not being installed.. So what I did was to go to the pyopenssl site and download a version capable of using the EG's version of python.. Then I extracted that OPENSSL directory from my python folder and placed it in the main EG folder. Then I was able to use from OPENssl import SSL"

Although I'm unsure of the use to this project, I figure it's better than nothing.

This thread also came up when doing searches.
https://stackoverflow.com/questions/185 ... 4#18579484
The AN1 problem was described in that thread to some extent.