On Mar 13, 2005, at 7:48 AM, Martin Hauner wrote:
> Hi,
>
> if i set 'const char *password' in 'svn_auth_cred_simple_t' to 0
> subversion crashes in cram.c compute_digest (called from
> svn_ra_svn__cram_client) when running strlen on the password (on 1.1.x
> branch).
>
> This happens in my (client) code when the user does not enter a
> password in
> the prompt dialog.
>
> The code should check the pointer first.
>
Why do you say that? The various svn_auth.h APIs promise to either
return a "good" cred_simple_t structure, or NULL. I think it's
completely reasonable for code that receives a non-NULL cred_simple_t
structure to assume that the structure is complete.
I would argue that the bug is in your client. If the user doesn't
enter a password, then it should return a credentials structure with
password = "".
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sun Mar 13 15:19:48 2005