[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] Issue 2489 - Add support for storing SSL client certificate passphrases in OSX Keychain.

From: Jeremy Whitlock <jcscoobyrs_at_gmail.com>
Date: Sun, 31 Aug 2008 11:43:12 -0600

>> ===================================================================
>> --- subversion/libsvn_subr/cmdline.c (revision 32800)
>> +++ subversion/libsvn_subr/cmdline.c (working copy)
>> @@ -509,7 +509,20 @@
>> {
>> #ifdef SVN_HAVE_KEYCHAIN_SERVICES
>> svn_auth_get_keychain_simple_provider(&provider, pool);
>> - APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *) = provider;
>> +
>> + if (provider)
>> + {
>> + APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *)
>> + = provider;
>> + }
>> +
>> + svn_auth_get_keychain_ssl_client_cert_pw_provider(&provider, pool);
>> +
>> + if (provider)
>> + {
>> + APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *)
>> + = provider;
>> + }
>
> provider cannot be NULL here, so there should be:
>
> svn_auth_get_keychain_simple_provider(&provider, pool);
> APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *) = provider;
> svn_auth_get_keychain_ssl_client_cert_pw_provider(&provider, pool);
> APR_ARRAY_PUSH(providers, svn_auth_provider_object_t *) = provider;
>
> provider can be set to NULL only by get_auth_provider() which isn't used here.
>

Thanks for clarifying. I guess I was just being a little too cautious.

>> Index: subversion/include/svn_auth.h
>> ===================================================================
>> --- subversion/include/svn_auth.h (revision 32800)
>> +++ subversion/include/svn_auth.h (working copy)
>> @@ -825,6 +825,23 @@
>> void
>> svn_auth_get_keychain_simple_provider(svn_auth_provider_object_t **provider,
>> apr_pool_t *pool);
>> +
>> +/**
>> + * Create and return @a *provider, an authentication provider of type @c
>> + * svn_auth_cred_ssl_client_cert_pw_t that gets/sets information from the
>> + * user's ~/.subversion configuration directory. Allocate @a *provider in
>> + * @a pool.
>> + *
>> + * This is like svn_client_get_ssl_client_cert_pw_file_provider(), except
>
> s/client/auth/

Good eye.

>
>> + * that the password is stored in the Mac OS KeyChain.
>> + *
>> + * @since New in 1.6
>> + * @note This function is only available on Mac OS 10.2 and higher.
>> + */
>> +void
>> +svn_auth_get_keychain_ssl_client_cert_pw_provider
>> + (svn_auth_provider_object_t **provider,
>> + apr_pool_t *pool);
>> #endif /* DARWIN || DOXYGEN */
>
> --
> Arfrever Frehtes Taifersar Arahesis
>

Thanks for the review. I'll make the necessary changes and resubmit.

-- 
Take care,
Jeremy Whitlock
http://www.thoughtspark.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: dev-help_at_subversion.tigris.org
Received on 2008-08-31 19:43:31 CEST

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.