Xcode7 使用NSURLSession发送HTTP请求的问题
2016-03-23 14:23
429 查看
在用xcode7加载一个html网页的时候,莫名其妙的加载不出来
Application
Transport Security has blocked a cleartext HTTP (http://) resource load since it is insecure. Temporary exceptions can be configured via your app's Info.plist file.
原来在iOS9 beta1中,苹果将原http协议改成了https协议,禁用了明码的HTTP请求。使用
TLS1.2 SSL加密请求数据。
需要在info.plist中添加
<key>NSAppTransportSecurity</key><dict>
<key>NSAllowsArbitraryLoads</key>
<true/></dict>
就是在plist文件中添加这样的键值对:
Application
Transport Security has blocked a cleartext HTTP (http://) resource load since it is insecure. Temporary exceptions can be configured via your app's Info.plist file.
原来在iOS9 beta1中,苹果将原http协议改成了https协议,禁用了明码的HTTP请求。使用
TLS1.2 SSL加密请求数据。
需要在info.plist中添加
<key>NSAppTransportSecurity</key><dict>
<key>NSAllowsArbitraryLoads</key>
<true/></dict>
就是在plist文件中添加这样的键值对:
相关文章推荐
- RPC failed; result=22, HTTP code = 411
- 峰回路转,Firefox 浏览器即将重返 iOS 平台
- 峰回路转,Firefox 浏览器即将重返 iOS 平台
- 不可修补的 iOS 漏洞可能导致 iPhone 4s 到 iPhone X 永久越狱
- iOS 12.4 系统遭黑客破解,漏洞危及数百万用户
- 在Windows 8.1的IE 11中屏蔽双击放大功能
- HTTP Header 属性列表
- 每日安全资讯:NSO,一家专业入侵 iPhone 的神秘公司
- nginx中http核心模块的配置指令2
- nginx中http核心模块的配置指令3
- nginx中http核心模块的配置指令4
- nginx中http的fastcgi模块的配置指令1
- [转][源代码]Comex公布JailbreakMe 3.0源代码
- Apple官网研究之使用Justify布局导航
- 如何在 Linux 中快速地通过 HTTP 提供文件访问服务