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

Refresh Token Confusion #19

Open
silenuz opened this issue Dec 17, 2020 · 1 comment
Open

Refresh Token Confusion #19

silenuz opened this issue Dec 17, 2020 · 1 comment

Comments

@silenuz
Copy link

silenuz commented Dec 17, 2020

When I run a forced refresh things don't seem to work as expected.

So I connect to an app it goes as expected, the grant completes fine. When I run xoauth token client I see something like this:

`{
"access_token": "eyJhbGciOiJSUzI1NiIsImtpZCI6IjFDQUY4 REDACTED",

"id_token": "eyJhbGciOiJSUzI1NiIsImtpZCI6IjFDQUY4R REDACTED",

"refresh_token": "6937da68856f6ec7a9df734066c87ac85a29d34859be7 REDACTED",

"token_type": "Bearer",

"expires_in": 1800,

"expires_at": 1608247020
}`

So far so good. However if I run xoauth client token --refresh
It again looks good:

`{
"access_token": "eyJhbGciOiJSUzI1NiIsImtpZCI6IjFDQUY4 REDACTED",

"id_token": "eyJhbGciOiJSUzI1NiIsImtpZCI6IjFDQUY4R REDACTED",

"refresh_token": "85d37f3e9d0765d4e58d0853bc1f30b67a09c3021db77f3c57a REDACTED,

"token_type": "Bearer",

"expires_in": 1800,

"expires_at": 1608247306
`
It still looks good however the next time I call xoauth token client I get this:

`{
"access_token":
"eyJhbGciOiJSUzI1NiIsImtpZCI6IjFDQUY4R REDACTED",

"id_token": "",

"refresh_token": "85d37f3e9d0765d4e58d0853bc1f30b67a09c3021db77f3c57a REDACTED",

"token_type": "",

"expires_in": 0,

"expires_at": 1608247306
`

Note that suddenly the token says it is expired, id token and token type are now blank. So I'm wondering what is the proper way to use the cli client to refresh a token?

Also on Linux at least the output from xoauth list is piped to stderr instead of stdout.

@iamjoya
Copy link

iamjoya commented May 18, 2021

Encountered the same issue as well when calling xoauth token client it returns these "id_token": "",, "token_type": "", "expires_in": 0,".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants