]> git.ipfire.org Git - thirdparty/krb5.git/commit
Fix IAKERB context aliasing bugs [CVE-2015-2696]
authorNicolas Williams <nico@twosigma.com>
Mon, 14 Sep 2015 16:28:36 +0000 (12:28 -0400)
committerTom Yu <tlyu@mit.edu>
Wed, 25 Nov 2015 22:00:42 +0000 (17:00 -0500)
commitf84d3d246ef2960b2fedcbb5474b2b8a07b53be8
treea2227e6f340c76ef7f677714fd8d8d1efa02fcfd
parentdab2474dc628c5d05bc2863d37fd62a71ddb59fd
Fix IAKERB context aliasing bugs [CVE-2015-2696]

The IAKERB mechanism currently replaces its context handle with the
krb5 mechanism handle upon establishment, under the assumption that
most GSS functions are only called after context establishment.  This
assumption is incorrect, and can lead to aliasing violations for some
programs.  Maintain the IAKERB context structure after context
establishment and add new IAKERB entry points to refer to it with that
type.  Add initiate and established flags to the IAKERB context
structure for use in gss_inquire_context() prior to context
establishment.

CVE-2015-2696:

In MIT krb5 1.9 and later, applications which call
gss_inquire_context() on a partially-established IAKERB context can
cause the GSS-API library to read from a pointer using the wrong type,
generally causing a process crash.  Java server applications using the
native JGSS provider are vulnerable to this bug.  A carefully crafted
IAKERB packet might allow the gss_inquire_context() call to succeed
with attacker-determined results, but applications should not make
access control decisions based on gss_inquire_context() results prior
to context establishment.

    CVSSv2 Vector: AV:N/AC:M/Au:N/C:N/I:N/A:C/E:POC/RL:OF/RC:C

[ghudson@mit.edu: several bugfixes, style changes, and edge-case
behavior changes; commit message and CVE description]

(cherry picked from commit e04f0283516e80d2f93366e0d479d13c9b5c8c2a)
(cherry picked from commit 096cfaa18504d20889a3d8829decb1bf72dd0ac5)

ticket: 8282
version_fixed: 1.13.3
src/lib/gssapi/krb5/gssapiP_krb5.h
src/lib/gssapi/krb5/gssapi_krb5.c
src/lib/gssapi/krb5/iakerb.c