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

401 loop failed to retrieve accessToken, request new refreshToken ({"error":{"message":"Bad Request"}}) #148

Closed
raffis opened this issue Dec 7, 2018 · 1 comment
Assignees
Labels

Comments

@raffis
Copy link
Contributor

raffis commented Dec 7, 2018

Description

Is:

2018-12-07 06:36:34 WARNING <main> [unknown]: API: Got Status Code 401 Unauthorized
2018-12-07 06:36:34 INFO <main> [auth]: verify authentication failed ({"error":{"stack":"BlnApiRequestError: API: User is not authenticated\n    at handleResponse (/Applications/Balloon.app/Contents/Resources/app.asar/node_modules/@gyselroth/balloon-node-sync/lib/bln-api-request.js:97:21)\n    at Request.request [as _callback] (/Applications/Balloon.app/Contents/Resources/app.asar/node_modules/@gyselroth/balloon-node-sync/lib/bln-api-request.js:157:7)\n    at Request.self.callback (/Applications/Balloon.app/Contents/Resources/app.asar/node_modules/@gyselroth/balloon-node-sync/node_modules/request/request.js:185:22)\n    at emitTwo (events.js:126:13)\n    at Request.emit (events.js:214:7)\n    at Request.<anonymous> (/Applications/Balloon.app/Contents/Resources/app.asar/node_modules/@gyselroth/balloon-node-sync/node_modules/request/request.js:1161:10)\n    at emitOne (events.js:116:13)\n    at Request.emit (events.js:211:7)\n    at IncomingMessage.<anonymous> (/Applications/Balloon.app/Contents/Resources/app.asar/node_modules/@gyselroth/balloon-node-sync/node_modules/request/request.js:1083:12)\n    at Object.onceWrapper (events.js:313:30)\n    at emitNone (events.js:111:20)\n    at IncomingMessage.emit (events.js:208:7)\n    at endReadableNT (_stream_readable.js:1056:12)\n    at _combinedTickCallback (internal/process/next_tick.js:138:11)\n    at process._tickCallback (internal/process/next_tick.js:180:9)","name":"BlnApiRequestError","message":"API: User is not authenticated","code":"E_BLN_API_REQUEST_UNAUTHORIZED"}})
2018-12-07 06:36:34 INFO <main> [auth]: login failed ({"error":{"stack":"BlnApiRequestError: API: User is not authenticated\n    at handleResponse (/Applications/Balloon.app/Contents/Resources/app.asar/node_modules/@gyselroth/balloon-node-sync/lib/bln-api-request.js:97:21)\n    at Request.request [as _callback] (/Applications/Balloon.app/Contents/Resources/app.asar/node_modules/@gyselroth/balloon-node-sync/lib/bln-api-request.js:157:7)\n    at Request.self.callback (/Applications/Balloon.app/Contents/Resources/app.asar/node_modules/@gyselroth/balloon-node-sync/node_modules/request/request.js:185:22)\n    at emitTwo (events.js:126:13)\n    at Request.emit (events.js:214:7)\n    at Request.<anonymous> (/Applications/Balloon.app/Contents/Resources/app.asar/node_modules/@gyselroth/balloon-node-sync/node_modules/request/request.js:1161:10)\n    at emitOne (events.js:116:13)\n    at Request.emit (events.js:211:7)\n    at IncomingMessage.<anonymous> (/Applications/Balloon.app/Contents/Resources/app.asar/node_modules/@gyselroth/balloon-node-sync/node_modules/request/request.js:1083:12)\n    at Object.onceWrapper (events.js:313:30)\n    at emitNone (events.js:111:20)\n    at IncomingMessage.emit (events.js:208:7)\n    at endReadableNT (_stream_readable.js:1056:12)\n    at _combinedTickCallback (internal/process/next_tick.js:138:11)\n    at process._tickCallback (internal/process/next_tick.js:180:9)","name":"BlnApiRequestError","message":"API: User is not authenticated","code":"E_BLN_API_REQUEST_UNAUTHORIZED"}})
2018-12-07 06:36:34 INFO <main> [openid-connect]: found refreshToken, trying to request new access token
2018-12-07 06:36:35 INFO <main> [openid-connect]: failed to retrieve accessToken, request new refreshToken ({"error":{"message":"Bad Request"}})
2018-12-07 06:36:35 INFO <main> [openid-connect]: oauth2 authorization request ({"config":{"authorizationEndpoint":"https://accounts.xxx/auth","tokenEndpoint":"https://accounts.xxx/token","revocationEndpoint":"https://accounts.xxx"},"request":{"clientId":"xxx","redirectUri":"http://127.0.0.1:13006","scope":"openid profile offline_access","responseType":"code","extras":{"prompt":"consent","access_type":"offline"},"state":"IP2mnU8G5R"}})

Should:

balloon desktop version

Your client operating system

Filesystem (If known)

balloon server version (If known)

@raffis raffis added the bug label Dec 7, 2018
@raffis raffis added this to the 1.0.x milestone Dec 7, 2018
@raffis raffis removed this from the 1.0.x milestone Dec 21, 2018
@pixtron pixtron self-assigned this Nov 25, 2019
@pixtron
Copy link
Member

pixtron commented Nov 25, 2019

After looking through the logs, the user tried to link the account multiple times. The client always get to 2018-12-07 06:36:35 INFO <main> [openid-connect]: oauth2 authorization request but probably can't start the server because #21. In v0.2.4 which was used by the user, we can't see the EADDRINUSE error in the error.log.

Closing this issue as we are already tracking it with #21.

@pixtron pixtron closed this as completed Nov 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants