Issue with new android app

I am trying to use the android mobile app too, but I cannot get in…
The error in the app says: Error: invalid client id or redirect uri

2019-11-23 13:41:24 ERROR (MainThread) [homeassistant.components.auth.indieauth] Timeout while looking up redirect_uri https://home-assistant.io/android
2019-11-23 13:41:24 WARNING (MainThread) [homeassistant.components.http.ban] Login attempt or request with invalid authentication from 192.168.x.xx

I have moblie_app: in my configuration.yaml. Not sure what else is needed as I cannot find any documentation.

Any help would be appreciated.

2 Likes

It’s better to check on Github whether your issue has already been openend, and if not open a new issue there.

Which address did you enter in the app to connect to home assistant?

1 Like

I entered the full address: http:\\192.168.xx.xx:8123. And this link is working as the app does communicate with HA, as it knows what kind of authentication I am using (trusted network or HA auth). However I never get a change to enter any user credentials.

Did the network scan not find your home assistant instance? Did you enter the address like this with backslashes or is this just a typo? It should be with normal slashes like http://192.168.x.x:8123

The network scan did not find my RPI with HA. I think it is because I have deconz running on it (on port :80). I have noticed that other network scans see my RPI as a Philips HUE bridge…

(removed part on keyboard, was not relevant)

I have tried again on my android phone. It is smart enough to correct the backslash to slash, so that is for sure not an issue.

I assume this is a typo, however this is not needed, I don’t have this im my config but it works.
Did you try complety removing the app, clearing cache and reinstall it?

Having the same issue. Let’s Encrypt SSL, URL: https://my.domain.nl:8123. Phone and Hassio are on the same network.

Did you try without :8123? When you login via browser do you enter https://my.domain.nl:8123/?

without the :8123 thus only using: http://192.168.x.x I get the following error:

This is not the page you are looking for
The file /auth/authorize couldnot be found

Just like barrymossel I am also using dutch so could it be language setting related? I.e. when not on english it does not work?

This was for barrymossel as he tries to access it remotely. You need the :8123 as you are trying to access it locally.

I don’t think it’s language related, mine is in german and works.

ADDRESS_UNREACHABLE

I believe the port is necessary…

I believe that the issue with the android apps has something to do with permissions. I get the following in my log file:

Timeout while looking up redirect_uri https://home-assistant.io/android
Login attempt or request with invalid authentication from 192.168.x.xx

my relevant part of the config:

  auth_providers:
    - type: trusted_networks
      trusted_networks:
        - 192.168.x.0/24

With a web-browser I can login from the same device. So the trusted network is setup correct. Only from the app on the same device I am not allowed.

1 Like

I too am getting this.

My setup is home-assistant in a docker container behind an nginx container doing the port forwarding. nginx uses lets encrypt for wildcard certificates.

all traffic goes through nginx 80:443 – everything else is blocked from an external standpoint. I use pihole for split horizon DNS (eg: no hair pin turns – if you are on wifi, you get the private IP address of the nginx container)

Did you find a solution. I am in the same position.

No sorry, still not working for me.

1 Like

There was an update of the app on the playstore (dec 19). However no change.
Have these 2 errors:

Timeout while looking up redirect_uri https://home-assistant.io/android

and

Login attempt or request with invalid authentication from 192.168.x.xx

The first error I can understand as I do not have https support setup.
The second error I do not understand as all users on the local network are allowed.

I managed to solve this issue on my PI. The problem was exactly what the logs said: Home assistant was unable to reach https://home-assistant.io/android.

I tried to reach the URL in an SSH terminal session (with wget) and got a similar error.
I tried to reach the URL from my windows laptop, and it worked fine.

It turned out that the problem was with my static ip configuration. I changed the DNS server to 8.8.8.8 (google DNS server) and the problem went away.

I was having the same problem, following this thread I click on https://home-assistant.io/android when to that page.
Later I entered my Pi address again http://192.168.xxx.xxx:8123 and then it worked!

I had the same issue where it didn’t discover my HA and wouldn’t login if I tried manually. I switched from trying with the admin user to the user I created for myself and it successfully logged in.