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

"invalid_grant" error in google authentication only for iOS 16 devices. #400

Open
archana211 opened this issue Sep 26, 2022 · 0 comments
Open

Comments

@archana211
Copy link

Hello,
For iOS 16 device getting "invalid_grant"(Bad Request) error. The same code is working for the iOS 15.1 version.

Code setup:
self.oauth2 = OAuth2CodeGrant(settings: [
"client_id": “XXXXX”,
"authorize_uri": "https://accounts.google.com/o/oauth2/v2/auth",
"token_uri": "https://www.googleapis.com/oauth2/v4/token",
"redirect_uris": [“XXXX"],
"scope": "https://www.googleapis.com/auth/youtube.upload",
"use_keychain": true,
"keychain_access_mode": kSecAttrAccessibleAfterFirstUnlock,
"keychain_account_for_tokens": “XXXXXX”,
] as OAuth2JSON)

self.oauth2.authorize { result, error in
print("error",error?.localizedDescription) // The operation couldn’t be completed. (Base.OAuth2Error error 13.)
}

Testing version:
p2/OAuth2: Master branch's latest version,
Realdevices: iPhone 11 (iOS16) - not working, iphone 11(iOS 15.1) - working.

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

1 participant