{"id":2762,"date":"2020-01-25T09:46:35","date_gmt":"2020-01-25T08:46:35","guid":{"rendered":"https:\/\/myoceane.fr\/?p=2762"},"modified":"2020-02-08T10:12:26","modified_gmt":"2020-02-08T09:12:26","slug":"android-webview-without-https","status":"publish","type":"post","link":"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/","title":{"rendered":"[Android] WebView without HTTPS"},"content":{"rendered":"<div id=\"fb-root\"><\/div>\n\n<p>\u5728\u958b\u767c Android \u7a0b\u5f0f\u7684\u6642\u5019\uff0c\u6709\u9700\u8981\u7528\u5230 WebView \u76f4\u63a5\u9023\u7d50\u7279\u5b9a\u7684\u7db2\u9801\uff0c\u4f46\u662f\u5f88\u591a\u6642\u5019\u7db2\u9801\u4e26\u6c92\u6709 HTTP SSL \u7684\u4fdd\u8b77\uff0c \u57fa\u672c\u4e0a Android 9 \u4ee5\u5f8c WebView \u5728\u986f\u793a\u6c92\u6709 SSL \u7684\u7db2\u9801\u6703\u76f4\u63a5\u986f\u793a\u8a2d\u6210 Disable\uff0c\u8a73\u60c5\u53ef\u4ee5<a href=\"https:\/\/developer.android.com\/training\/articles\/security-config#CleartextTrafficPermitted\">\u53c3\u8003<\/a>\u3002\u672c\u7bc7\u60f3\u8981\u7d00\u9304\u5982\u4f55\u5229\u7528 Android WebView \u9023\u7d50 without HTTPS \u7684\u7db2\u7ad9\u3002<\/p>\n\n\n\n<p style=\"text-align: justify;\"><b>Note:&nbsp;<\/b>The guidance in this section applies only to apps that target Android 8.1 (API level 27) or lower. Starting with Android 9 (API level 28), cleartext support is disabled by default.<\/p>\n\n\n\n<h5>\u5617\u8a66\u4e00\uff1a\u589e\u52a0 <strong>network_security_config.xml \u5230 res\/xml \u88e1\u9762<\/strong><\/h5>\n<p style=\"text-align: justify;\">\u6211\u5011\u9996\u5148\u5617\u8a66<a href=\"https:\/\/stackoverflow.com\/questions\/58003523\/how-can-i-fix-this-android-webview-problem\">\u53c3\u8003\u9023\u7d50<\/a>\u7684\u89e3\u6c7a\u65b9\u6cd5\uff0c\u5728 res\/xml \u88e1\u9762\u589e\u52a0\u4e00\u500b network_security_config.xml \u6a94\u6848\u5982\u4ee5\u4e0b\u7684\u5167\u5bb9\uff0c\u5728 &lt;domain includeSubdomains=&#8221;true&#8221;&gt; &lt;\/domain&gt; \u4e2d\u9593\u52a0\u5165\u53ef\u4ee5\u63a5\u53d7 ClearTextTraffic \u7684 URL\u3002<\/p>\n<pre class=\"lang:markup\">&lt;?xml version=\"1.0\" encoding=\"utf-8\"?&gt;\n&lt;network-security-config&gt;\n    &lt;domain-config cleartextTrafficPermitted=\"true\"&gt;\n        \/\/  Add host of your download URL in below line. \n        \/\/  ie. if url is  \"https:\/\/www.google.com\/search?source=....\"\n        \/\/  then just add \"www.google.com\"\n        &lt;domain includeSubdomains=\"true\"&gt;www.smarterasp.net&lt;\/domain&gt;\n    &lt;\/domain-config&gt;\n&lt;\/network-security-config&gt;<\/pre>\n<p>\u7136\u5f8c\u5728 AndroidManifest.xml \u88e1\u9762\u589e\u52a0\u4ee5\u4e0b\u7684\u8a2d\u5b9a\uff1a<\/p>\n<pre class=\"lang:markup\">&lt;application\n        ...\n        android:networkSecurityConfig=\"@xml\/network_security_config\"\n        ...&gt;\n&lt;\/application&gt;<\/pre>\n<p>\u4f46\u662f\u6e2c\u8a66\u7684\u7d50\u679c\u662f\u9019\u500b\u65b9\u6cd5\u4e26\u4e0d\u6709\u6548\uff0c\u4e4b\u5f8c\u5617\u8a66\u65b9\u6cd5\u4e8c\u3002\u5176\u4ed6\u53c3\u8003\u8cc7\u8a0a\uff1a<a href=\"https:\/\/stackoverflow.com\/questions\/45940861\/android-8-cleartext-http-traffic-not-permitted\">\u9023\u7d50<\/a><\/p>\n\n\n\n<h5>\u5617\u8a66\u4e8c\uff1a\u6539\u52d5 WebViewClient \u589e\u52a0 onReceivedSslError()<\/h5>\n<p>\u5728\u8a2d\u5b9a webView \u7684\u6642\u5019\u9700\u8981\u8a2d\u5b9a WebViewClient\uff0c\u9019\u500b\u65b9\u6cd5\u662f\u91cd\u65b0\u8abf\u6574\u7576 SslError \u6642\u7684\u53cd\u61c9\u65b9\u6cd5\uff0c\u5728 Android 9.0 \u4e4b\u5f8c onReceivedSslError \u7684\u9810\u8a2d\u65b9\u6cd5\u662f handler.cancel() \u6b64\u6703\u5c07 WebView \u8b8a\u6210\u7a7a\u767d\u9801\uff0c\u5c07 handler.cancel() \u6539\u6210 handler.proceed() \u4e4b\u5f8c\u5c31\u53ef\u4ee5\u6210\u529f\u986f\u793a\u6c92\u6709 SSL \u7684\u7db2\u9801\u3002<\/p>\n<pre class=\"lang:java\">webView.setWebViewClient(new WebViewClient(){\n          @Override\n            public void onReceivedSslError(WebView view, SslErrorHandler handler, SslError error){\n                handler.proceed();\n            }\n        });\n        WebSettings webSettings = webView.getSettings();\n        webSettings.setJavaScriptEnabled(true);\n        webSettings.setMixedContentMode(WebSettings.MIXED_CONTENT_ALWAYS_ALLOW);\n}<\/pre>\n<p>\u4ee5\u4e0a\u7684\u65b9\u6cd5\u96d6\u7136\u53ef\u4ee5\u89e3\u6c7a SSL \u7684\u554f\u984c\uff0c\u4f46\u662f\u5728\u767c\u4f48\u5230 Google Play Store \u7684\u6642\u5019\u767c\u751f\u4ee5\u4e0b\u932f\u8aa4\u8a0a\u606f\uff0cGoogle \u65b9\u9762\u63d0\u4f9b\u76f8\u95dc\u8cc7\u8a0a\u9023\u7d50\uff1a<a href=\"https:\/\/support.google.com\/faqs\/answer\/7071387\">https:\/\/support.google.com\/faqs\/answer\/7071387<\/a><\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/myoceane.fr\/wp-content\/uploads\/2020\/01\/\u87a2\u5e55\u5feb\u7167-2020-01-25-\u4e0a\u53487.58.19.png\" alt=\"\" class=\"wp-image-2823\" width=\"506\" height=\"133\" srcset=\"https:\/\/myoceane.fr\/wp-content\/uploads\/2020\/01\/\u87a2\u5e55\u5feb\u7167-2020-01-25-\u4e0a\u53487.58.19.png 1012w, https:\/\/myoceane.fr\/wp-content\/uploads\/2020\/01\/\u87a2\u5e55\u5feb\u7167-2020-01-25-\u4e0a\u53487.58.19-300x79.png 300w, https:\/\/myoceane.fr\/wp-content\/uploads\/2020\/01\/\u87a2\u5e55\u5feb\u7167-2020-01-25-\u4e0a\u53487.58.19-768x202.png 768w\" sizes=\"auto, (max-width: 506px) 100vw, 506px\" \/><\/figure><\/div>\n\n\n\n<p>\u6211\u5011\u5c07 onReceivedSslError \u8fd1\u4e00\u6b65\u6539\u9032\u5982\u4ee5\u4e0b\uff0c\u9084\u662f\u7121\u6cd5\u901a\u904e Google Play \u5be9\u6838\uff1a<\/p>\n<pre class=\"lang:java\">public void onReceivedSslError(WebView view, SslErrorHandler handler, SslError error){\n    if (error.getPrimaryError() == SslError.SSL_IDMISMATCH ){\n        handler.proceed();\n    } else {\n        handler.cancel();\n    }\n}<\/pre>\n<p>\u6211\u5011\u5c07 SslError \u932f\u8aa4\u7684\u60c5\u6cc1\u9650\u5236\u5728 SSL_IDMISMATCH \u5247\u53ef\u4ee5\u88ab\u63a5\u53d7\uff0c\u9019\u908a\u9084\u662f\u9700\u8981\u770b\u4e0d\u540c\u7684\u9700\u6c42\u53bb\u6539\u52d5\u3002\u5176\u4ed6\u7684\u932f\u8aa4\u60c5\u6cc1\u53ef\u4ee5\u53c3\u8003\u4ee5\u4e0b\uff1a<\/p>\n<pre class=\"lang:java\">public static final int SSL_NOTYETVALID = 0;\npublic static final int SSL_EXPIRED = 1;\npublic static final int SSL_IDMISMATCH = 2;\npublic static final int SSL_UNTRUSTED = 3;\npublic static final int SSL_DATE_INVALID = 4;\npublic static final int SSL_INVALID = 5;\n@Deprecated\npublic static final int SSL_MAX_ERROR = 6;<\/pre>\n\n\n\n<h5><strong>\u6700\u5f8c\u89e3\u6c7a\u65b9\u6cd5\uff1a<\/strong><\/h5>\n<p>\u5728\u641c\u5c0b\u5176\u4ed6\u7684\u89e3\u6c7a\u65b9\u6cd5\u4e4b\u5f8c\uff0c\u627e\u5230\u4ee5\u4e0b\u7684\u65b9\u6cd5\u53ef\u4ee5\u901a\u904e Google \u7684\u5be9\u6838\uff0c\u4f46\u662f\u4e26\u4e0d\u662f\u5b8c\u7f8e\u7684\u89e3\u6c7a\u65b9\u6cd5\uff0c\u5982\u679c WebView \u9023\u7d50\u6c92\u6709 SSL \u7684\u7db2\u7ad9\u7684\u8a71\uff0cGoogle \u9084\u662f\u5e0c\u671b\u53ef\u4ee5\u8a62\u554f\u7528\u6236\u7684\u610f\u9858\u4f86\u8fd1\u4e00\u6b65\u4fdd\u8b77\u7528\u6236\uff01<\/p>\n<pre class=\"lang:java\">SslCertificate sslCertificate = error.getCertificate();\nfinal AlertDialog.Builder builder = new AlertDialog.Builder(act);\nbuilder.setTitle(\"Website Loading, Continue?\");\nbuilder.setPositiveButton(R.string.NSLS_YES, new DialogInterface.OnClickListener() {\n    @Override\n    public void onClick(DialogInterface dialog, int which) {\n        handler.proceed();\n    }\n});\nbuilder.setNegativeButton(R.string.NSLS_CANCEL, new DialogInterface.OnClickListener() {\n    @Override\n    public void onClick(DialogInterface dialog, int which) {\n        handler.cancel();\n    }\n});\nfinal AlertDialog dialog = builder.create();\ndialog.show();<\/pre>\n<p>\u00a0<\/p>\n\n\n\n<p>\u5176\u4ed6\u53c3\u8003\u9023\u7d50\uff1a<\/p>\n<p><a href=\"https:\/\/codertw.com\/android-%E9%96%8B%E7%99%BC\/334517\/\">https:\/\/codertw.com\/android-%E9%96%8B%E7%99%BC\/334517\/<\/a><\/p>\n<p><a href=\"https:\/\/lipeng1667.github.io\/2017\/01\/03\/android-webview-https-and-taobaoke\/\">https:\/\/lipeng1667.github.io\/2017\/01\/03\/android-webview-https-and-taobaoke\/<\/a><\/p>\n<p><a href=\"https:\/\/stackoverflow.com\/questions\/58003523\/how-can-i-fix-this-android-webview-problem\">https:\/\/stackoverflow.com\/questions\/58003523\/how-can-i-fix-this-android-webview-problem<\/a><\/p>\n<p>\u00a0<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5728\u958b\u767c Android \u7a0b\u5f0f\u7684\u6642\u5019\uff0c\u6709\u9700\u8981\u7528\u5230 WebView \u76f4\u63a5\u9023\u7d50\u7279\u5b9a\u7684\u7db2\u9801\uff0c\u4f46\u662f\u5f88\u591a\u6642\u5019\u7db2\u9801\u4e26\u6c92\u6709 HTTP SSL \u7684\u4fdd\u8b77\uff0c \u57fa\u672c\u4e0a Android 9 \u4ee5\u5f8c WebView \u5728\u986f\u793a\u6c92\u6709 SSL \u7684\u7db2\u9801\u6703\u76f4\u63a5\u986f\u793a\u8a2d\u6210 Disable\uff0c\u8a73\u60c5\u53ef\u4ee5\u53c3\u8003\u3002\u672c\u7bc7\u60f3\u8981\u7d00\u9304\u5982\u4f55\u5229\u7528 Android WebView \u9023\u7d50 without HTTPS \u7684\u7db2\u7ad9\u3002<\/p>\n","protected":false},"author":1,"featured_media":2836,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7,14],"tags":[58,60,61,59],"class_list":["post-2762","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-android","category-it-technology","tag-android","tag-cleartexttraffic","tag-onreceivedsslerror","tag-webview"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v24.6 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>[Android] WebView without HTTPS - \u60f3\u65b9\u6d89\u6cd5 - \u91cf\u74f6\u5916\u7684\u5929\u7a7a M-Y-Oceane<\/title>\n<meta name=\"description\" content=\"\u5728\u958b\u767c Android \u7a0b\u5f0f\u7684\u6642\u5019\uff0c\u6709\u9700\u8981\u7528\u5230 WebView \u76f4\u63a5\u9023\u7d50\u7279\u5b9a\u7684\u7db2\u9801\uff0c\u4f46\u662f\u5f88\u591a\u6642\u5019\u7db2\u9801\u4e26\u6c92\u6709 HTTP SSL \u7684\u4fdd\u8b77\uff0c \u57fa\u672c\u4e0a Android 9 \u4ee5\u5f8c WebView \u5728\u986f\u793a\u6c92\u6709 SSL \u7684\u7db2\u9801\u6703\u76f4\u63a5\u986f\u793a\u8a2d\u6210 Disable\uff0c\u8a73\u60c5\u53ef\u4ee5\u53c3\u8003\u3002\u672c\u7bc7\u60f3\u8981\u7d00\u9304\u5982\u4f55\u5229\u7528 Android WebView \u9023\u7d50without HTTPS \u7684\u7db2\u7ad9\u3002\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"[Android] WebView without HTTPS - \u60f3\u65b9\u6d89\u6cd5 - \u91cf\u74f6\u5916\u7684\u5929\u7a7a M-Y-Oceane\" \/>\n<meta property=\"og:description\" content=\"\u5728\u958b\u767c Android \u7a0b\u5f0f\u7684\u6642\u5019\uff0c\u6709\u9700\u8981\u7528\u5230 WebView \u76f4\u63a5\u9023\u7d50\u7279\u5b9a\u7684\u7db2\u9801\uff0c\u4f46\u662f\u5f88\u591a\u6642\u5019\u7db2\u9801\u4e26\u6c92\u6709 HTTP SSL \u7684\u4fdd\u8b77\uff0c \u57fa\u672c\u4e0a Android 9 \u4ee5\u5f8c WebView \u5728\u986f\u793a\u6c92\u6709 SSL \u7684\u7db2\u9801\u6703\u76f4\u63a5\u986f\u793a\u8a2d\u6210 Disable\uff0c\u8a73\u60c5\u53ef\u4ee5\u53c3\u8003\u3002\u672c\u7bc7\u60f3\u8981\u7d00\u9304\u5982\u4f55\u5229\u7528 Android WebView \u9023\u7d50without HTTPS \u7684\u7db2\u7ad9\u3002\" \/>\n<meta property=\"og:url\" content=\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/\" \/>\n<meta property=\"og:site_name\" content=\"\u60f3\u65b9\u6d89\u6cd5 - \u91cf\u74f6\u5916\u7684\u5929\u7a7a M-Y-Oceane\" \/>\n<meta property=\"article:published_time\" content=\"2020-01-25T08:46:35+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2020-02-08T09:12:26+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/myoceane.fr\/wp-content\/uploads\/2020\/01\/ClearTextTraffic.png\" \/>\n\t<meta property=\"og:image:width\" content=\"380\" \/>\n\t<meta property=\"og:image:height\" content=\"276\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"\u6ab8\u6aac\u7238\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"\u6ab8\u6aac\u7238\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/\"},\"author\":{\"name\":\"\u6ab8\u6aac\u7238\",\"@id\":\"https:\/\/myoceane.fr\/#\/schema\/person\/4a4552fb8c27693083d465e12db7658b\"},\"headline\":\"[Android] WebView without HTTPS\",\"datePublished\":\"2020-01-25T08:46:35+00:00\",\"dateModified\":\"2020-02-08T09:12:26+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/\"},\"wordCount\":123,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/myoceane.fr\/#\/schema\/person\/4a4552fb8c27693083d465e12db7658b\"},\"image\":{\"@id\":\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/myoceane.fr\/wp-content\/uploads\/2020\/01\/ClearTextTraffic.png\",\"keywords\":[\"Android\",\"ClearTextTraffic\",\"onReceivedSslError\",\"WebView\"],\"articleSection\":[\"Android\",\"IT Technology\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/\",\"url\":\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/\",\"name\":\"[Android] WebView without HTTPS - \u60f3\u65b9\u6d89\u6cd5 - \u91cf\u74f6\u5916\u7684\u5929\u7a7a M-Y-Oceane\",\"isPartOf\":{\"@id\":\"https:\/\/myoceane.fr\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/myoceane.fr\/wp-content\/uploads\/2020\/01\/ClearTextTraffic.png\",\"datePublished\":\"2020-01-25T08:46:35+00:00\",\"dateModified\":\"2020-02-08T09:12:26+00:00\",\"description\":\"\u5728\u958b\u767c Android \u7a0b\u5f0f\u7684\u6642\u5019\uff0c\u6709\u9700\u8981\u7528\u5230 WebView \u76f4\u63a5\u9023\u7d50\u7279\u5b9a\u7684\u7db2\u9801\uff0c\u4f46\u662f\u5f88\u591a\u6642\u5019\u7db2\u9801\u4e26\u6c92\u6709 HTTP SSL \u7684\u4fdd\u8b77\uff0c \u57fa\u672c\u4e0a Android 9 \u4ee5\u5f8c WebView \u5728\u986f\u793a\u6c92\u6709 SSL \u7684\u7db2\u9801\u6703\u76f4\u63a5\u986f\u793a\u8a2d\u6210 Disable\uff0c\u8a73\u60c5\u53ef\u4ee5\u53c3\u8003\u3002\u672c\u7bc7\u60f3\u8981\u7d00\u9304\u5982\u4f55\u5229\u7528 Android WebView \u9023\u7d50without HTTPS \u7684\u7db2\u7ad9\u3002\",\"breadcrumb\":{\"@id\":\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#primaryimage\",\"url\":\"https:\/\/myoceane.fr\/wp-content\/uploads\/2020\/01\/ClearTextTraffic.png\",\"contentUrl\":\"https:\/\/myoceane.fr\/wp-content\/uploads\/2020\/01\/ClearTextTraffic.png\",\"width\":380,\"height\":276},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/myoceane.fr\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"[Android] WebView without HTTPS\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/myoceane.fr\/#website\",\"url\":\"https:\/\/myoceane.fr\/\",\"name\":\"M-Y-Oceane \u60f3\u65b9\u6d89\u6cd5\u3002\u91cf\u74f6\u5916\u7684\u5929\u7a7a\",\"description\":\"\u60f3\u65b9\u6d89\u6cd5, France, Taiwan, Health, Information Technology\",\"publisher\":{\"@id\":\"https:\/\/myoceane.fr\/#\/schema\/person\/4a4552fb8c27693083d465e12db7658b\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/myoceane.fr\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\/\/myoceane.fr\/#\/schema\/person\/4a4552fb8c27693083d465e12db7658b\",\"name\":\"\u6ab8\u6aac\u7238\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/myoceane.fr\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/6cc678684664f8ad45a8d56a6630b183?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/6cc678684664f8ad45a8d56a6630b183?s=96&d=mm&r=g\",\"caption\":\"\u6ab8\u6aac\u7238\"},\"logo\":{\"@id\":\"https:\/\/myoceane.fr\/#\/schema\/person\/image\/\"},\"url\":\"https:\/\/myoceane.fr\/index.php\/author\/johnny5584767gmail-com\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"[Android] WebView without HTTPS - \u60f3\u65b9\u6d89\u6cd5 - \u91cf\u74f6\u5916\u7684\u5929\u7a7a M-Y-Oceane","description":"\u5728\u958b\u767c Android \u7a0b\u5f0f\u7684\u6642\u5019\uff0c\u6709\u9700\u8981\u7528\u5230 WebView \u76f4\u63a5\u9023\u7d50\u7279\u5b9a\u7684\u7db2\u9801\uff0c\u4f46\u662f\u5f88\u591a\u6642\u5019\u7db2\u9801\u4e26\u6c92\u6709 HTTP SSL \u7684\u4fdd\u8b77\uff0c \u57fa\u672c\u4e0a Android 9 \u4ee5\u5f8c WebView \u5728\u986f\u793a\u6c92\u6709 SSL \u7684\u7db2\u9801\u6703\u76f4\u63a5\u986f\u793a\u8a2d\u6210 Disable\uff0c\u8a73\u60c5\u53ef\u4ee5\u53c3\u8003\u3002\u672c\u7bc7\u60f3\u8981\u7d00\u9304\u5982\u4f55\u5229\u7528 Android WebView \u9023\u7d50without HTTPS \u7684\u7db2\u7ad9\u3002","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/","og_locale":"en_US","og_type":"article","og_title":"[Android] WebView without HTTPS - \u60f3\u65b9\u6d89\u6cd5 - \u91cf\u74f6\u5916\u7684\u5929\u7a7a M-Y-Oceane","og_description":"\u5728\u958b\u767c Android \u7a0b\u5f0f\u7684\u6642\u5019\uff0c\u6709\u9700\u8981\u7528\u5230 WebView \u76f4\u63a5\u9023\u7d50\u7279\u5b9a\u7684\u7db2\u9801\uff0c\u4f46\u662f\u5f88\u591a\u6642\u5019\u7db2\u9801\u4e26\u6c92\u6709 HTTP SSL \u7684\u4fdd\u8b77\uff0c \u57fa\u672c\u4e0a Android 9 \u4ee5\u5f8c WebView \u5728\u986f\u793a\u6c92\u6709 SSL \u7684\u7db2\u9801\u6703\u76f4\u63a5\u986f\u793a\u8a2d\u6210 Disable\uff0c\u8a73\u60c5\u53ef\u4ee5\u53c3\u8003\u3002\u672c\u7bc7\u60f3\u8981\u7d00\u9304\u5982\u4f55\u5229\u7528 Android WebView \u9023\u7d50without HTTPS \u7684\u7db2\u7ad9\u3002","og_url":"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/","og_site_name":"\u60f3\u65b9\u6d89\u6cd5 - \u91cf\u74f6\u5916\u7684\u5929\u7a7a M-Y-Oceane","article_published_time":"2020-01-25T08:46:35+00:00","article_modified_time":"2020-02-08T09:12:26+00:00","og_image":[{"width":380,"height":276,"url":"https:\/\/myoceane.fr\/wp-content\/uploads\/2020\/01\/ClearTextTraffic.png","type":"image\/png"}],"author":"\u6ab8\u6aac\u7238","twitter_card":"summary_large_image","twitter_misc":{"Written by":"\u6ab8\u6aac\u7238","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#article","isPartOf":{"@id":"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/"},"author":{"name":"\u6ab8\u6aac\u7238","@id":"https:\/\/myoceane.fr\/#\/schema\/person\/4a4552fb8c27693083d465e12db7658b"},"headline":"[Android] WebView without HTTPS","datePublished":"2020-01-25T08:46:35+00:00","dateModified":"2020-02-08T09:12:26+00:00","mainEntityOfPage":{"@id":"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/"},"wordCount":123,"commentCount":0,"publisher":{"@id":"https:\/\/myoceane.fr\/#\/schema\/person\/4a4552fb8c27693083d465e12db7658b"},"image":{"@id":"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#primaryimage"},"thumbnailUrl":"https:\/\/myoceane.fr\/wp-content\/uploads\/2020\/01\/ClearTextTraffic.png","keywords":["Android","ClearTextTraffic","onReceivedSslError","WebView"],"articleSection":["Android","IT Technology"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/","url":"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/","name":"[Android] WebView without HTTPS - \u60f3\u65b9\u6d89\u6cd5 - \u91cf\u74f6\u5916\u7684\u5929\u7a7a M-Y-Oceane","isPartOf":{"@id":"https:\/\/myoceane.fr\/#website"},"primaryImageOfPage":{"@id":"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#primaryimage"},"image":{"@id":"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#primaryimage"},"thumbnailUrl":"https:\/\/myoceane.fr\/wp-content\/uploads\/2020\/01\/ClearTextTraffic.png","datePublished":"2020-01-25T08:46:35+00:00","dateModified":"2020-02-08T09:12:26+00:00","description":"\u5728\u958b\u767c Android \u7a0b\u5f0f\u7684\u6642\u5019\uff0c\u6709\u9700\u8981\u7528\u5230 WebView \u76f4\u63a5\u9023\u7d50\u7279\u5b9a\u7684\u7db2\u9801\uff0c\u4f46\u662f\u5f88\u591a\u6642\u5019\u7db2\u9801\u4e26\u6c92\u6709 HTTP SSL \u7684\u4fdd\u8b77\uff0c \u57fa\u672c\u4e0a Android 9 \u4ee5\u5f8c WebView \u5728\u986f\u793a\u6c92\u6709 SSL \u7684\u7db2\u9801\u6703\u76f4\u63a5\u986f\u793a\u8a2d\u6210 Disable\uff0c\u8a73\u60c5\u53ef\u4ee5\u53c3\u8003\u3002\u672c\u7bc7\u60f3\u8981\u7d00\u9304\u5982\u4f55\u5229\u7528 Android WebView \u9023\u7d50without HTTPS \u7684\u7db2\u7ad9\u3002","breadcrumb":{"@id":"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#primaryimage","url":"https:\/\/myoceane.fr\/wp-content\/uploads\/2020\/01\/ClearTextTraffic.png","contentUrl":"https:\/\/myoceane.fr\/wp-content\/uploads\/2020\/01\/ClearTextTraffic.png","width":380,"height":276},{"@type":"BreadcrumbList","@id":"https:\/\/myoceane.fr\/index.php\/android-webview-without-https\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/myoceane.fr\/"},{"@type":"ListItem","position":2,"name":"[Android] WebView without HTTPS"}]},{"@type":"WebSite","@id":"https:\/\/myoceane.fr\/#website","url":"https:\/\/myoceane.fr\/","name":"M-Y-Oceane \u60f3\u65b9\u6d89\u6cd5\u3002\u91cf\u74f6\u5916\u7684\u5929\u7a7a","description":"\u60f3\u65b9\u6d89\u6cd5, France, Taiwan, Health, Information Technology","publisher":{"@id":"https:\/\/myoceane.fr\/#\/schema\/person\/4a4552fb8c27693083d465e12db7658b"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/myoceane.fr\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/myoceane.fr\/#\/schema\/person\/4a4552fb8c27693083d465e12db7658b","name":"\u6ab8\u6aac\u7238","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/myoceane.fr\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/6cc678684664f8ad45a8d56a6630b183?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/6cc678684664f8ad45a8d56a6630b183?s=96&d=mm&r=g","caption":"\u6ab8\u6aac\u7238"},"logo":{"@id":"https:\/\/myoceane.fr\/#\/schema\/person\/image\/"},"url":"https:\/\/myoceane.fr\/index.php\/author\/johnny5584767gmail-com\/"}]}},"amp_enabled":false,"_links":{"self":[{"href":"https:\/\/myoceane.fr\/index.php\/wp-json\/wp\/v2\/posts\/2762","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/myoceane.fr\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/myoceane.fr\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/myoceane.fr\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/myoceane.fr\/index.php\/wp-json\/wp\/v2\/comments?post=2762"}],"version-history":[{"count":52,"href":"https:\/\/myoceane.fr\/index.php\/wp-json\/wp\/v2\/posts\/2762\/revisions"}],"predecessor-version":[{"id":2922,"href":"https:\/\/myoceane.fr\/index.php\/wp-json\/wp\/v2\/posts\/2762\/revisions\/2922"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/myoceane.fr\/index.php\/wp-json\/wp\/v2\/media\/2836"}],"wp:attachment":[{"href":"https:\/\/myoceane.fr\/index.php\/wp-json\/wp\/v2\/media?parent=2762"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/myoceane.fr\/index.php\/wp-json\/wp\/v2\/categories?post=2762"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/myoceane.fr\/index.php\/wp-json\/wp\/v2\/tags?post=2762"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}