cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: darwin-ssl relies upon Apple documentation error

From: <myriachan_at_cox.net>
Date: Tue, 12 Nov 2013 18:36:34 -0800

---- Nick Zitzmann <nick_at_chronosnet.com> wrote:
>
> On Nov 12, 2013, at 7:18 PM, myriachan_at_cox.net wrote:
>
> > The following code will not start on Mac OS X 10.6 due to a symbol not existing in Security.framework:
> >
> > #if CURL_BUILD_MAC_10_6 || CURL_BUILD_IOS
> > if(CFURLCreateDataAndPropertiesFromResource(NULL, pkcs_url, &pkcs_data,
> > NULL, NULL, &status)) {
> > const void *cKeys[] = {kSecImportExportPassphrase};
> > const void *cValues[] = {password};
> > CFDictionaryRef options = CFDictionaryCreate(NULL, cKeys, cValues,
> > password ? 1L : 0L, NULL, NULL);
> >
> > Specifically, kSecImportExportPassphrase does not exist in 10.6. It was added in 10.7, even though Apple's documentation says otherwise: https://developer.apple.com/library/mac/DOCUMENTATION/Security/Reference/keychainservices/Reference/reference.html
>
> Which is really odd, because those constants appear in what is supposedly the 10.6.8 source code: <https://www.opensource.apple.com/source/libsecurity_keychain/libsecurity_keychain-55017/lib/SecImportExport.c>
>
> But I just tried it, and found out that you’re right; it won’t build due to an undefined symbols linker error. Looks like that feature has to be dropped from the Snow Leopard build…

It exists, but the .exp file doesn't export it. Also, the SecPKCS12Import function in 10.6 has #if 0'd the code block... >.<

Melissa

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2013-11-13