iOS 通用链接 NSURLAuthenticationMethodServerTrust kAuthenticationErr

iOS Universal Links NSURLAuthenticationMethodServerTrust kAuthenticationErr

我已经在我们的应用程序中设置了通用链接,但我无法在应用程序安装时从我的服务器检索 apple-app-site-association 文件。设备控制台在安装期间尝试检索文件时出现以下错误:

Rejecting URL 'https://example.com/apple-app-site-association' for auth method 'NSURLAuthenticationMethodServerTrust': -6754/0xFFFFE59E kAuthenticationErr

我能够使用同一台设备在 Safari 中成功检索文件。它通过 https 托管,并带有标准的 verisign 颁发的 EV 证书。在应用程序安装之外检索文件时,我没有收到任何 SSL 错误,因此我相信证书已在服务器端正确配置。

什么可能导致此错误?

事实证明,这个问题是由在 phone 上安装 Citrix 的 Worx 引起的。此应用程序在 phone 上安装了 XenMobile 的配置文件,该配置文件干扰了我们的服务器与苹果之间的 ssl 握手。只有在 phone 上安装测试应用程序时才会出现这种情况。我们从 App Store 下载的生产应用程序运行良好。此外,如果我删除 Citrix 应用程序和关联的 XenMobile 配置文件,它仍然有效。很烦人。

对我来说,问题是缺少功能条目:activitycontinuation:com.example.app。出于某种原因,当 apple-app-site-association 文件托管在 IIS 服务器上时,除了 applinks:com.example.app.

之外还需要添加该功能