[英]auth0 login issue “We’re sorry, something went wrong when attempting to log in.” error 403 Invalid State
On my iOS app that is using Auth0.swift library 在我的使用Auth0.swift库的iOS应用上
I see this error trying to authenticate the user. 我看到此错误试图验证用户。 “We're sorry, something went wrong when attempting to log in.”
“很抱歉,尝试登录时出了点问题。”
The application is asking the authentication in the following way 应用程序通过以下方式询问身份验证
Auth0
.webAuth()
.scope("openid profile email offline_access")
.audience("https://api.xxx.xxx")
.start
Debugging the Safary login page when the request is performed 执行请求时调试Safary登录页面
Request
:method: POST
:scheme: https
:authority: XXX.eu.auth0.com
:path: /usernamepassword/login
Content-Type: application/json
Accept: / Host: XXX.eu.auth0.com
Accept-Language: en-us
Accept-Encoding: br, gzip, deflate
Origin: https://XXX.eu.auth0.com
Referer: https://XXX.eu.auth0.com/login?state=IqUcaKz8oL43BPVflsm84gUET1cDrnaN&client=XXXmyclientIDXXX&protocol=oauth2&response_type=code&redirect_uri=xxx.XXX%3A%2F%2FXXX.eu.auth0.com%2Fios%2Fxxx.XXX%2Fcallback&audience=https%3A%2F%2Fapi.XXX.xxx&code_challenge=U89LGQB5BSIi5ilLyQqSTVqjrqYDwn9O700SrC-70tk&code_challenge_method=S256&scope=openid%20profile%20email%20offline_access&auth0Client=xxx
User-Agent: Mozilla/5.0 (iPhone; CPU iPhone OS 12_0_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/12.0 Mobile/15E148 Safari/604.1 DNT: 1
Connection: keep-alive
Content-Length: 722
Auth0-Client: xxx
I see the following error response 我看到以下错误响应
{ "statusCode": 403,
"description": "Invalid state",
"name": "AnomalyDetected",
"code": "access_denied" }
Unfortunately I am not able to reproduce it anymore in my debug environment but the problem is still present in the field for some users. 不幸的是,我无法再在调试环境中重现它,但是对于某些用户来说,该问题仍然存在。 I suspect that it could be related to the iOS 12 update.
我怀疑这可能与iOS 12更新有关。
错误name": "AnomalyDetected", "code": "access_denied"
。您确定没有打开异常检测功能并且从同一IP尝试了几次登录失败吗?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.