nirnachmani / Pixie-Plus-for-Home-Assistant

a Pixie Plus integration for Home Assistant
Apache License 2.0
9 stars 3 forks source link

Unable to find ApplicationID, InstallationID and JavaScriptKey #9

Open nickw444 opened 2 months ago

nickw444 commented 2 months ago

Despite following the instructions closely and using various MITM apps with HTTPS functionality on iOS as well as mitmproxy with an Android emulator, I have been unable to fetch the desired secrets needed to make this integration work.

Perhaps PIXIE have changed their communication method to something else that isn't done via HTTP(s)? (Or I'm doing something wrong).

Ultimately I'm not too interested in a cloud integration, but rather mostly interested in local integration. I've previously reversed engineered binary protocols, so would be willing to give this a try. I'd love to know how you went about capturing the TCP messages between the app and hub? (and whether you had a pcap you'd be willing to share). Otherwise I'll try capture myself.

nirnachmani commented 2 months ago

They have changed it - those keys are now in the HTTPS headers, not in the content. Also JavaScriptKey is now called clientkey. I thought I changed the readme in the github repository to reflect those changes but looking at it now, it doesn't - I must have changed it somewhere else. Sorry.

I have spent many hours in an attempt to implement local control. I used WireGuard on an android device and mitmproxy in wiregaurd mode to see the local TCP communication between the app and the hub. This communication is encrypted so I started to reverse engineer the android app to find out what encryption method is used, which I think I managed to do. However, the decrypted data still didn't make much sense, and eventually I just gave up. I can't remember now why, but the wiregurad didn't work on a virtual device so I needed to use an old physical device which I rooted. I am happy to give some more advise but I don't think I want to spend more time on that project - while I would prefer local control, the current implementation works quite well so it is good enough for me.

zhoob commented 2 months ago

Despite following the instructions closely and using various MITM apps with HTTPS functionality on iOS as well as mitmproxy with an Android emulator, I have been unable to fetch the desired secrets needed to make this integration work.

Perhaps PIXIE have changed their communication method to something else that isn't done via HTTP(s)? (Or I'm doing something wrong).

Ultimately I'm not too interested in a cloud integration, but rather mostly interested in local integration. I've previously reversed engineered binary protocols, so would be willing to give this a try. I'd love to know how you went about capturing the TCP messages between the app and hub? (and whether you had a pcap you'd be willing to share). Otherwise I'll try capture myself.

Nick I would be forever grateful if you could give it a crack and get local support going..

nickw444 commented 2 months ago

They have changed it - those keys are now in the HTTPS headers, not in the content. Also JavaScriptKey is now called clientkey. I thought I changed the readme in the github repository to reflect those changes but looking at it now, it doesn't - I must have changed it somewhere else. Sorry.

Which domains / URLs did you observe these tokens be exchanged? I'm looking through the dump I have captured on my end when authenticating within the app, the only domains it seems to contact are:

Should I be seeing more domains/URLs here?

nickw444 commented 2 months ago

Separate to this, I've added a comment on the PIXIE support page to encourage SAL to implement a public API.

nirnachmani commented 2 months ago

You should see communication with https://www.pixie.app.

hoskerism commented 3 weeks ago

Looking at the Pixie support page posted by nickw444. It has now been replaced with a page that simply says 'there is no API'. All comments have been removed.

Does this mean that the Pixie API is officially dead?

nickw444 commented 3 weeks ago

Wow that's really not good to see 😢