-
Notifications
You must be signed in to change notification settings - Fork 0
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
tvOS Device Authorization Flow #26
Conversation
a052fce
to
cfe24a1
Compare
# Conflicts: # Development/OpenPassDevelopmentApp/Info.plist # Development/OpenPassDevelopmentApp/Localizable.strings # Development/OpenPassDevelopmentApp/OpenPassTokensView.swift # Development/OpenPassDevelopmentApp/RootView.swift # Development/OpenPassDevelopmentApp/RootViewModel.swift # Sources/OpenPass/OpenPassClient.swift # Sources/OpenPass/OpenPassManager.swift # Sources/OpenPass/ResponseData/OpenPassTokensResponse.swift # Tests/OpenPassTests/OpenPassClientTests.swift
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.
One other observation is that by default, we are using the production API (fine) but also a client id that isn't allowed to use Device Auth Flow (since it's not a TV app). I'm assuming this is because we have a single app, so single plist and therefore only a single client id can be extracted. I wonder if this limitation is something we should revisit? Something to discuss anyway
Development/OpenPassDevelopmentApp/DeviceAuthorizationViewModel.swift
Outdated
Show resolved
Hide resolved
Development/OpenPassDevelopmentApp/DeviceAuthorizationViewModel.swift
Outdated
Show resolved
Hide resolved
7727830
to
0de5f59
Compare
0de5f59
to
389459c
Compare
I've added a note to Development/README.md to cover this, and make it easy to toggle the ID. In the future if we change how the SDK is configured, or split the Dev app, I think we can revisit 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.
Just a minor nit about some, now outdated, documentation.
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.
LGTM
Adds tvOS support for OAuth 2.0 Device Authorization Grant to the SDK.
To run the tvOS sample app and test Device Auth, you must change the
OpenPassClientId
inInfo.plist
to51c42041a7de48f59bff4f8a8a6ad18b
.OpenPassManager
propertydeviceAuthorizationFlow
for initiating the flow.