Hi, I am working on iPhone. I wanted to get a certificate that contains a particular value in the subject field. Eg. CN="myName" or O="myOrg" etc. I tried to use the SecItemCopyMatching with kSecMatchSubjectContains. but the certificate returned is not having the same subject name.
The example code as below. err = SecItemCopyMatching( (CFDictionaryRef) [NSDictionary dictionaryWithObjectsAndKeys: (id)kSecClassCertificate, kSecClass, @"CN=MyName", kSecMatchSubjectContains, kSecMatchLimitOne, kSecMatchLimit, kCFBooleanTrue, kSecReturnRef, kCFBooleanTrue, kSecReturnAttributes, nil ], (CFTypeRef *) &result1 ); or I got the subject field which is in x.500 format. How to extract CN, organization details from the x.500 formatted NSData? Regards, SivaKumar -----^v^v^------||--- _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com