openT2T / translators

Repository for Open Translators to Things.
http://www.opentranslatorstothings.org
Other
29 stars 27 forks source link

Making Wink notification verification more robust. #166

Closed danielrischar closed 7 years ago

danielrischar commented 7 years ago

I'm trying to create a decent workflow for e2e testing of the wink subscription notifications. In doing so I've run into a couple issue that can occur depending on server configuration/software for the callback end-point.

Fixes a potential issue with Wink notification verification caused by the payload contents being a string/object or vice versa. (#165)

Fixes a potential issue with reading HTTP headers as they are case-insensitive while their JSON representation is case-sensitive.

Adds HMACs to the error string for verification failure, useful for debugging purposes.

danielrischar commented 7 years ago

FYI, these scenarios are unit-testable so those are incoming.

arjun-msft commented 7 years ago

:shipit: