iOS9 workaround for HTTP not working properly

Source: Internet
Author: User

Today just upgraded Xcode7, built-in the latest version of the iOS9 SDK, wrote a small demo to find the image can not be downloaded, while the system printout:

APP 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.

A look at this HTTP I think of the apple in the iOS9 began to use a more secure HTTPS protocol, and now most of the company's server estimates are not upgraded to this, which led to the failure of the download, iOS9 by default is HTTPS, but can also be set to tell the system we also use HTTP, Here's how:

      1. Search in Filter Info.plist , select Info.plist to edit

      2. According to the above-mentioned way to add information, the correct changes will see this look, note the type NSAppTransportSecurity Dictionary , NSAllowsArbitraryLoads for Boolean , copy and paste, do not have more space, segment fault page directly copied, often more one out of space!

Note that there is also a unit test below Info.plist , it is not useful to modify that file!

With the above settings can be the same as the previous use of HTTP, but the personal feeling is not server-side updates, support HTTPS or more secure ...

Reference: http://segmentfault.com/a/1190000002933776

iOS9 workaround for HTTP not working properly

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.