gpt4 book ai didi

ios - 什么是 NSExceptionDomains 以及我应该何时使用它?

转载 作者:可可西里 更新时间:2023-11-01 04:40:57 28 4
gpt4 key购买 nike

具有网络编程的 iOS 新手。

请任何人帮助理解这一点?

  <key>NSExceptionDomains</key>
<dict>
<key><!-- your_remote_server.com / localhost --></key>
<dict>
<key>NSIncludesSubdomains</key>
<true/>
<key>NSExceptionAllowsInsecureHTTPLoads</key>
<true/>
<key>NSExceptionRequiresForwardSecrecy</key>
<true/>
</dict>
<!-- add more domain here -->
</dict>

最佳答案

Apple 引入了 App Transport Security (ATS) 并要求应用程序与服务器通信建立安全连接。作为一项临时措施,在所有应用程序和服务器都符合要求之前,它们允许您定义安全要求的异常(exception)情况。您可以在此处阅读更多信息:https://developer.apple.com/library/content/documentation/General/Reference/InfoPlistKeyReference/Articles/CocoaKeys.html#//apple_ref/doc/uid/TP40009251-SW35

关于ios - 什么是 NSExceptionDomains 以及我应该何时使用它?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40478331/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com