Bug 770325 (CVE-2011-4862) - CVE-2011-4862 krb5: telnet client and server encrypt_keyid heap-based buffer overflow
Summary: CVE-2011-4862 krb5: telnet client and server encrypt_keyid heap-based buffer ...
Keywords:
Status: CLOSED ERRATA
Alias: CVE-2011-4862
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
urgent
urgent
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
URL:
Whiteboard: impact=critical,public=20111225,repor...
Depends On: 770348 770349 770350 770351 770352 770518 770519 770527 770528 770529 770794 844271
Blocks: 770326
TreeView+ depends on / blocked
 
Reported: 2011-12-26 02:45 UTC by Huzaifa S. Sidhpurwala
Modified: 2019-06-08 18:59 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-02-22 16:54:58 UTC


Attachments (Terms of Use)
FreeBSD patch from FreeBSD-SA-11:08.telnetd (851 bytes, patch)
2011-12-26 03:21 UTC, Huzaifa S. Sidhpurwala
no flags Details | Diff
Patch backport to rhel-6/fedora (484 bytes, patch)
2011-12-26 06:27 UTC, Huzaifa S. Sidhpurwala
no flags Details | Diff
rhel-4/rhel-5 straight backport (479 bytes, patch)
2011-12-26 07:03 UTC, Huzaifa S. Sidhpurwala
no flags Details | Diff


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2011:1851 normal SHIPPED_LIVE Critical: krb5 security update 2011-12-27 21:14:05 UTC
Red Hat Product Errata RHSA-2011:1852 normal SHIPPED_LIVE Critical: krb5-appl security update 2011-12-27 21:25:55 UTC
Red Hat Product Errata RHSA-2011:1853 normal SHIPPED_LIVE Critical: krb5 security update 2011-12-29 00:10:40 UTC
Red Hat Product Errata RHSA-2011:1854 normal SHIPPED_LIVE Critical: krb5-appl security update 2011-12-29 00:10:32 UTC

Description Huzaifa S. Sidhpurwala 2011-12-26 02:45:58 UTC
Florian Weimer reports:

A pre-authentication buffer overflow in telnetd recently fixed by FreeBSD is not BSD-specific.  It seems to have been added at MIT when the BSD telnetd was Kerberized, and it ended up in the Heimdal recryptofication of Kerberos (from where FreeBSD got it) and later in GNU inetutils.

Reference:
http://seclists.org/oss-sec/2011/q4/556
http://security.freebsd.org/advisories/FreeBSD-SA-11:08.telnetd.asc
http://web.mit.edu/kerberos/advisories/MITKRB5-SA-2011-008.txt
http://www.debian.org/security/2011/dsa-2375
http://thexploit.com/secdev/a-textbook-buffer-overflow-a-look-at-the-freebsd-telnetd-code/

Note:
Since same encryption code is shared between the MIT krb5 telnet daemon and the
telnet client, this issue affects the telnet client as well.

Comment 1 Huzaifa S. Sidhpurwala 2011-12-26 03:21:52 UTC
Created attachment 549530 [details]
FreeBSD patch from FreeBSD-SA-11:08.telnetd

Source: http://security.freebsd.org/patches/SA-11:08/telnetd.patch

Comment 4 Huzaifa S. Sidhpurwala 2011-12-26 06:27:49 UTC
Created attachment 549549 [details]
Patch backport to rhel-6/fedora

Comment 5 Huzaifa S. Sidhpurwala 2011-12-26 07:03:34 UTC
Created attachment 549550 [details]
rhel-4/rhel-5 straight backport

Comment 8 Huzaifa S. Sidhpurwala 2011-12-26 09:47:32 UTC
This issue affects the version of krb5-appl shipped with Red Hat Enterprise Linux 4, 5 and 6.

This issue affects the version of krb5-appl shipped with Fedora release 15 and 16.

Red Hat Enterprise Linux also ships netkit-telnet, this package is not affected by this issue.

