iphone - 使用证书、 key 和信任编程指南中的代码示例时出现“extractIdentityAndTrust”错误和警告

标签 iphone ios ios4 ios-4.2

我正在尝试使用“证书、 key 和信任编程指南”中的代码。在关于从 p12 文件中提取和评估身份的部分中,使用指南中给出的代码时出现错误和警告。

线

status = extractIdentityAndTrust(inPKCS12Data, &myIdentity, &myTrust);

给出警告:“函数 extractIdentityAndTrust 的隐式声明”

而 extractIdentityAndTrust 的函数声明"
OSStatus extractIdentityAndTrust(CFDataRef inPKCS12Data,SecIdentityRef *outIdentity,SecTrustRef *outTrust)

给我错误:extractIdentityAndTrust 的类型冲突。

我只是试图实现指南中给出的代码示例。请指导我在这方面哪里出错了。

最佳答案

我的错!!没有在头文件中声明方法。

关于iphone - 使用证书、 key 和信任编程指南中的代码示例时出现“extractIdentityAndTrust”错误和警告,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4734193/

相关文章:

ios4 - 如何将外部项目添加到 Xcode 4?

ios - 如何在 ios 中通过 http get 请求在控制台中显示数据

iPhone/iOS : Subclassing UITableViewCell two times --> cannot reference properties of parentclass in InterfaceBuilder

iphone - 在更新到iOS 6之后,所有“取消”按钮都无法在sharekit中使用

ios - Swift:无法将 [CombinedChartView.DrawOrder] 类型的值分配给 [int] 的值

iphone - 我如何将数据传回父 View Controller 。我正在使用 addSubView 方法来显示 subview

iPhone 模拟器看不到我的 NSString 类别

iphone - URL 主机名返回 null

ios - 共享扩展不上传全尺寸图像

iphone - 如何让 Sprite 跟随轨迹?