-
Notifications
You must be signed in to change notification settings - Fork 219
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
Support refresh token authentication #69
Conversation
@@ -339,6 +371,14 @@ public protocol Authentication: Trackable, Loggable { | |||
- seeAlso: https://tools.ietf.org/html/rfc7636 | |||
*/ | |||
func tokenExchange(withCode code: String, codeVerifier: String, redirectURI: String) -> Request<Credentials, AuthenticationError> | |||
|
|||
/** | |||
Authenticate with a refresh_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.
Renew user's credentials with a refresh_token
/** | ||
Authenticate with a refresh_token. | ||
|
||
- Parameter token: the clients refresh_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.
`- Parameter refreshToken: the client's refresh token obtained on auth
- Parameter token: the clients refresh_token | ||
- Returns: a request that will yield Auth0 user's credentials | ||
*/ | ||
func login(withToken token: String) -> Request<Credentials, AuthenticationError> |
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.
func renew(withRefreshToken refreshToken: String) -> Request<Credentials, AuthenticationError>
- Parameter token: the clients refresh_token | ||
- Returns: a request that will yield Auth0 user's credentials | ||
*/ | ||
func login(withToken token: String) -> Request<Credentials, AuthenticationError> |
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.
Needs to be public
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't change to public in protocol, access is inline with other methods and I didn't have any issues accessing in the App ViewController.
53ed8ff
to
55541ee
Compare
7c41a83
to
295993f
Compare
295993f
to
fb9abe8
Compare
Also adds method to call delegation.
Closes #55 also fixes #59