Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to authenticate with Ring servers #1284

Closed
1 task done
risograph opened this issue Aug 6, 2023 · 8 comments
Closed
1 task done

Unable to authenticate with Ring servers #1284

risograph opened this issue Aug 6, 2023 · 8 comments
Labels
bug Something isn't working

Comments

@risograph
Copy link

risograph commented Aug 6, 2023

Is there an existing issue for this?

  • I have searched the existing issues

Describe The Bug

I have generated a refreshtoken successfully with the CLI tool and now when starting homebridge the ring plugin remains non-functional because the token is invalid according to an error in the logs.

To Reproduce

use homebridge-nest 11.8.1
start homebridge gui x 1.6.0
view logs
406 error after booting nest plugin

Expected behavior

honestly not sure bc i havent gotten there yet.
i assume my connected devices would appear without error.

Relevant log output

[8/7/2023, 9:29:19 AM] [Ring] HTTPError: Response code 406 (Not Acceptable)
    at Request.<anonymous> (/homebridge/node_modules/homebridge-ring/node_modules/got/dist/source/as-promise/index.js:118:42)
    at processTicksAndRejections (node:internal/process/task_queues:95:5) {
  code: 'ERR_NON_2XX_3XX_RESPONSE',
  timings: {
    start: 1691364554493,
    socket: 1691364554595,
    lookup: 1691364554597,
    connect: 1691364555096,
    secureConnect: 1691364557895,
    upload: 1691364559497,
    response: 1691364559695,
    end: 1691364559793,
    error: undefined,
    abort: undefined,
    phases: {
      wait: 102,
      dns: 2,
      tcp: 499,
      tls: 2799,
      request: 1602,
      firstByte: 198,
      download: 98,
      total: 5300
    }
  }
}
[8/7/2023, 9:29:19 AM] [Ring] Request to https://api.ring.com/devices/v1/locations failed:
[8/7/2023, 9:29:19 AM] [Ring] Error: Refresh token is not valid.  Unable to authenticate with Ring servers.  See https://github.com/dgreif/ring/wiki/Refresh-Tokens
    at RingRestClient.getGrantData (/homebridge/node_modules/homebridge-ring/node_modules/ring-client-api/lib/rest-client.js:140:15)
    at RingRestClient.getAuth (/homebridge/node_modules/homebridge-ring/node_modules/ring-client-api/lib/rest-client.js:143:32)
    at RingRestClient.getAuth (/homebridge/node_modules/homebridge-ring/node_modules/ring-client-api/lib/rest-client.js:184:29)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
[8/7/2023, 9:29:19 AM] [Ring] Error connecting to API
[8/7/2023, 9:29:19 AM] [Ring] Error: Refresh token is not valid.  Unable to authenticate with Ring servers.  See https://github.com/dgreif/ring/wiki/Refresh-Tokens
    at RingRestClient.getGrantData (/homebridge/node_modules/homebridge-ring/node_modules/ring-client-api/lib/rest-client.js:140:15)
    at RingRestClient.getAuth (/homebridge/node_modules/homebridge-ring/node_modules/ring-client-api/lib/rest-client.js:143:32)
    at RingRestClient.getAuth (/homebridge/node_modules/homebridge-ring/node_modules/ring-client-api/lib/rest-client.js:184:29)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)

Screenshots

No response

Homebridge Ring Config

{
    "refreshToken": "xxxxx",
    "platform": "Ring"
}

Additional context

No response

OS

macOS Ventura

Node.js Version

v20.4.0

NPM Version

v9.7.2?

Homebridge/HOOBs Version

v1.6.0

Homebridge Ring Plugin Version

11.8.1

Operating System

Docker

@risograph risograph added the bug Something isn't working label Aug 6, 2023
@tsightler
Copy link
Collaborator

Perhaps obvious but, as a general rule, if the API responds that the token is invalid, then it's because the token is invalid. If you just generated it, then that would indicate that there was a copy/paste error (commonly the unintentional insertion of line breaks since the token is very long) or some other issue with how the token was placed into the configuration. Other options include temporary Ring outages (they happen), or Ring has changed something and broken authentication completely, however, that latter issue would usually be followed by a significant number of reports in very short order.

You might consider using one of the UI based options for generating a token to avoid any potential copy/paste issues.

@dgreif
Copy link
Owner

dgreif commented Aug 7, 2023

406 in particular can also mean that you are being rate limited. If this occurs, you simply need to wait a bit (e.g. a few hours) and try again. This doesn't happen often, but can occur if you try to log in many times in a row.

Repository owner deleted a comment from raiubreaksthings Aug 8, 2023
Repository owner deleted a comment from raiubreaksthings Aug 8, 2023
@johnrr70

This comment was marked as off-topic.

@dgreif
Copy link
Owner

dgreif commented Aug 13, 2023

@johnrr70 please see #1286 for your specific issue. I'm going to hide your comment as it's a bit off topic for this issue, but you are welcome to post on #1286 where I've asked users to provide some specific data to help us narrow the problem down.

@PeterLawrence1
Copy link

I've just had this, however the error was due to using a VPN on my computer. I couldn't even get onto Ring's website.
I know they don't like VPN's. Once turned off I had no issue.
Do you have a VPN turned on?

@DerMuri
Copy link

DerMuri commented Aug 14, 2023

I don't have a VPN running.

Did you have the VPN running on the Homebridge or on the client side?

I've just had this, however the error was due to using a VPN on my computer. I couldn't even get onto Ring's website. I know they don't like VPN's. Once turned off I had no issue. Do you have a VPN turned on?

@PeterLawrence1
Copy link

I have Homebridge installed on my Mac

@dgreif
Copy link
Owner

dgreif commented Aug 20, 2023

Haven't heard back from @risograph, so I'm going to close this and assume it was rate limiting related.

@dgreif dgreif closed this as not planned Won't fix, can't repro, duplicate, stale Aug 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants