"invalid authentication" when adding Google Assistant integration

Hello! I’m trying to manually expose my HA devices to Google Home/Assistant, following the instructions on the Google Assistant integration’s documentation page. Everything goes perfectly until I try to add my [test] project in the Google Home app. It opens up my HA login page with the message “You’re about to give https ://oauth-redirect. google … access to your Home Assistant instance. Logging in with Home Assistant Local.”

Trying to log in on this page results in an “Invalid username or password” message, along with a notification in HA saying “Login attempt or request with invalid authentication from [IP]”. In the logs, this is recorded as:

Logger: homeassistant.components.http.ban
Source: components/http/ban.py:80
Integration: HTTP (documentation, issues)
First occurred: 8:58:04 PM (2 occurrences)
Last logged: 10:44:49 PM

Login attempt or request with invalid authentication from [IP]. Requested URL: '/auth/login_flow/...'. (Mozilla/5.0 (iPhone; CPU iPhone OS 17_0 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.0 Mobile/15E148 Safari/604.1)

I’m wondering if something is wrong with my encryption/SSL setup. I have Duck DNS and NGINX Home Assistant SSL Proxy add-ons set up and working. The message “Logging in with Home Assistant Local” makes me wonder if it’s trying to log in as a local user, but I’ve tried doing this both on my local network and on my cellular data, with the same results. Would appreciate any help!

1 Like

Okay, figured it out. For anyone who has the same problem in the future: The problem is specific to the iOS version of Google Home. The login page for the HA instance runs on Safari, and there’s a bug in Safari where it will not send out your password if you autofilled it from a password manager (at least not with BitWarden). The solution is to simply type in your username and password instead of using autofill.

1 Like

Using iOS 17 Beta, the same bug/feature is present here, so thank you for answering your own question!

2 Likes

I have the exact same problem on my Android with an old MIUI with Google Home (app version 3.6.1.5)
without autofill!

2023-09-19 22:02:17.773 WARNING (MainThread) [homeassistant.components.http.ban] Login attempt or request with invalid authentication from mob-XX-XX-201-33.net.vodafone.it (5.90.XX.XX). Requested URL: '/auth/login_flow/asdsded5ef14df6a3a014acd171af'. (Mozilla/5.0 (Linux; U; Android 9; it-it; MIX 2 Build/PKQ1.190118.001) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/71.0.3578.141 Mobile Safari/537.36 XiaoMi/MiuiBrowser/11.0.13)

EDIT:
Just used another device with app version 3.4.15 it worked!

1 Like