ios - auth0 登录问题“我们很抱歉,尝试登录时出现问题。” 错误 403 无效状态
问题描述
在我使用Auth0.swift库的 iOS 应用程序上
我在尝试对用户进行身份验证时看到此错误。“很抱歉,尝试登录时出现问题。”</p>
应用程序以下列方式询问身份验证
Auth0
.webAuth()
.scope("openid profile email offline_access")
.audience("https://api.xxx.xxx")
.start
执行请求时调试 Safari 登录页面
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
我看到以下错误响应
{ "statusCode": 403,
"description": "Invalid state",
"name": "AnomalyDetected",
"code": "access_denied" }
不幸的是,我无法在我的调试环境中再重现它,但对于某些用户来说,该问题仍然存在于现场。我怀疑它可能与 iOS 12 更新有关。
解决方案
有错误name": "AnomalyDetected", "code": "access_denied"
。您确定您没有打开异常检测并且从同一个 IP 进行了多次失败的登录尝试吗?
推荐阅读
- c# - C# 保持 DataTable 与数据库同步
- c++ - 制作一个未知的类实例
- elasticsearch - Ansible elasticsearch jinja2 模板无法正常输出
- php - 127.0.0.1 目前无法处理此请求。HTTP 错误 500 laravel
- android - 为 MongoDB Mobile 加载 android-aarch64/libmongo_embedded_capi.so 时出错
- python - ValueError:对象太深,无法在 np.digitize 函数中使用所需的数组
- range - Apex:如何达到下限中的 bk 变量?
- r - 如何从多个列表(数字?
- javascript - Drupal - CKEditor 的 config.js 在哪里?
- angular - Angular:如何在其他类方法中访问构造函数的私有输入参数?