在iOS中获取移动证书中包含的pfx文件 [英] get pfx file included in a mobilecertificate in iOS

查看:910
本文介绍了在iOS中获取移动证书中包含的pfx文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试使用存储在iPhone上的.mobileconfig文件中的.pfx连接到服务器。



当服务器请求时

   - (void)connection:(NSURLConnection *)connection didReceiveAuthenticationChallenge:(NSURLAuthenticationChallenge *)challenge {

如何使用.pfx创建NSURLCredential?我应该使用

  +(NSURLCredential *)credentialWithIdentity:(SecIdentityRef)identity certificates:(NSArray *)certArray persistence:(NSURLCredentialPersistence)持久化

如果是这种情况,如何提取.pfx将其放入数组。 / p>

提前感谢。

解决方案

从mobileconfig文件获取证书。 iOS应用程序使用自己的钥匙串访问和存储。只有电子邮件和其他电话服务(如互联网)才能使用这些证书


I'm trying to connect to a server using a .pfx that is stored in a .mobileconfig file on my iPhone.

When the server ask for it in

-(void)connection:(NSURLConnection*)connection didReceiveAuthenticationChallenge:(NSURLAuthenticationChallenge*)challenge{

How can I create the NSURLCredential with the .pfx? Should I use

+ (NSURLCredential *)credentialWithIdentity:(SecIdentityRef)identity certificates:(NSArray *)certArray persistence:(NSURLCredentialPersistence)persistence

If thats the case, how do I extract the .pfx to put it into the array.

Thanks in advance.

解决方案

So no, there is no way to get the certificate from the mobileconfig file. iOS applications use its own keychain access and storage. Only email and other phone service like internet can make use of those certificates

这篇关于在iOS中获取移动证书中包含的pfx文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