2017-04-24 6 views
0

以前は、IBM MobileFirst 7.1では、authenticationConfig.xmlのカスタムセキュリティチェックを使用して、直接更新の定義済み認証領域とチャレンジハンドラを更新または調整できます。 mobileFirst 8.0アプリケーションでは、事前定義の認証領域を直接更新するカスタムセキュリティチェックをどのように使用できますか?MobileFirst 8.0で直接更新定義済み認証領域とチャレンジハンドラを更新する方法

現在、カスタムチャレンジハンドラとセキュリティチェックを使用してアプリケーションを開発しています。したがって、サーバー上のWebリソースを更新すると、クライアントのデバイス上で直接更新を開始し、Webリソースを更新してアプリケーションをリロードします。ここで、Webリソースは期待通りに更新されます。アプリのリロード後、アクセストークンを取得しようとしましたが、サーバからトークンを取得できませんでした。

ログ:

04-25 17:10:02.822 7414-8743/com.abc D/com.worklight.androidgap.directupdate.WLDirectUpdateDownloader: WLDirectUpdateDownloader.extractZipFile in WLDirectUpdateDownloader.java:320 :: File: views 
04-25 17:10:02.825 7414-8743/com.abc D/com.worklight.androidgap.directupdate.WLDirectUpdateDownloader: WLDirectUpdateDownloader.extractZipFile in WLDirectUpdateDownloader.java:353 :: Finish copy files to local storage from updated zip file... 
04-25 17:10:04.088 7414-8847/com.abc W/PluginManager: THREAD WARNING: exec() call to WLDirectUpdatePlugin.hideProgressDialog blocked the main thread for 1064ms. Plugin should use CordovaInterface.getThreadPool(). 
04-25 17:10:04.088 7414-8847/com.abc I/Choreographer: Skipped 63 frames! The application may be doing too much work on its main thread. 
04-25 17:10:04.095 7414-8743/com.abc D/com.worklight.androidgap.plugin.ChallengeHandlerPlugin: ChallengeHandlerPlugin.execute in ChallengeHandlerPlugin.java:42 :: inside ChallengeHandlerPlugin execute for action cancel 
04-25 17:10:04.096 7414-8743/com.abc D/com.worklight.androidgap.plugin.ChallengeHandlerPlugin: ChallengeHandlerPlugin.execute in ChallengeHandlerPlugin.java:64 :: inside ChallengeHandlerPlugin cancel 
04-25 17:10:04.096 7414-8743/com.abc D/wl.resource_request: WLResourceRequest$ObtainAccessTokenListener.onFailure in WLResourceRequest.java:759 :: Resource request failed with status:-1 and error: Challenge handler operation was cancelled. 
04-25 17:10:04.099 7414-8743/com.abc D/com.worklight.androidgap.plugin.WLResourceRequestPlugin: WLResourceRequestPlugin$1$1.onFailure in WLResourceRequestPlugin.java:92 :: inside WLResourceRequestPlugin failure 
04-25 17:10:04.102 7414-8743/com.abc D/WLAuthorizationManagerInternal: WLAuthorizationManagerInternal.onObtainAccessTokenFailure in WLAuthorizationManagerInternal.java:904 :: Obtain AccessToken failed with status code: -1 and error message: Challenge handler operation was cancelled. 
04-25 17:10:04.109 7414-8743/com.abc D/com.worklight.androidgap.plugin.WLActionSenderPlugin: WLActionSenderPlugin.onDestroy in WLActionSenderPlugin.java:114 :: onDestroy 
04-25 17:10:04.112 7414-8743/com.abc D/com.worklight.androidgap.plugin.WLActionSenderPlugin: WLActionSenderPlugin.removeActionReceiverIfExists in WLActionSenderPlugin.java:96 :: Receiver :: MIActionReceiverId found. Removing. 
04-25 17:10:04.113 7414-8743/com.abc D/com.worklight.androidgap.plugin.WLActionReceiverWithCallbackcontext: WLActionReceiverWithCallbackcontext.releaseCallbackContext in WLActionReceiverWithCallbackcontext.java:50 :: releaseCallbackContext 
04-25 17:10:04.206 7414-7414/com.abc I/chromium: [INFO:CONSOLE(142)] "onFailure for fetch tasks adapter call. error:{"status":-1,"responseText":"","responseHeaders":{},"errorMsg":"Challenge handler operation was cancelled.","errorCode":"CHALLENGE_HANDLING_CANCELED"}", source: file:///android_asset/www/js/controllers/myTasks.js (142) 

答えて

0

あなたがここに文書化されている8.0の直接更新のライフサイクルは、ここで

https://www.ibm.com/support/knowledgecenter/en/SSHS8R_8.0.0/com.ibm.worklight.dev.doc/dev/c_configuring_customizing_direct_update.html

んが強調されている

https://www.ibm.com/support/knowledgecenter/en/SSHS8R_8.0.0/com.ibm.worklight.dev.doc/dev/c_customizing_direct_update_ui_android_wp8_ios.html

を参照していますこのmあなたの要件を満たす。そうでない場合は、例を参考にして詳細情報を提供してください。

+0

ありがとうございました。Srinivasありがとうございました。しかし、私たちの質問は、ダイレクトアップデートUIをカスタマイズすることではありません。私は自分の質問を詳細に更新しました。あなたがより多くの情報を必要とするかどうか私に教えてください。 –

0

ここで、mobileFirst 7.1のセキュリティレルムはauthenticationConfig.xmlで定義されています。 MobileFirst 8.0は、adapter.xmlで定義されたセキュリティチェックに置き換えられます。以下のリンクを参照して、セキュリティレルムのMFP 8への移行の詳細をご確認ください。 https://mobilefirstplatform.ibmcloud.com/tutorials/en/foundation/8.0/upgrading/migrating-security/#migrating-the-resource-adapter

関連する問題