如何在 wso2 重试中添加额外的请求参数?

How to add additional request parameters in wso2 retrying?

我需要添加一个参数来重定向。当身份验证失败时,WSO2 使用 &authFailure=true&authFailureMsg=login.fail.message 请求参数重定向到登录页面。

我无法通过更改 org.wso2.carbon.identity.application.authenticator.basicauth.BasicaAuthenticator class 消息向它添加一些额外的参数。

有什么方法可以做到吗?

我无法更改 BasicAuthenticator.class。通过注册我的 LocalBasicAuthenticator 添加其他参数,其中功能与 BasicAuthenticator 相同,但您可以添加查询参数并修改它。然后在 components/dropins 中替换 jar 并在您的服务提供商中更改本地身份验证。

此外,可以通过一种非常简单的方式修改位于 login.jsp 的文件:

<WSO2_APIM_HOME>/repository/deployment/server/webapps/authenticationendpoint/login.jsp

您无需构建任何自定义身份验证器和重新部署即可完成此操作。是热部署。

仔细修改这个文件也很重要,因为它被平台上的所有登录流程使用