FirebaseUI-iOS
FirebaseUI-iOS copied to clipboard
Yahoo OAuth fails with invalid scope error
Step 1: Are you in the right place?
Step 2: Describe your environment
- Objective C or Swift: Swift
- iOS version: iOS 13
- Firebase SDK version: 10.6.0
- FirebaseUI version: 12.2.0
- CocoaPods Version: 1.11.1
Step 3: Describe the problem:
OAuth with the yahoo provider verification step fails with an invalid scope error.
I confirmed that the application registration with Yahoo is correct as I was able to successfully authenticate using the FirebaseUI-Android library.
As per yahoo documentation, to get an ID Token to authenticate a user, you are required to specify the scope identifier openid. For example: scope=openid Reference: https://developer.yahoo.com/oauth2/guide/openid_connect/getting_started.html
Steps to reproduce:
- Register an application with yahoo - https://developer.yahoo.com/oauth2/guide/openid_connect/getting_started.html
- Enable Yahoo sign-in, configure the auth provider
- Attempt to initiate authentication using yahoo provider
Observed Results:
- Yahoo OAuth request fails with error
Error getting verification code from yahoo.com response: error=invalid_scope&error_description=invalid%20scope&state=xx...xx&providerId=yahoo.com
Expected Results:
- Yahoo authentication should be successful.
Relevant Code:
if ([provider isEqualToString:@"yahoo"]) {
[providers addObject:[FUIOAuth yahooAuthProvider]];
}