pullup from trunk
authorTom Yu <tlyu@mit.edu>
Tue, 22 Mar 2005 23:25:08 +0000 (23:25 +0000)
committerTom Yu <tlyu@mit.edu>
Tue, 22 Mar 2005 23:25:08 +0000 (23:25 +0000)
ticket: 2918
version_fixed: 1.4.1

git-svn-id: svn://anonsvn.mit.edu/krb5/branches/krb5-1-4@17133 dc483132-0cff-0310-8789-dd5450dbe970

src/lib/krb5/krb/ChangeLog
src/lib/krb5/krb/gic_pwd.c

index 4280ec761587a9c5fd1dc91124fbf048a6db9b05..ba5562ed1bee01683668aa65eee2009724a97861 100644 (file)
@@ -1,3 +1,9 @@
+2005-02-09  Tom Yu  <tlyu@mit.edu>
+
+       * gic_pwd.c (krb5_get_init_creds_password): Fix so empty password
+       string causes prompting and doesn't cause truncation of password
+       to zero characters.
+
 2005-01-17  Jeffrey Altman <jaltman@mit.edu>
         * unparse.c: krb5_unparse_name, krb5_unparse_name_ext()
           prevent null pointer dereferencing if either 'name' or 'size'    
index de0f47df3d84c90eb484a9c34297a44d34bc34a4..f2837effb61d9ef788662df6d9d4a66125e511ce 100644 (file)
@@ -104,7 +104,7 @@ krb5_get_init_creds_password(krb5_context context, krb5_creds *creds, krb5_princ
 
    pw0.data = pw0array;
 
-   if (password) {
+   if (password && password[0]) {
       if ((pw0.length = strlen(password)) > sizeof(pw0array)) {
         ret = EINVAL;
         goto cleanup;