October 2006
Three FreeBSD Security Advisories: 1. FreeBSD i386_set_ldt Integer Signedness and Overflow Vulnerabilities 2. FreeBSD-SA-06:22.openssh 3. FreeBSD-SA-06:23.openssl - Multiple problems in crypto(3)
ID: 00669
Ref: 641/2006
Date: 02 October 2006:15:00:12
Version: 1
Title: Three FreeBSD Security Advisories: 1. FreeBSD i386_set_ldt Integer Signedness and Overflow Vulnerabilities 2. FreeBSD-SA-06:22.openssh 3. FreeBSD-SA-06:23.openssl - Multiple problems in crypto(3)
Abstract:
Vendors affected: FreeBSD
Operating systems affected: FreeBSD
Applications affected: FreeBSD
Title
=====
Three FreeBSD Security Advisories:
1. FreeBSD i386_set_ldt Integer Signedness and Overflow Vulnerabilities
2. FreeBSD-SA-06:22.openssh
3. FreeBSD-SA-06:23.openssl - Multiple problems in crypto(3)
Detail
======
1. Local exploitation of an integer signedness vulnerability in version 5.4
of FreeBSD allows attackers to create a denial of service condition.
The i386_set_ldt() call is provided to allow user-land programs to
dynamically manage the per-process local descriptor table.
2. The CRC compensation attack detector in the sshd(8) daemon, upon receipt
of duplicate blocks, uses CPU time cubic in the number of duplicate
blocks received. [CVE-2006-4924]
A race condition exists in a signal handler used by the sshd(8) daemon
to handle the LoginGraceTime option, which can potentially cause some
cleanup routines to be executed multiple times. [CVE-2006-5051]
3. Several problems have been found in OpenSSL:
1.
- -----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
===========================================================================
ESB-2006.0717 -- [FreeBSD]
FreeBSD i386_set_ldt Integer Signedness and Overflow Vulnerabilities
29 September 2006
===========================================================================
Product: FreeBSD 5.X
Publisher: iDEFENSE
Impact: Denial of Service
Access: Existing Account
CVE Names: CVE-2006-4178 CVE-2006-4172
Original Bulletin:
http://www.idefense.com/intelligence/vulnerabilities/display.php?id=415
http://www.idefense.com/intelligence/vulnerabilities/display.php?id=414
- - --------------------------BEGIN INCLUDED TEXT--------------------
FreeBSD i386_set_ldt Integer Signedness Vulnerability
iDefense Security Advisory 09.23.06
http://www.idefense.com/intelligence/vulnerabilities/
Sep 23, 2006
I. BACKGROUND
FreeBSD is a modern operating system for x86, amd64, Alpha, IA-64, PC-98
and SPARC architectures. It's based on the UNIX operating system, BSD,
which was created at the University of California, Berkeley. More
information can be obtained from the FreeBSD Project web site at
http://www.FreeBSD.org/
II. DESCRIPTION
Local exploitation of an integer signedness vulnerability in version 5.4
of FreeBSD allows attackers to create a denial of service condition.
The i386_set_ldt() call is provided to allow user-land programs to
dynamically manage the per-process local descriptor table.
Due to the use of signed integers and a lack of proper input validation,
a situation can occur in the kernel where bzero is called with a very
large size parameter. The affected code follows.
415 int error = 0, i;
416 int largest_ld;
..
449 largest_ld = uap->start + uap->num;
450 if (largest_ld > pldt->ldt_len)
451 largest_ld = pldt->ldt_len;
452 i = largest_ld - uap->start;
453 bzero(&((union descriptor
*)(pldt->ldt_base))[uap->start],
454 sizeof(union descriptor) * i);
As seen on lines 415 and 416, the 'i' and 'largest_ld' variables are
both signed integers. On line 449, uap->start and uap->num are added
together. It should be noted that both of these variables are user
controlled and are not checked properly. On line 452, 'i' can be set to
a negative value which causes the bzero on line 453 to be called with a
very large length parameter. Invalid memory access will result in a
kernel panic.
III. ANALYSIS
Exploitation of this vulnerability would result in a denial of service
condition on the affected host.
IV. DETECTION
iDefense has confirmed the existence of this problem in FreeBSD 5.5. It
is suspected that versions as early as 5.2 are also affected.
V. WORKAROUND
iDefense is not aware of any workarounds for this issue.
VI. VENDOR RESPONSE
"The policy of the FreeBSD Security Team is to not issue security
advisories for local denial of service attacks; since we have not been
able to demonstrate that this bug can result in anything more severe
than a denial of service, we will not be issuing a security advisory
relating to this problem.
It is possible that an Errata Notice will be issued concerning this
problem."
VII. CVE INFORMATION
The Common Vulnerabilities and Exposures (CVE) project has assigned the
name CVE-2006-4178 to this issue. This is a candidate for inclusion in
the CVE list (http://cve.mitre.org), which standardizes names for
security problems.
VIII. DISCLOSURE TIMELINE
08/16/2006 Initial vendor notification
08/16/2006 Initial vendor response
09/23/2006 Public disclosure
IX. CREDIT
The discoverer of this vulnerability wishes to remain anonymous.
Get paid for vulnerability research
http://www.idefense.com/methodology/vulnerability/vcp.php
Free tools, research and upcoming events
http://labs.idefense.com/
X. LEGAL NOTICES
Copyright © 2006 iDefense, Inc.
Permission is granted for the redistribution of this alert
electronically. It may not be edited in any way without the express
written consent of iDefense. If you wish to reprint the whole or any
part of this alert in any other medium other than electronically, please
email customerservice@idefense.com for permission.
Disclaimer: The information in the advisory is believed to be accurate
at the time of publishing based on currently available information. Use
of the information constitutes acceptance for use in an AS IS condition.
There are no warranties with regard to this information. Neither the
author nor the publisher accepts any liability for any direct, indirect,
or consequential loss or damage arising from use of, or reliance on,
this information.
FreeBSD i386_set_ldt Integer Overflow Vulnerability
iDefense Security Advisory 09.23.06
http://www.idefense.com/intelligence/vulnerabilities/
Sep 23, 2006
I. BACKGROUND
FreeBSD is a modern operating system for x86, amd64, Alpha, IA-64, PC-98
and SPARC architectures. It's based on the UNIX operating system, BSD,
which was created at the University of California, Berkeley. More
information can be obtained from the FreeBSD Project web site at
http://www.FreeBSD.org/
II. DESCRIPTION
Local exploitation of a input validation error in the FreeBSD Project's
i386_set_ldt() kernel implementation could allow attackers to create a
kernel panic, leading to a denial of service condition on the affected
computer.
III. ANALYSIS
Exploitation of this vulnerability would result in a denial of service
condition on the affected host. There is a potential for arbitrary code
execution in kernel context due to the way this function manipulates
kernel heap memory.
IV. DETECTION
iDefense has confirmed the existence of this problem in FreeBSD 5.5. It
is suspected that versions as early as 5.2 are also affected.
V. WORKAROUND
iDefense is not aware of any workaround for this issue.
VI. VENDOR RESPONSE
"It appears that the problem you have discovered was fixed in revision
1.96 of src/sys/i386/i386/sys_machdep.c on March 23, 2005, after being
found by the Coverity Prevent analysis tool; the commit message at the
time documented this as a local denial of service bug.
The policy of the FreeBSD Security Team is that local denial of service bugs
not be treated as security issues; it is possible that this problem will be
corrected in a future Erratum."
VII. CVE INFORMATION
The Common Vulnerabilities and Exposures (CVE) project has assigned the
name CVE-2006-4172 to this issue. This is a candidate for inclusion in
the CVE list (http://cve.mitre.org), which standardizes names for
security problems.
VIII. DISCLOSURE TIMELINE
08/16/2006 Initial vendor notification
08/16/2006 Initial vendor response
09/23/2006 Public disclosure
IX. CREDIT
The discoverer of this vulnerability wishes to remain anonymous.
Get paid for vulnerability research
http://www.idefense.com/methodology/vulnerability/vcp.php
Free tools, research and upcoming events
http://labs.idefense.com/
X. LEGAL NOTICES
Copyright © 2006 iDefense, Inc.
Permission is granted for the redistribution of this alert
electronically. It may not be edited in any way without the express
written consent of iDefense. If you wish to reprint the whole or any
part of this alert in any other medium other than electronically, please
email customerservice@idefense.com for permission.
Disclaimer: The information in the advisory is believed to be accurate
at the time of publishing based on currently available information. Use
of the information constitutes acceptance for use in an AS IS condition.
There are no warranties with regard to this information. Neither the
author nor the publisher accepts any liability for any direct, indirect,
or consequential loss or damage arising from use of, or reliance on,
this information.
- - --------------------------END INCLUDED TEXT--------------------
iQCVAwUBRRyCMyh9+71yA2DNAQLS9gP+OnLsAr+FfL8fNcT6Ftb24zpEbe2vpV85
o2fcEz0VqsehRKbFUhcP6UMeGU2LrMsLK1B6U0WxmUejiCcUb0gI4FtozkV4tcpu
3ZukxtgaUKrPl9nRAoH+oSSakUGQY6GclpbLvzFlqgIx67ZBy6pLmZcYNEM09u7V
YDFDtpEgiyI=
=Ov9Y
- -----END PGP SIGNATURE-----
2.
- -----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
=============================================================================
FreeBSD-SA-06:22.openssh Security Advisory
The FreeBSD Project
Topic: Multiple vulnerabilities in OpenSSH
Category: contrib
Module: openssh
Announced: 2006-09-30
Credits: Tavis Ormandy, Mark Dowd
Affects: All FreeBSD releases.
Corrected: 2006-09-30 19:50:57 UTC (RELENG_6, 6.2-PRERELEASE)
2006-09-30 19:51:56 UTC (RELENG_6_1, 6.1-RELEASE-p10)
2006-09-30 19:53:21 UTC (RELENG_6_0, 6.0-RELEASE-p15)
2006-09-30 19:54:03 UTC (RELENG_5, 5.5-STABLE)
2006-09-30 19:54:58 UTC (RELENG_5_5, 5.5-RELEASE-p8)
2006-09-30 19:55:52 UTC (RELENG_5_4, 5.4-RELEASE-p22)
2006-09-30 19:56:38 UTC (RELENG_5_3, 5.3-RELEASE-p37)
2006-09-30 19:57:15 UTC (RELENG_4, 4.11-STABLE)
2006-09-30 19:58:07 UTC (RELENG_4_11, 4.11-RELEASE-p25)
CVE Name: CVE-2006-4924, CVE-2006-5051
For general information regarding FreeBSD Security Advisories,
including descriptions of the fields above, security branches, and the
following sections, please visit .
I. Background
OpenSSH is an implementation of the SSH protocol suite, providing an
encrypted, authenticated transport for a variety of services,
including remote shell access.
II. Problem Description
The CRC compensation attack detector in the sshd(8) daemon, upon receipt
of duplicate blocks, uses CPU time cubic in the number of duplicate
blocks received. [CVE-2006-4924]
A race condition exists in a signal handler used by the sshd(8) daemon
to handle the LoginGraceTime option, which can potentially cause some
cleanup routines to be executed multiple times. [CVE-2006-5051]
III. Impact
An attacker sending specially crafted packets to sshd(8) can cause a
Denial of Service by using 100% of CPU time until a connection timeout
occurs. Since this attack can be performed over multiple connections
simultaneously, it is possible to cause up to MaxStartups (10 by default)
sshd processes to use all the CPU time they can obtain. [CVE-2006-4924]
The OpenSSH project believe that the race condition can lead to a Denial
of Service or potentially remote code execution, but the FreeBSD Security
Team has been unable to verify the exact impact. [CVE-2006-5051]
IV. Workaround
The attack against the CRC compensation attack detector can be avoided
by disabling SSH Protocol version 1 support in sshd_config(5).
There is no workaround for the second issue.
V. Solution
Perform one of the following:
1) Upgrade your vulnerable system to 4-STABLE, 5-STABLE, or 6-STABLE,
or to the RELENG_6_1, RELENG_6_0, RELENG_5_5, RELENG_5_4, RELENG_5_3,
or RELENG_4_11 security branch dated after the correction date.
2) To patch your present system:
The following patches have been verified to apply to FreeBSD 4.11, 5.3,
5.4, 5.5, 6.0, and 6.1 systems.
a) Download the relevant patch from the location below, and verify the
detached PGP signature using your PGP utility.
[FreeBSD 4.11]
# fetch http://security.FreeBSD.org/patches/SA-06:22/openssh4x.patch
# fetch http://security.FreeBSD.org/patches/SA-06:22/openssh4x.patch.asc
[FreeBSD 5.x]
# fetch http://security.FreeBSD.org/patches/SA-06:22/openssh5x.patch
# fetch http://security.FreeBSD.org/patches/SA-06:22/openssh5x.patch.asc
[FreeBSD 6.x]
# fetch http://security.FreeBSD.org/patches/SA-06:22/openssh6x.patch
# fetch http://security.FreeBSD.org/patches/SA-06:22/openssh6x.patch.asc
b) Execute the following commands as root:
# cd /usr/src
# patch < /path/to/patch
# cd /usr/src/secure/lib/libssh
# make obj && make depend && make && make install
# cd /usr/src/secure/usr.sbin/sshd
# make obj && make depend && make && make install
c) Restart the SSH daemon. On FreeBSD 5.x and 6.x, this can be done via
# /etc/rc.d/sshd restart
VI. Correction details
The following list contains the revision numbers of each file that was
corrected in FreeBSD.
Branch Revision
Path
- - -------------------------------------------------------------------------
RELENG_4
src/crypto/openssh/deattack.c 1.1.1.1.2.6
src/crypto/openssh/deattack.h 1.1.1.1.2.3
src/crypto/openssh/defines.h 1.1.1.2.2.3
src/crypto/openssh/log.c 1.1.1.1.2.6
src/crypto/openssh/log.h 1.1.1.1.2.4
src/crypto/openssh/packet.c 1.1.1.1.2.7
src/crypto/openssh/ssh_config 1.2.2.10
src/crypto/openssh/ssh_config.5 1.4.2.6
src/crypto/openssh/sshd.c 1.6.2.12
src/crypto/openssh/sshd_config 1.4.2.14
src/crypto/openssh/sshd_config.5 1.5.2.8
src/crypto/openssh/version.h 1.1.1.1.2.14
RELENG_4_11
src/UPDATING 1.73.2.91.2.26
src/sys/conf/newvers.sh 1.44.2.39.2.29
src/crypto/openssh/deattack.c 1.1.1.1.2.5.6.1
src/crypto/openssh/deattack.h 1.1.1.1.2.2.10.1
src/crypto/openssh/defines.h 1.1.1.2.2.2.8.1
src/crypto/openssh/log.c 1.1.1.1.2.5.8.1
src/crypto/openssh/log.h 1.1.1.1.2.3.8.1
src/crypto/openssh/packet.c 1.1.1.1.2.6.8.1
src/crypto/openssh/ssh_config 1.2.2.9.6.1
src/crypto/openssh/ssh_config.5 1.4.2.5.6.1
src/crypto/openssh/sshd.c 1.6.2.11.8.1
src/crypto/openssh/sshd_config 1.4.2.13.6.1
src/crypto/openssh/sshd_config.5 1.5.2.7.4.1
src/crypto/openssh/version.h 1.1.1.1.2.13.6.1
RELENG_5
src/crypto/openssh/auth.h 1.13.2.1
src/crypto/openssh/deattack.c 1.1.1.7.2.1
src/crypto/openssh/deattack.h 1.1.1.3.8.1
src/crypto/openssh/defines.h 1.1.1.7.2.1
src/crypto/openssh/log.c 1.1.1.10.2.1
src/crypto/openssh/log.h 1.5.2.1
src/crypto/openssh/packet.c 1.1.1.14.2.1
src/crypto/openssh/session.c 1.44.2.1
src/crypto/openssh/ssh_config 1.25.2.2
src/crypto/openssh/ssh_config.5 1.15.2.2
src/crypto/openssh/sshd.c 1.37.2.1
src/crypto/openssh/sshd_config 1.40.2.2
src/crypto/openssh/sshd_config.5 1.21.2.2
src/crypto/openssh/version.h 1.27.2.2
RELENG_5_5
src/UPDATING 1.342.2.35.2.8
src/sys/conf/newvers.sh 1.62.2.21.2.10
src/crypto/openssh/auth.h 1.13.8.1
src/crypto/openssh/deattack.c 1.1.1.7.14.1
src/crypto/openssh/deattack.h 1.1.1.3.20.1
src/crypto/openssh/defines.h 1.1.1.7.8.1
src/crypto/openssh/log.c 1.1.1.10.8.1
src/crypto/openssh/log.h 1.5.8.1
src/crypto/openssh/packet.c 1.1.1.14.8.1
src/crypto/openssh/session.c 1.44.8.1
src/crypto/openssh/ssh_config 1.25.2.1.2.1
src/crypto/openssh/ssh_config.5 1.15.2.1.2.1
src/crypto/openssh/sshd.c 1.37.8.1
src/crypto/openssh/sshd_config 1.40.2.1.2.1
src/crypto/openssh/sshd_config.5 1.21.2.1.2.1
src/crypto/openssh/version.h 1.27.2.1.2.1
RELENG_5_4
src/UPDATING 1.342.2.24.2.31
src/sys/conf/newvers.sh 1.62.2.18.2.27
src/crypto/openssh/auth.h 1.13.6.1
src/crypto/openssh/deattack.c 1.1.1.7.6.1
src/crypto/openssh/deattack.h 1.1.1.3.12.1
src/crypto/openssh/defines.h 1.1.1.7.6.1
src/crypto/openssh/log.c 1.1.1.10.6.1
src/crypto/openssh/log.h 1.5.6.1
src/crypto/openssh/packet.c 1.1.1.14.6.1
src/crypto/openssh/session.c 1.44.6.1
src/crypto/openssh/ssh_config 1.25.6.2
src/crypto/openssh/ssh_config.5 1.15.6.2
src/crypto/openssh/sshd.c 1.37.6.1
src/crypto/openssh/sshd_config 1.40.6.2
src/crypto/openssh/sshd_config.5 1.21.6.2
src/crypto/openssh/version.h 1.27.6.2
RELENG_5_3
src/UPDATING 1.342.2.13.2.40
src/sys/conf/newvers.sh 1.62.2.15.2.42
src/crypto/openssh/auth.h 1.13.4.1
src/crypto/openssh/deattack.c 1.1.1.7.4.1
src/crypto/openssh/deattack.h 1.1.1.3.10.1
src/crypto/openssh/defines.h 1.1.1.7.4.1
src/crypto/openssh/log.c 1.1.1.10.4.1
src/crypto/openssh/log.h 1.5.4.1
src/crypto/openssh/packet.c 1.1.1.14.4.1
src/crypto/openssh/session.c 1.44.4.1
src/crypto/openssh/ssh_config 1.25.4.2
src/crypto/openssh/ssh_config.5 1.15.4.2
src/crypto/openssh/sshd.c 1.37.4.1
src/crypto/openssh/sshd_config 1.40.4.2
src/crypto/openssh/sshd_config.5 1.21.4.2
src/crypto/openssh/version.h 1.27.4.2
RELENG_6
src/crypto/openssh/auth.h 1.15.2.2
src/crypto/openssh/deattack.c 1.1.1.7.8.1
src/crypto/openssh/deattack.h 1.1.1.3.14.1
src/crypto/openssh/defines.h 1.1.1.9.2.2
src/crypto/openssh/log.c 1.1.1.13.2.1
src/crypto/openssh/log.h 1.6.2.1
src/crypto/openssh/packet.c 1.1.1.16.2.2
src/crypto/openssh/session.c 1.46.2.2
src/crypto/openssh/ssh_config 1.27.2.2
src/crypto/openssh/ssh_config.5 1.17.2.2
src/crypto/openssh/sshd.c 1.39.2.2
src/crypto/openssh/sshd_config 1.42.2.2
src/crypto/openssh/sshd_config.5 1.23.2.2
src/crypto/openssh/version.h 1.30.2.2
RELENG_6_1
src/UPDATING 1.416.2.22.2.12
src/sys/conf/newvers.sh 1.69.2.11.2.12
src/crypto/openssh/auth.h 1.15.2.1.4.1
src/crypto/openssh/deattack.c 1.1.1.7.12.1
src/crypto/openssh/deattack.h 1.1.1.3.18.1
src/crypto/openssh/defines.h 1.1.1.9.2.1.4.1
src/crypto/openssh/log.c 1.1.1.13.6.1
src/crypto/openssh/log.h 1.6.6.1
src/crypto/openssh/packet.c 1.1.1.16.2.1.4.1
src/crypto/openssh/session.c 1.46.2.1.4.1
src/crypto/openssh/ssh_config 1.27.2.1.4.1
src/crypto/openssh/ssh_config.5 1.17.2.1.4.1
src/crypto/openssh/sshd.c 1.39.2.1.4.1
src/crypto/openssh/sshd_config 1.42.2.1.4.1
src/crypto/openssh/sshd_config.5 1.23.2.1.4.1
src/crypto/openssh/version.h 1.30.2.1.4.1
RELENG_6_0
src/UPDATING 1.416.2.3.2.20
src/sys/conf/newvers.sh 1.69.2.8.2.16
src/crypto/openssh/auth.h 1.15.2.1.2.1
src/crypto/openssh/deattack.c 1.1.1.7.10.1
src/crypto/openssh/deattack.h 1.1.1.3.16.1
src/crypto/openssh/defines.h 1.1.1.9.2.1.2.1
src/crypto/openssh/log.c 1.1.1.13.4.1
src/crypto/openssh/log.h 1.6.4.1
src/crypto/openssh/packet.c 1.1.1.16.2.1.2.1
src/crypto/openssh/session.c 1.46.2.1.2.1
src/crypto/openssh/ssh_config 1.27.2.1.2.1
src/crypto/openssh/ssh_config.5 1.17.2.1.2.1
src/crypto/openssh/sshd.c 1.39.2.1.2.1
src/crypto/openssh/sshd_config 1.42.2.1.2.1
src/crypto/openssh/sshd_config.5 1.23.2.1.2.1
src/crypto/openssh/version.h 1.30.2.1.2.1
- - -------------------------------------------------------------------------
VII. References
http://www.openssh.com/txt/release-4.4
http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2006-4924
http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2006-5051
The latest revision of this advisory is available at
http://security.FreeBSD.org/advisories/FreeBSD-SA-06:22.openssh.asc
- -----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (FreeBSD)
iD8DBQFFHtD+FdaIBMps37IRAhw8AJ0dNrOCiYVEmqQqePByx/KUrdi+AACeNcB0
T5VfZGGXDv31Py3yxejjhlw=
=f1ch
- -----END PGP SIGNATURE-----
3.
- -----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
=============================================================================
FreeBSD-SA-06:23.openssl Security Advisory
The FreeBSD Project
Topic: Multiple problems in crypto(3)
Category: contrib
Module: openssl
Announced: 2006-09-28
Credits: Dr S N Henson, Tavis Ormandy, Will Drewry
Stephen Kiernan (Juniper SIRT)
Affects: All FreeBSD releases.
Corrected: 2006-09-29 13:44:03 UTC (RELENG_6, 6.2-PRERELEASE)
2006-09-29 13:44:31 UTC (RELENG_6_1, 6.1-RELEASE-p9)
2006-09-29 13:44:45 UTC (RELENG_6_0, 6.0-RELEASE-p14)
2006-09-29 13:45:01 UTC (RELENG_5, 5.5-STABLE)
2006-09-29 13:45:43 UTC (RELENG_5_5, 5.5-RELEASE-p7)
2006-09-29 13:45:59 UTC (RELENG_5_4, 5.4-RELEASE-p21)
2006-09-29 13:46:10 UTC (RELENG_5_3, 5.3-RELEASE-p36)
2006-09-29 13:46:23 UTC (RELENG_4, 4.11-STABLE)
2006-09-29 13:46:41 UTC (RELENG_4_11, 4.11-RELEASE-p24)
CVE Name: CVE-2006-2937, CVE-2006-2940, CVE-2006-3738, CVE-2006-4343
For general information regarding FreeBSD Security Advisories,
including descriptions of the fields above, security branches, and the
following sections, please visit .
0. Revision History
v1.0 2006-09-28 Initial release.
v1.1 2006-09-29 Corrected patch.
I. Background
FreeBSD includes software from the OpenSSL Project. The OpenSSL Project is
a collaborative effort to develop a robust, commercial-grade, full-featured,
and Open Source toolkit implementing the Secure Sockets Layer (SSL v2/v3)
and Transport Layer Security (TLS v1) protocols as well as a full-strength
general purpose cryptography library.
II. Problem Description
Several problems have been found in OpenSSL:
1. During the parsing of certain invalid ASN1 structures an error condition
is mishandled, possibly resulting in an infinite loop. [CVE-2006-2937]
2. A buffer overflow exists in the SSL_get_shared_ciphers function.
[CVE-2006-3738]
3. A NULL pointer may be dereferenced in the SSL version 2 client code.
[CVE-2006-4343]
In addition, many applications using OpenSSL do not perform any validation
of the lengths of public keys being used. [CVE-2006-2940]
III. Impact
Servers which parse ASN1 data from untrusted sources may be vulnerable to
a denial of service attack. [CVE-2006-2937]
An attacker accessing a server which uses SSL version 2 may be able to
execute arbitrary code with the privileges of that server. [CVE-2006-3738]
A malicious SSL server can cause clients connecting using SSL version 2 to
crash. [CVE-2006-4343]
Applications which perform public key operations using untrusted keys may
be vulnerable to a denial of service attack. [CVE-2006-2940]
IV. Workaround
No workaround is available, but not all of the vulnerabilities mentioned
affect all applications.
V. Solution
Perform one of the following:
1) Upgrade your vulnerable system to 4-STABLE, 5-STABLE, or 6-STABLE,
or to the RELENG_6_1, RELENG_6_0, RELENG_5_5, RELENG_5_4, RELENG_5_3,
or RELENG_4_11 security branch dated after the correction date.
2) To patch your present system:
The following patch has been verified to apply to FreeBSD 4.11, 5.3,
5.4, 5.5, 6.0, and 6.1 systems.
a) Download the patch from the location below, and verify the detached
PGP signature using your PGP utility.
# fetch http://security.FreeBSD.org/patches/SA-06:23/openssl.patch
# fetch http://security.FreeBSD.org/patches/SA-06:23/openssl.patch.asc
NOTE: The patch distributed at the time of the original advisory was
incorrect. Systems to which the original patch was applied should be
patched with the following corrective patch, which contains only the
changes between the original and updated patch:
# fetch http://security.FreeBSD.org/patches/SA-06:23/openssl-correction.patch
# fetch http://security.FreeBSD.org/patches/SA-06:23/openssl-correction.patch.asc
b) Execute the following commands as root:
# cd /usr/src
# patch < /path/to/patch
c) Recompile the operating system as described in
and reboot the
system.
NOTE: Any third-party applications, including those installed from the
FreeBSD ports collection, which are statically linked to libcrypto(3)
should be recompiled in order to use the corrected code.
NOTE ALSO: The above patch reduces the functionality of libcrypto(3) by
prohibiting the use of exceptionally large public keys. It is believed
that no existing applications legitimately use such key lengths as would
be affected by this change.
VI. Correction details
The following list contains the revision numbers of each file that was
corrected in FreeBSD.
Branch Revision
Path
- - -------------------------------------------------------------------------
RELENG_4
src/crypto/openssl/crypto/asn1/tasn_dec.c 1.1.1.1.2.3
src/crypto/openssl/crypto/dh/dh.h 1.1.1.1.2.5
src/crypto/openssl/crypto/dh/dh_err.c 1.1.1.1.2.4
src/crypto/openssl/crypto/dh/dh_key.c 1.1.1.1.2.9
src/crypto/openssl/crypto/dsa/dsa.h 1.1.1.1.2.5
src/crypto/openssl/crypto/dsa/dsa_err.c 1.1.1.1.2.4
src/crypto/openssl/crypto/dsa/dsa_ossl.c 1.1.1.1.2.8
src/crypto/openssl/crypto/rsa/rsa.h 1.2.2.9
src/crypto/openssl/crypto/rsa/rsa_eay.c 1.2.4.9
src/crypto/openssl/crypto/rsa/rsa_err.c 1.1.1.1.2.4
src/crypto/openssl/ssl/s2_clnt.c 1.2.2.9
src/crypto/openssl/ssl/s3_srvr.c 1.1.1.1.2.10
src/crypto/openssl/ssl/ssl_lib.c 1.1.1.1.2.9
RELENG_4_11
src/UPDATING 1.73.2.91.2.25
src/sys/conf/newvers.sh 1.44.2.39.2.28
src/crypto/openssl/crypto/asn1/tasn_dec.c 1.1.1.1.2.2.6.1
src/crypto/openssl/crypto/dh/dh.h 1.1.1.1.2.4.8.1
src/crypto/openssl/crypto/dh/dh_err.c 1.1.1.1.2.3.8.1
src/crypto/openssl/crypto/dh/dh_key.c 1.1.1.1.2.7.6.2
src/crypto/openssl/crypto/dsa/dsa.h 1.1.1.1.2.4.8.1
src/crypto/openssl/crypto/dsa/dsa_err.c 1.1.1.1.2.3.8.1
src/crypto/openssl/crypto/dsa/dsa_ossl.c 1.1.1.1.2.7.6.1
src/crypto/openssl/crypto/rsa/rsa.h 1.2.2.8.4.1
src/crypto/openssl/crypto/rsa/rsa_eay.c 1.2.4.8.4.1
src/crypto/openssl/crypto/rsa/rsa_err.c 1.1.1.1.2.3.8.1
src/crypto/openssl/ssl/s2_clnt.c 1.2.2.8.4.1
src/crypto/openssl/ssl/s3_srvr.c 1.1.1.1.2.9.4.1
src/crypto/openssl/ssl/ssl_lib.c 1.1.1.1.2.8.4.1
RELENG_5
src/crypto/openssl/crypto/asn1/tasn_dec.c 1.1.1.2.4.1
src/crypto/openssl/crypto/dh/dh.h 1.1.1.6.6.1
src/crypto/openssl/crypto/dh/dh_err.c 1.1.1.4.6.2
src/crypto/openssl/crypto/dh/dh_key.c 1.1.1.8.4.3
src/crypto/openssl/crypto/dsa/dsa.h 1.1.1.6.6.2
src/crypto/openssl/crypto/dsa/dsa_err.c 1.1.1.4.6.1
src/crypto/openssl/crypto/dsa/dsa_ossl.c 1.1.1.7.4.2
src/crypto/openssl/crypto/rsa/rsa.h 1.10.4.2
src/crypto/openssl/crypto/rsa/rsa_eay.c 1.12.4.2
src/crypto/openssl/crypto/rsa/rsa_err.c 1.1.1.4.6.1
src/crypto/openssl/ssl/s2_clnt.c 1.12.2.2
src/crypto/openssl/ssl/s3_srvr.c 1.1.1.13.2.2
src/crypto/openssl/ssl/ssl_lib.c 1.1.1.11.2.2
RELENG_5_5
src/UPDATING 1.342.2.35.2.7
src/sys/conf/newvers.sh 1.62.2.21.2.9
src/crypto/openssl/crypto/asn1/tasn_dec.c 1.1.1.2.16.1
src/crypto/openssl/crypto/dh/dh.h 1.1.1.6.18.1
src/crypto/openssl/crypto/dh/dh_err.c 1.1.1.4.6.1.4.1
src/crypto/openssl/crypto/dh/dh_key.c 1.1.1.8.4.1.4.2
src/crypto/openssl/crypto/dsa/dsa.h 1.1.1.6.6.1.4.1
src/crypto/openssl/crypto/dsa/dsa_err.c 1.1.1.4.18.1
src/crypto/openssl/crypto/dsa/dsa_ossl.c 1.1.1.7.4.1.4.1
src/crypto/openssl/crypto/rsa/rsa.h 1.10.4.1.4.1
src/crypto/openssl/crypto/rsa/rsa_eay.c 1.12.4.1.4.1
src/crypto/openssl/crypto/rsa/rsa_err.c 1.1.1.4.18.1
src/crypto/openssl/ssl/s2_clnt.c 1.12.2.1.4.1
src/crypto/openssl/ssl/s3_srvr.c 1.1.1.13.2.1.4.1
src/crypto/openssl/ssl/ssl_lib.c 1.1.1.11.2.1.4.1
RELENG_5_4
src/UPDATING 1.342.2.24.2.30
src/sys/conf/newvers.sh 1.62.2.18.2.26
src/crypto/openssl/crypto/asn1/tasn_dec.c 1.1.1.2.8.1
src/crypto/openssl/crypto/dh/dh.h 1.1.1.6.10.1
src/crypto/openssl/crypto/dh/dh_err.c 1.1.1.4.6.1.2.1
src/crypto/openssl/crypto/dh/dh_key.c 1.1.1.8.4.1.2.2
src/crypto/openssl/crypto/dsa/dsa.h 1.1.1.6.6.1.2.1
src/crypto/openssl/crypto/dsa/dsa_err.c 1.1.1.4.10.1
src/crypto/openssl/crypto/dsa/dsa_ossl.c 1.1.1.7.4.1.2.1
src/crypto/openssl/crypto/rsa/rsa.h 1.10.4.1.2.1
src/crypto/openssl/crypto/rsa/rsa_eay.c 1.12.4.1.2.1
src/crypto/openssl/crypto/rsa/rsa_err.c 1.1.1.4.10.1
src/crypto/openssl/ssl/s2_clnt.c 1.12.2.1.2.1
src/crypto/openssl/ssl/s3_srvr.c 1.1.1.13.2.1.2.1
src/crypto/openssl/ssl/ssl_lib.c 1.1.1.11.2.1.2.1
RELENG_5_3
src/UPDATING 1.342.2.13.2.39
src/sys/conf/newvers.sh 1.62.2.15.2.41
src/crypto/openssl/crypto/asn1/tasn_dec.c 1.1.1.2.6.1
src/crypto/openssl/crypto/dh/dh.h 1.1.1.6.8.1
src/crypto/openssl/crypto/dh/dh_err.c 1.1.1.4.8.1
src/crypto/openssl/crypto/dh/dh_key.c 1.1.1.8.6.2
src/crypto/openssl/crypto/dsa/dsa.h 1.1.1.6.8.1
src/crypto/openssl/crypto/dsa/dsa_err.c 1.1.1.4.8.1
src/crypto/openssl/crypto/dsa/dsa_ossl.c 1.1.1.7.6.1
src/crypto/openssl/crypto/rsa/rsa.h 1.10.6.1
src/crypto/openssl/crypto/rsa/rsa_eay.c 1.12.6.1
src/crypto/openssl/crypto/rsa/rsa_err.c 1.1.1.4.8.1
src/crypto/openssl/ssl/s2_clnt.c 1.12.4.1
src/crypto/openssl/ssl/s3_srvr.c 1.1.1.13.4.1
src/crypto/openssl/ssl/ssl_lib.c 1.1.1.11.4.1
RELENG_6
src/crypto/openssl/crypto/asn1/tasn_dec.c 1.1.1.2.10.1
src/crypto/openssl/crypto/dh/dh.h 1.1.1.6.12.1
src/crypto/openssl/crypto/dh/dh_err.c 1.1.1.5.2.1
src/crypto/openssl/crypto/dh/dh_key.c 1.1.1.9.2.2
src/crypto/openssl/crypto/dsa/dsa.h 1.1.1.7.2.1
src/crypto/openssl/crypto/dsa/dsa_err.c 1.1.1.4.12.1
src/crypto/openssl/crypto/dsa/dsa_ossl.c 1.1.1.8.2.1
src/crypto/openssl/crypto/rsa/rsa.h 1.11.2.1
src/crypto/openssl/crypto/rsa/rsa_eay.c 1.13.2.1
src/crypto/openssl/crypto/rsa/rsa_err.c 1.1.1.4.12.1
src/crypto/openssl/ssl/s2_clnt.c 1.13.2.1
src/crypto/openssl/ssl/s3_srvr.c 1.1.1.14.2.1
src/crypto/openssl/ssl/ssl_lib.c 1.1.1.12.2.1
RELENG_6_1
src/UPDATING 1.416.2.22.2.11
src/sys/conf/newvers.sh 1.69.2.11.2.11
src/crypto/openssl/crypto/asn1/tasn_dec.c 1.1.1.2.14.1
src/crypto/openssl/crypto/dh/dh.h 1.1.1.6.16.1
src/crypto/openssl/crypto/dh/dh_err.c 1.1.1.5.6.1
src/crypto/openssl/crypto/dh/dh_key.c 1.1.1.9.6.2
src/crypto/openssl/crypto/dsa/dsa.h 1.1.1.7.6.1
src/crypto/openssl/crypto/dsa/dsa_err.c 1.1.1.4.16.1
src/crypto/openssl/crypto/dsa/dsa_ossl.c 1.1.1.8.6.1
src/crypto/openssl/crypto/rsa/rsa.h 1.11.6.1
src/crypto/openssl/crypto/rsa/rsa_eay.c 1.13.6.1
src/crypto/openssl/crypto/rsa/rsa_err.c 1.1.1.4.16.1
src/crypto/openssl/ssl/s2_clnt.c 1.13.6.1
src/crypto/openssl/ssl/s3_srvr.c 1.1.1.14.6.1
src/crypto/openssl/ssl/ssl_lib.c 1.1.1.12.6.1
RELENG_6_0
src/UPDATING 1.416.2.3.2.19
src/sys/conf/newvers.sh 1.69.2.8.2.15
src/crypto/openssl/crypto/asn1/tasn_dec.c 1.1.1.2.12.1
src/crypto/openssl/crypto/dh/dh.h 1.1.1.6.14.1
src/crypto/openssl/crypto/dh/dh_err.c 1.1.1.5.4.1
src/crypto/openssl/crypto/dh/dh_key.c 1.1.1.9.4.2
src/crypto/openssl/crypto/dsa/dsa.h 1.1.1.7.4.1
src/crypto/openssl/crypto/dsa/dsa_err.c 1.1.1.4.14.1
src/crypto/openssl/crypto/dsa/dsa_ossl.c 1.1.1.8.4.1
src/crypto/openssl/crypto/rsa/rsa.h 1.11.4.1
src/crypto/openssl/crypto/rsa/rsa_eay.c 1.13.4.1
src/crypto/openssl/crypto/rsa/rsa_err.c 1.1.1.4.14.1
src/crypto/openssl/ssl/s2_clnt.c 1.13.4.1
src/crypto/openssl/ssl/s3_srvr.c 1.1.1.14.4.1
src/crypto/openssl/ssl/ssl_lib.c 1.1.1.12.4.1
- - -------------------------------------------------------------------------
VII. References
http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2006-2937
http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2006-2940
http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2006-3738
http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2006-4343
The latest revision of this advisory is available at
http://security.FreeBSD.org/advisories/FreeBSD-SA-06:23.openssl.asc
- -----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.3 (FreeBSD)
iD8DBQFFHSVwFdaIBMps37IRApTZAJ9YY6pldJ52FwtYHbMxsW5363NUgwCgl4tb
3jFuSkTKR6xVJ6ui4POBjkI=
=Bn+e
- -----END PGP SIGNATURE-----