Hybrid App - 安全 - 开源实现

为了解决通讯中的安全问题(http://drops.wooyun.org/papers/548) 替换addJavascriptInterface 方法。java

safe-java-js-webview-bridgegit

参考:http://www.pedant.cn/2014/07/04/webview-js-java-interface-research/github

源代码:https://github.com/pedant/safe-java-js-webview-bridgeweb

利用WebChromeClient回调中 onJsAlertonJsPrompt 方法来实现js像native通讯安全

 

jsBridgeide

参考:https://github.com/lzyzsd/JsBridgespa

利用 WebViewClient 回调中的 shouldOverrideUrlLoading 方法来实现native通讯code