Commit Graph

19 Commits

Author SHA1 Message Date
Cy Schubert
ed549cb0c5 heimdal: Fix multiple security vulnerabilities
The following issues are patched:

 - CVE-2022-42898 PAC parse integer overflows
 - CVE-2022-3437 Overflows and non-constant time leaks in DES{,3} and arcfour
 - CVE-2021-44758 NULL dereference DoS in SPNEGO acceptors
 - CVE-2022-44640 Heimdal KDC: invalid free in ASN.1 codec

    Note that CVE-2022-44640 is a severe vulnerability, possibly a 10.0
    on the Common Vulnerability Scoring System (CVSS) v3, as we believe
    it should be possible to get an RCE on a KDC, which means that
    credentials can be compromised that can be used to impersonate
    anyone in a realm or forest of realms.

    Heimdal's ASN.1 compiler generates code that allows specially
    crafted DER encodings of CHOICEs to invoke the wrong free function
    on the decoded structure upon decode error.  This is known to impact
    the Heimdal KDC, leading to an invalid free() of an address partly
    or wholly under the control of the attacker, in turn leading to a
    potential remote code execution (RCE) vulnerability.

    This error affects the DER codec for all extensible CHOICE types
    used in Heimdal, though not all cases will be exploitable.  We have
    not completed a thorough analysis of all the Heimdal components
    affected, thus the Kerberos client, the X.509 library, and other
    parts, may be affected as well.

    This bug has been in Heimdal's ASN.1 compiler since 2005, but it may
    only affect Heimdal 1.6 and up.  It was first reported by Douglas
    Bagnall, though it had been found independently by the Heimdal
    maintainers via fuzzing a few weeks earlier.

    While no zero-day exploit is known, such an exploit will likely be
    available soon after public disclosure.

 - CVE-2019-14870: Validate client attributes in protocol-transition
 - CVE-2019-14870: Apply forwardable policy in protocol-transition
 - CVE-2019-14870: Always lookup impersonate client in DB

Sponsored by:	so (philip)
Obtained from:	so (philip)
Tested by:	philip, cy
MFC after:	immediately
2022-11-15 13:12:37 -08:00
Stanislav Sedov
ae77177087 - Update FreeBSD Heimdal distribution to version 1.5.1. This also brings
several new kerberos related libraries and applications to FreeBSD:
  o kgetcred(1) allows one to manually get a ticket for a particular service.
  o kf(1) securily forwards ticket to another host through an authenticated
    and encrypted stream.
  o kcc(1) is an umbrella program around klist(1), kswitch(1), kgetcred(1)
    and other user kerberos operations. klist and kswitch are just symlinks
    to kcc(1) now.
  o kswitch(1) allows you to easily switch between kerberos credentials if
    you're running KCM.
  o hxtool(1) is a certificate management tool to use with PKINIT.
  o string2key(1) maps a password into key.
  o kdigest(8) is a userland tool to access the KDC's digest interface.
  o kimpersonate(8) creates a "fake" ticket for a service.

  We also now install manpages for some lirbaries that were not installed
  before, libheimntlm and libhx509.

- The new HEIMDAL version no longer supports Kerberos 4.  All users are
  recommended to switch to Kerberos 5.

- Weak ciphers are now disabled by default.  To enable DES support (used
  by telnet(8)), use "allow_weak_crypto" option in krb5.conf.

- libtelnet, pam_ksu and pam_krb5 are now compiled with error on warnings
  disabled due to the function they use (krb5_get_err_text(3)) being
  deprecated.  I plan to work on this next.

- Heimdal's KDC now require sqlite to operate.  We use the bundled version
  and install it as libheimsqlite.  If some other FreeBSD components will
  require it in the future we can rename it to libbsdsqlite and use for these
  components as well.

- This is not a latest Heimdal version, the new one was released while I was
  working on the update.  I will update it to 1.5.2 soon, as it fixes some
  important bugs and security issues.
2012-03-22 08:48:42 +00:00
Stanislav Sedov
31f1e9c17f - Flatten the vendor heimdal tree. 2011-09-29 05:23:57 +00:00
Doug Rabson
33f1219925 Fix conflicts after heimdal-1.1 import and add build infrastructure. Import
all non-style changes made by heimdal to our own libgssapi.
2008-05-07 13:53:12 +00:00
Doug Rabson
c19800e8cd Vendor import of Heimdal 1.1 2008-05-07 13:39:42 +00:00
Jacques Vidrine
8d4ba808a5 Vendor import of Heimdal 0.6.3. 2005-02-24 22:22:53 +00:00
Jacques Vidrine
a43dbe2565 Clean up the Heimdal vendor branch by removing files not included in
any import for several years.

If memory serves, this was
Suggested by:	ru
an awfully long time ago-- sorry for the delay!
2005-02-24 22:14:04 +00:00
Jacques Vidrine
1c43270ada Vendor import of Heimdal 0.6.1. 2004-04-03 21:22:55 +00:00
Jacques Vidrine
bbd80c285e Vendor import of Heimdal 0.6. 2003-10-09 19:36:20 +00:00
Jacques Vidrine
4f62b1068d Add a missing include, needed to get a prototype for `des_read_pw_string'.
This is particularly important for OpenSSL 0.9.7, as `des_read_pw_string'
is a macro there.  (This fix brought in on the vendor branch, because I
already committed it to Heimdal's CVS.)
2003-01-21 14:19:06 +00:00
Jacques Vidrine
5bda878e3e Import of Heimdal 0.5.1.
Approved by:	re
2002-11-24 20:59:25 +00:00
Jacques Vidrine
0cadf2f4d7 Import of Heimdal Kerberos from KTH repository circa 2002/09/16. 2002-09-16 21:04:40 +00:00
Jacques Vidrine
8373020d34 Import of Heimdal Kerberos from KTH repository circa 2002/08/29. 2002-08-30 21:23:27 +00:00
Jacques Vidrine
4137ff4cc1 Import of Heimdal Kerberos from KTH repository circa 2002/02/17. 2002-02-19 15:46:56 +00:00
Assar Westerlund
adb0ddaeac import of heimdal 0.3f 2001-06-21 02:12:07 +00:00
Assar Westerlund
45524cd79e mdoc(ng) fixes
Submitted by:	ru
2001-05-08 14:57:13 +00:00
Assar Westerlund
5e9cd1ae3e import of heimdal 0.3e 2001-02-13 16:46:19 +00:00
Mark Murray
13e3f4d6d9 Vendor import of Heimdal 0.2n 2000-02-24 11:07:16 +00:00
Mark Murray
b528cefc6b Import KTH Heimdal, which will be the core of our Kerberos5.
Userland to follow.
2000-01-09 20:58:00 +00:00