[krb5] - don't discard the error code from an error message received in response to a change-password req

Nalin Dahyabhai nalin at fedoraproject.org
Mon Apr 4 23:03:45 UTC 2011


commit 5ad8efcad5bb2b49bf858257c1ef2ca75604f0b5
Author: Nalin Dahyabhai <nalin at redhat.com>
Date:   Mon Apr 4 19:04:05 2011 -0400

    - don't discard the error code from an error message received in response
      to a change-password request (#658871, RT#6893)

 krb5-trunk-chpw-err.patch |   24 ++++++++++++++++++++++++
 krb5.spec                 |    6 ++++++
 2 files changed, 30 insertions(+), 0 deletions(-)
---
diff --git a/krb5-trunk-chpw-err.patch b/krb5-trunk-chpw-err.patch
new file mode 100644
index 0000000..5810f29
--- /dev/null
+++ b/krb5-trunk-chpw-err.patch
@@ -0,0 +1,24 @@
+Don't suppress the error code from an error message when the error message
+contains e-data.  RT#6893
+Index: src/lib/krb5/krb/chpw.c
+===================================================================
+--- src/lib/krb5/krb/chpw.c	(revision 24838)
++++ src/lib/krb5/krb/chpw.c	(working copy)
+@@ -111,15 +111,11 @@
+             if ((ret = krb5_rd_error(context, packet, &krberror)))
+                 return(ret);
+ 
+-            if (krberror->e_data.data  == NULL)
+-                ret = ERROR_TABLE_BASE_krb5 + (krb5_error_code) krberror->error;
+-            else
+-                ret = KRB5KRB_AP_ERR_MODIFIED;
++            ret = ERROR_TABLE_BASE_krb5 + (krb5_error_code) krberror->error;
+             krb5_free_error(context, krberror);
+             return(ret);
+-        } else {
+-            return(KRB5KRB_AP_ERR_MODIFIED);
+         }
++        return(KRB5KRB_AP_ERR_MODIFIED);
+     }
+ 
+ 
diff --git a/krb5.spec b/krb5.spec
index 29bd518..3feb849 100644
--- a/krb5.spec
+++ b/krb5.spec
@@ -54,6 +54,7 @@ Patch74: http://web.mit.edu/kerberos/advisories/2011-002-patch.txt
 Patch75: krb5-pkinit-debug.patch
 Patch76: http://web.mit.edu/kerberos/advisories/2011-003-patch.txt
 Patch77: krb5-1.9-paren.patch
+Patch78: krb5-trunk-chpw-err.patch
 
 License: MIT
 URL: http://web.mit.edu/kerberos/www/
@@ -199,6 +200,7 @@ ln -s NOTICE LICENSE
 #%patch75 -p1 -b .pkinit-debug
 %patch76 -p1 -b .2011-003
 %patch77 -p1 -b .paren
+%patch78 -p0 -b .chpw-err
 gzip doc/*.ps
 
 sed -i -e '1s!\[twoside\]!!;s!%\(\\usepackage{hyperref}\)!\1!' doc/api/library.tex
@@ -657,6 +659,10 @@ exit 0
 %{_sbindir}/uuserver
 
 %changelog
+* Mon Apr  4 2011 Nalin Dahyabhai <nalin at redhat.com>
+- don't discard the error code from an error message received in response
+  to a change-password request (#658871, RT#6893)
+
 * Fri Apr  1 2011 Nalin Dahyabhai <nalin at redhat.com>
 - override INSTALL_SETUID at build-time so that ksu is installed into
   the buildroot with the right permissions (part of #225974)


More information about the scm-commits mailing list