为什么我收到 OTP 消息但在 WSO2 IS 中被重定向到 405 页面?

问题描述 投票:0回答:1

我正在尝试实现双因素身份验证。第一步登录应提示用户输入:用户名和密码,然后输入 SMS OTP 以进行第二步。

问题是配置 SMS OTP 后,单击“发送 OTP 按钮”后显示 405 错误

这是出现405错误的页面链接 https://localhost:9443/smsotpauthenticationendpoint/smsotp.jsp?client_id=fJsj8UV4QEH5yWkuLjevFruYGyMa&commonAuthCallerPath=%2Foauth2%2Fauthorize&forceAuth=false&passiveAuth=false&redirect_uri=http%3A%2F%2Flocalhost%3A8080%2Fpickup-dispatch%2F oauth2client&response_type=code&scope=openid+internal_application_mgt_view&tenantDomain=carbon .super&sessionDataKey=cc73a6e6-168d-40ce-8003-c0c2a26afa16&relyingParty=fJsj8UV4QEH5yWkuLjevFruYGyMa&type=oidc&sp=pickup-dispatch&isSaaSApp=false&multiOptionURI=%2Fauthenticationendpoint%2Foauth2_login.do%3Faut henticators%3DEmailOTP%253AGmail%2BOTP%253BSMSOTP%253ASMS%2BOTP%253Btotp%253ALOCAL%26response_type% 3Dcode%26type%3Doidc%26tenantDomain%3Dcarbon.super%26client_id%3DfJsj8UV4QEH5yWkuLjevFruYGyMa%26relyingParty%3DfJsj8UV4QEH5yWkuLjevFruYGyMa%26passiveAuth%3Dfalse%26isSaaSApp%3Dfalse%26commonAuthCallerPath% 3D%252Foauth2%252Fauthorize%26scope%3Dopenid%2Binternal_application_mgt_view%26forceAuth%3Dfalse%26sessionDataKey%3Dcc73a6e6- 168d-40ce-8003-c0c2a26afa16%26redirect_uri%3Dhttp%253A%252F%252Flocalhost%253A8080%252Fpickup-dispatch%252Foauth2client%26sp%3Dpickup-dispatch&authenticators=SMSOTP

我通过添加以下内容修改了部署文件。

### SMS CONFIGURATION ###
[authentication.authenticator.sms_otp] 
name ="SMSOTP"
enable=true

[authentication.authenticator.sms_otp.parameters]
SMSOTPAuthenticationEndpointURL= "/smsotpauthenticationendpoint/smsotp.jsp"
SMSOTPAuthenticationEndpointErrorPage= "/smsotpauthenticationendpoint/smsotpError.jsp"
MobileNumberRegPage = "/smsotpauthenticationendpoint/mobile.jsp"
RetryEnable = true
ResendEnable = true
BackupCode = true
SMSOTPEnableByUserClaim = true
usecase = "local"
secondaryUserstore = "primary"
SMSOTPMandatory = true
SendOtpToFederatedMobile = false
federatedMobileAttributeKey = "mobile"
CaptureAndUpdateMobileNumber = true
SendOTPDirectlyToMobile = false
redirectToMultiOptionPageOnFailure = false
TokenExpiryTime = 12

我的 SMS 提供商正在使用 GET 请求,并且在所有文档中 SMS 提供商都使用 POST。这会是问题吗?

这是我的短信身份提供商配置

sms wso2-identity-server two-factor-authentication
1个回答
0
投票

当如上所述添加deployment.toml配置时,我也可以在IS-6.1.0包中重现该问题。 从deployment.toml 文件中删除所有这些配置并尝试该流程。该流程将正常工作。

### SMS CONFIGURATION ###
[authentication.authenticator.sms_otp] 
name ="SMSOTP"
enable=true

[authentication.authenticator.sms_otp.parameters]
SMSOTPAuthenticationEndpointURL= "/smsotpauthenticationendpoint/smsotp.jsp"
SMSOTPAuthenticationEndpointErrorPage= "/smsotpauthenticationendpoint/smsotpError.jsp"
MobileNumberRegPage = "/smsotpauthenticationendpoint/mobile.jsp"
RetryEnable = true
ResendEnable = true
BackupCode = true
SMSOTPEnableByUserClaim = true
usecase = "local"
secondaryUserstore = "primary"
SMSOTPMandatory = true
SendOtpToFederatedMobile = false
federatedMobileAttributeKey = "mobile"
CaptureAndUpdateMobileNumber = true
SendOTPDirectlyToMobile = false
redirectToMultiOptionPageOnFailure = false
TokenExpiryTime = 12
© www.soinside.com 2019 - 2024. All rights reserved.