Description
Logout on iOS is problematic for us, due to additionalParameters: { prompt: 'login' }
being ignored. I'm looking at the approaches I could take to get a working logout.
Previously, I had edited AppAuth-iOS to force the use of SFAuthenticationSession and then used react-native-safari-view to clear the authentication cookie. openid/AppAuth-iOS#182, but these customizations were lost during our last update and look more difficult now since the pod is now being pulled automatically.
Some possible solutions I was looking at:
-
Disable Pod install of AppAuth-iOS, include source manually and update as before.
-
Fork this and update the code to allow implementation as per the gist here which changes AppAuth to always use the SFSafariViewController https://gist.github.com/WilliamDenniss/18f3779b4a310361bb955cf4e534f29c (Support sign on without SSO (no SFAuthenticationSession) openid/AppAuth-iOS#209).
-
Fork this and add an iOS only method which will call out to the signout endpoint on iOS only. The issue with this is it looks like it opens with a prompt stating sign-in which doesn't look good. Logout popup says 'Log in' instead of 'Log out' openid/AppAuth-iOS#461
I am currently thinking approach 2 looks to be the best, if I'm missing anything or anyone has any better suggestions please let me know!
Related to #68