-
Notifications
You must be signed in to change notification settings - Fork 1
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
Client Side OAUTH with Token Refresh #82
base: main
Are you sure you want to change the base?
Conversation
@@ -531,6 +535,7 @@ | |||
const _host = "<%= host %>"; | |||
const _fabricApiUrl = "<%= fabricApiUrl %>"; | |||
const _firebaseConfig = <%- firebaseConfig %>; | |||
const _oauth_config = <%- oauthConfig %>; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We are not using it anywhere on the client side, are we?
The same goes for _token
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to authConfig to initialize the oicd instance.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh yeah, I saw the _oauth_config
usage. We need to remove only the _token
.
} | ||
req.session.token = accessToken |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If the token is being accessed using oidc:
const _token = (await window.UserManager.getUser())?.access_token
We probably no longer need to maintain the session on our side.
} | ||
req.session.token = accessToken |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If the token is being accessed using oidc:
const _token = (await window.UserManager.getUser())?.access_token
We probably no longer need to maintain the session on our side.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or do we? I am thinking... ..we need to check this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, we shouldn't
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we remove it then, please?
Execute the OAUTH authentication via the client side using https://github.com/authts/oidc-client-ts
The same lib is suggested in the SDK documentation.