我在混合mobilefirst 6.3应用程序中工作,我想在登录之前访问适配器,有没有办法可以做到这一点?因为每次我想访问我的适配器时都会发生handleChallenge方法。
应用descriptor.xml:
<android version="1.0" securityTest="NevadaApplication-strong-mobile-securityTest">
我的适配器配置xml:
<procedure name="getPhoneNumber" securityTest="wl_unprotected"/>
答案 0 :(得分:0)
因为您已经在应用程序级别设置了安全性测试,这意味着在application-descriptor.xml中的环境中,尽管将适配器过程设置为安全性测试设置为wl_unprotected,但您将遇到质询处理程序。 / p>
要实现您正在寻找的内容,您需要在适配器过程中添加安全测试(使用您希望不受保护的wl_protected)并保留环境,而不在应用程序描述符中为其分配安全测试.XML。
在此处阅读有关安全测试的更多信息:https://www.ibm.com/developerworks/community/blogs/worklight/entry/understanding_predefined_worklight_authentication_realms_and_security_tests11?lang=en
在此处详细了解不同的身份验证选项:https://developer.ibm.com/mobilefirstplatform/documentation/getting-started-6-3/authentication-security/authentication-concepts/