关于在WSO2代理上使用HTTP基本身份验证,我有一点问题,我的所有服务使用者都通过HTTP基本身份验证发送他们的凭据,&我需要在WSO2标准用户商店验证它们。
我选择使用本教程,该教程使用自定义调解器:http://wso2.com/library/knowledge-base/convert-http-basic-authentication-ws-security-username-token/
问题是当我运行测试时,我在WSO2上有以下错误,显然返回的用户域是null:
ERROR {org.wso2.carbon.esb.mediator.basicauth.internal.BasicAuthMediatorServiceComponent} - 在激活Carbon Core捆绑包之前,应该存在UserRealm服务的实例{org.wso2.carbon.esb.mediator.basicauth。 internal.BasicAuthMediatorServiceComponent} TID:[0] [ESB] [2015-04-16 16:34:13,684] ERROR {org.wso2.carbon.esb.mediator.basicauth.BasicAuthWSSecMediator} - 无法验证用户:: WSO2_Portail。错误是在激活Carbon Core捆绑包之前,应该存在UserRealm服务的实例{org.wso2.carbon.esb.mediator.basicauth.BasicAuthWSSecMediator} java.lang.Exception:在激活Carbon Core bundle之前,应该存在UserRealm服务的实例 at org.wso2.carbon.esb.mediator.basicauth.internal.BasicAuthMediatorServiceComponent.getUserRealm(BasicAuthMediatorServiceComponent.java:41) 在org.wso2.carbon.esb.mediator.basicauth.BasicAuthWSSecMediator.isAuthenticated(BasicAuthWSSecMediator.java:186) 在org.wso2.carbon.esb.mediator.basicauth.BasicAuthWSSecMediator.mediate(BasicAuthWSSecMediator.java:102) 在org.apache.synapse.mediators.ext.ClassMediator.mediate(ClassMediator.java:78) 在org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:77) 在org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:47) 在org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:131) at org.apache.synapse.core.axis2.ProxyServiceMessageReceiver.receive(ProxyServiceMessageReceiver.java:166) 在org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:180) 在org.apache.synapse.transport.passthru.ServerWorker.processEntityEnclosingRequest(ServerWorker.java:411) 在org.apache.synapse.transport.passthru.ServerWorker.run(ServerWorker.java:183) 在org.apache.axis2.transport.base.threads.NativeWorkerPool $ 1.run(NativeWorkerPool.java:172) 在java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor $ Worker.run(ThreadPoolExecutor.java:615) 在java.lang.Thread.run(Thread.java:744)