iobroker-community-adapters / ioBroker.unifi-protect

Unifi Protect Adapter for ioBroker
MIT License
22 stars 8 forks source link

Login fails after update to current beta Unifi-OS 3.2.5 or 3.2.6 on UDMP #189

Open pfanntec opened 8 months ago

pfanntec commented 8 months ago

Describe the bug
Ubiquiti must have changed something on the login. The adapter turns green but only error messages are displayed in the log. The login fails.

To Reproduce

  1. update Unifi-OS to 3.2.5 or 3.2.6
  2. login fails

Screenshots & Logfiles

2023-10-23 20:17:44.074 - info: host.Server instance system.adapter.unifi-protect.0 started with pid 299504 2023-10-23 20:17:45.023 - error: unifi-protect.0 (299504) getApiAuthBearerToken: Unifi Protect reported authorization failure 2023-10-23 20:17:45.024 - error: unifi-protect.0 (299504) Couldn't login. 2023-10-23 20:17:45.034 - error: unifi-protect.0 (299504) getCameraList: Unifi Protect reported authorization failure 2023-10-23 20:17:45.046 - error: unifi-protect.0 (299504) getApiAuthBearerToken: Unifi Protect reported authorization failure 2023-10-23 20:17:45.046 - error: unifi-protect.0 (299504) Couldn't login. 2023-10-23 20:17:45.537 - error: unifi-protect.0 (299504) getMotionEvents: Unifi Protect reported authorization failure 2023-10-23 20:17:45.552 - error: unifi-protect.0 (299504) getApiAuthBearerToken: Unifi Protect reported authorization failure 2023-10-23 20:17:45.552 - error: unifi-protect.0 (299504) Couldn't login.

Versions:

777Timo commented 8 months ago

Hello, same here with Unify NVR and Protect 2.9.30 and OS 3.2.5

unifi-protect.0 | 2023-10-25 13:38:30.038 | error | Couldn't login. unifi-protect.0 | 2023-10-25 13:38:30.038 | error | getApiAuthBearerToken: Unifi Protect reported authorization failure unifi-protect.0 | 2023-10-25 13:38:30.029 | error | getMotionEvents: Unifi Protect reported authorization failure

adapter is green and the log shows error objects did not get updates.

ChrMaass commented 8 months ago

Unfortunately, I have the same error. I can no longer connect to the Homebridge Unifi Protect plugin either. I hope we can identify the problem quickly.

pfanntec commented 8 months ago

It looks like unifi-os has stopped sending x-csrf-token headers since version 3.2.X. https://github.com/Art-of-WiFi/UniFi-API-client/issues/202#issuecomment-1803669407

Maybe the maintainer @peterbaumert can fix this before UI release a 3.2.x version as official.

Stroell commented 7 months ago

The issue has been fixed in the Unifi Network Adapter: https://github.com/iobroker-community-adapters/ioBroker.unifi/issues/723

Would be great if the issue could get fixed in this Adapter as well ❤️ The new Unifi OS is already in RC and will be released soon

Bart1909 commented 6 months ago

Opened #199