Comment 12 Mark J. Cox 2011-12-27 08:21:19 UTC
Note that the krb5 telnet daemon is not enabled by default in any version of Red Hat Enterprise Linux. In addition, the default firewall rules block remote access to the telnet port. This flaw does not affect the telnet daemon distributed in the telnet-server package. 

The krb5 telnet daemon is an xinetd service. You can determine if krb5 telnetd is enabled with the commands: 

/sbin/chkconfig --list krb5-telnet 
/sbin/chkconfig --list ekrb5-telnet 

The output of this command will be "krb5-telnet on" or "ekrb5-telnet on" if krb5 telnet is enabled. krb5 telnet daemon can be immediately disabled with the commands: 

/sbin/chkconfig krb5-telnet off
/sbin/chkconfig ekrb5-telnet off

While we are aware of public exploits for this issue, we are not aware of any yet which would be successful in gaining arbitrary root code execution in Red Hat Enterprise Linux.  However it is plausible that one could be created to do so.  For users who have enabled the krb5 telnet daemon and have it accessible remotely, they should disable it until we provide updated packages to correct this flaw.

Comment 15 Mark J. Cox 2011-12-27 09:41:02 UTC
Statement:

A buffer overflow flaw was found in the MIT krb5 telnet daemon (telnetd) as shipped with all supported versions of Red Hat Enterprise Linux. A remote attacker who can access the telnet port of a target machine could use this flaw to execute arbitrary code as root.

While we are aware of public exploits for this issue that include targets for Red Hat Enterprise Linux 3, we are not aware of any yet which would be successful in gaining arbitrary root code execution in Red Hat Enterprise Linux 4, 5, or 6.  However it is plausible that one could be created to do so.

Note that the krb5 telnet daemon is not enabled by default in any version of Red Hat Enterprise Linux. In addition, the default firewall rules block remote access to the telnet port. This flaw does not affect the telnet daemon distributed in the telnet-server package.

For users who have enabled the krb5 telnet daemon and have it accessible remotely, they should disable it or apply the updates we have released.

Since same encryption code is shared between the MIT krb5 telnet daemon and the telnet client, this issue affects the telnet client as well. The updates we have released fixes the issue for both, the telnet daemon and the telnet client.

Comment 16 errata-xmlrpc 2011-12-27 16:16:38 UTC
This issue has been addressed in following products:

  Red Hat Enterprise Linux 5
  Red Hat Enterprise Linux 4

Via RHSA-2011:1851 https://rhn.redhat.com/errata/RHSA-2011-1851.html

Comment 17 errata-xmlrpc 2011-12-27 16:27:38 UTC
This issue has been addressed in following products:

  Red Hat Enterprise Linux 6

Via RHSA-2011:1852 https://rhn.redhat.com/errata/RHSA-2011-1852.html

Comment 23 errata-xmlrpc 2011-12-28 19:11:33 UTC
This issue has been addressed in following products:

  Red Hat Enterprise Linux 6.0.Z - Server Only
  Red Hat Enterprise Linux 6.1.Z - Server Only

Via RHSA-2011:1854 https://rhn.redhat.com/errata/RHSA-2011-1854.html

Comment 24 errata-xmlrpc 2011-12-28 19:11:41 UTC
This issue has been addressed in following products:

  Red Hat Enterprise Linux 3 Extended Lifecycle Support
  Red Hat Enterprise Linux 5.3 Long Life
  Red Hat Enterprise Linux 5.6.Z - Server Only

Via RHSA-2011:1853 https://rhn.redhat.com/errata/RHSA-2011-1853.html

Comment 34 Fedora Update System 2012-01-05 20:57:20 UTC
krb5-appl-1.0.1-8.fc15 has been pushed to the Fedora 15 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 35 Fedora Update System 2012-01-05 21:02:56 UTC
krb5-appl-1.0.2-2.fc16 has been pushed to the Fedora 16 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.