[16468] in Kerberos-V5-bugs

home help back first fref pref prev next nref lref last post

[krbdev.mit.edu #8871] git commit

daemon@ATHENA.MIT.EDU (Greg Hudson via RT)
Tue Jan 28 12:02:39 2020

From: "Greg Hudson via RT" <rt-comment@KRBDEV-PROD-APP-1.mit.edu>
In-Reply-To: 
Message-ID: <rt-4.4.4-96346-1580230927-1307.8871-4-0@mit.edu>
To: "AdminCc of krbdev.mit.edu Ticket #8871":;
Date: Tue, 28 Jan 2020 12:02:07 -0500
MIME-Version: 1.0
Reply-To: rt-comment@KRBDEV-PROD-APP-1.mit.edu
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Errors-To: krb5-bugs-bounces@mit.edu


Tue Jan 28 12:02:07 2020: Request 8871 was acted upon.
 Transaction: Ticket created by ghudson@mit.edu
       Queue: krb5
     Subject: git commit
       Owner: ghudson@mit.edu
  Requestors: 
      Status: new
 Ticket <URL: https://krbdev.mit.edu/rt/Ticket/Display.html?id=8871 >



Zero length fields when freeing object contents

In krb5_free_data_contents() and krb5_free_checksum_contents(), zero
the length as well as the data pointer to leave the object in a valid
state.  Add asserts to existing test harnesses to verify the new
behavior.

In the krb5 GSS mech's kg_checksum_channel_bindings(), remove the code
to reallocate the checksum with xmalloc(), as it relied on
krb5_free_checksum_contents() leaving the object in an invalid state.
This code was added in commit a30fb4c4400f13a2690df7ef910b7ac0ccbcf194
to match an xfree() call, but commit
29337e7c7b796685fb6a03466d32147e17aa2d16 replaced that xfree() with a
krb5_free_checksum_contents().  (In addition, the xmalloc and xfree
wrappers never evolved to do anything beyond malloc and free.)

In kpropd's recv_database(), don't free outbuf until we are done using
its length.

[ghudson@mit.edu: rewrote commit message; edited doxygen comment
changes to mention version]

https://github.com/krb5/krb5/commit/4a2c5d259f5a7eda0f0f9028c061fcd032a72de0
Author: Isaac Boukris <iboukris@gmail.com>
Committer: Greg Hudson <ghudson@mit.edu>
Commit: 4a2c5d259f5a7eda0f0f9028c061fcd032a72de0
Branch: master
 src/include/krb5/krb5.hin              |    4 ++++
 src/kprop/kpropd.c                     |    2 +-
 src/lib/crypto/crypto_tests/t_cksums.c |    1 +
 src/lib/gssapi/krb5/util_cksum.c       |   16 ----------------
 src/lib/krb5/krb/kfree.c               |    8 ++++----
 src/tests/rdreq.c                      |    2 ++
 6 files changed, 12 insertions(+), 21 deletions(-)

_______________________________________________
krb5-bugs mailing list
krb5-bugs@mit.edu
https://mailman.mit.edu/mailman/listinfo/krb5-bugs

home help back first fref pref prev next nref lref last post