FormidableLabs / FormidableLabs/react-native-app-auth

When using iosCustomBrowser after a redirect it does not return authorization tokens

Abierto
#1,104 0 comentarios 1 reacción 0 asignados Ver en GitHub
Lenguaje dominante
Java
Estrellas
2.3k
Forks
473
Métricas de merge de PR
Sin PR fusionados en 30 d

Descripción

## Issue

If I remove iosCustomBrowser from the config file, authorization occurs within the app in a drop-down WebView. But this option doesn't suit me. I want to use the login and password saving feature provided by iosCustomBrowser: 'safari'. When the user is redirected to a separate browser window, after successful authorization, I'm returned to the app, and the result doesn't produce any logs or anything. In the inspector, I don't see a URL that ends in protocol/openid-connect/token with the POST method. As soon as I remove iosCustomBrowser: 'safari', everything starts working again. I'm looking for a way to save the login and password. If you have an alternative solution, I'd be glad to see it. Thanks.

---

## Environment

I updated react-native-app-auth to version 8.1.0

I'm using the following config

const config: AuthConfiguration = {
iosCustomBrowser: 'safari',
iosPrefersEphemeralSession: true,
redirectUrl: redirectUrl,
androidAllowCustomBrowsers: ['chrome'],
additionalParameters: {
prompt: 'login',
},
androidTrustedWebActivity: true,
clientId: clientId,
issuer: issuerUri,
scopes: ['openid', 'profile'],
usePKCE: true,
skipCodeExchange: false,
};

I'm using the authorization method
const result = await authorize(config);

Keycloak type auth

IOS device

"react-native-app-auth": "8.1.0",
"react-native": "0.76.0",

I'm not used expo

Guía de contribución

Abrir la guía de contribución

Línea de trabajo

Comienza con authorize(config) usando la configuración proporcionada de react-native-app-auth 8.1.0 y reproduce el flujo de iOS con iosCustomBrowser establecido en safari y la redirectUrl indicada. Compáralo con el flujo funcional del navegador integrado en la aplicación; se considera terminado cuando una redirección exitosa de Safari devuelve tokens de autorización y se realiza el intercambio de tokens.

Escrito por el modelo de indexación a partir del texto del issue.

Evaluación

Stack tecnológico
ios, react-native
Área
authentication, mobile-dev
Tipo de issue
Error
Dificultad
4/5
Tiempo estimado
3-5 días
Estado de actividad
Estancado
Claridad
Bastante claro
Aptitud para principiantes
35/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.