copyright | disclaimer | privacy | contact  
Australia's Leading Computer Emergency Response Team
 
Search this site

 
On this site

 > HOME
 > About AusCERT
 > Membership
 > Contact Us
 > PKI Services
 > Publications
 > Sec. Bulletins
 > Conferences
 > News & Media
 > Services
 > Web Log
 > Site Map
 > Site Help
 > Member login





 

ESB-2012.0507 - [UNIX/Linux][FreeBSD] crypt: Reduced security - Remote/unauthenticated

Date: 31 May 2012
References: ESB-2012.0527  ESB-2012.0654  

Click here for printable version
Click here for PGP verifiable version
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

===========================================================================
             AUSCERT External Security Bulletin Redistribution

                               ESB-2012.0507
                         Incorrect crypt() hashing
                                31 May 2012

===========================================================================

        AusCERT Security Bulletin Summary
        ---------------------------------

Product:           crypt
Publisher:         FreeBSD
Operating System:  FreeBSD
                   UNIX variants (UNIX, Linux, OSX)
Impact/Access:     Reduced Security -- Remote/Unauthenticated
Resolution:        Patch/Upgrade
CVE Names:         CVE-2012-2143  

Original Bulletin: 
   ftp://ftp.freebsd.org/pub/FreeBSD/CERT/advisories/FreeBSD-SA-12:02.crypt.asc

Comment: This advisory references vulnerabilities in products which run on 
         platforms other than FreeBSD. It is recommended that administrators
         running crypt check for an updated version of this library for their
         operating system or consider a stronger encryption implementation, if 
         available.

- --------------------------BEGIN INCLUDED TEXT--------------------

- -----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

=============================================================================
FreeBSD-SA-12:02.crypt                                      Security Advisory
                                                          The FreeBSD Project

Topic:          Incorrect crypt() hashing

Category:       core
Module:         libcrypt
Announced:      2012-05-30
Credits:        Rubin Xu, Joseph Bonneau, Donting Yu
Affects:        All supported versions of FreeBSD.
Corrected:      2012-05-30 12:01:28 UTC (RELENG_7, 7.4-STABLE)
                2012-05-30 12:01:28 UTC (RELENG_7_4, 7.4-RELEASE-p8)
                2012-05-30 12:01:28 UTC (RELENG_8, 8.3-STABLE)
                2012-05-30 12:01:28 UTC (RELENG_8_3, 8.3-RELEASE-p2)
                2012-05-30 12:01:28 UTC (RELENG_8_2, 8.2-RELEASE-p8)
                2012-05-30 12:01:28 UTC (RELENG_8_1, 8.1-RELEASE-p10)
                2012-05-30 12:01:28 UTC (RELENG_9, 9.0-STABLE)
                2012-05-30 12:01:28 UTC (RELENG_9_0, 9.0-RELEASE-p2)
CVE Name:       CVE-2012-2143

For general information regarding FreeBSD Security Advisories,
including descriptions of the fields above, security branches, and the
following sections, please visit <URL:http://security.FreeBSD.org/>.

I.   Background

The crypt(3) function performs password hashing with additional code added
to deter key search attempts.

II.  Problem Description

There is a programming error in the DES implementation used in crypt()
when handling input which contains characters that can not be represented
with 7-bit ASCII.

III. Impact

When the input contains characters with only the most significant bit set
(0x80), that character and all characters after it will be ignored.

IV.  Workaround

No workaround is available, but systems not using crypt(), or which only
use it to handle 7-bit ASCII are not vulnerable.  Note that, because
DES does not have the computational complexity to defeat brute force
search on modern computers, it is not recommended for new applications.

V.   Solution

Perform one of the following:

1) Upgrade your vulnerable system to 7-STABLE, 8-STABLE, or 9-STABLE,
or to the RELENG_7_4, RELENG_8_3, RELENG_8_2, RELENG_8_1, or RELENG_9_0
security branch dated after the correction date.

2) To update your vulnerable system via a source code patch:

The following patches have been verified to apply to FreeBSD 7.4,
8.3, 8.2, 8.1 and 9.0 systems.

a) Download the relevant patch from the location below, and verify the
detached PGP signature using your PGP utility.

# fetch http://security.FreeBSD.org/patches/SA-12:02/crypt.patch
# fetch http://security.FreeBSD.org/patches/SA-12:02/crypt.patch.asc

# cd /usr/src
# patch < /path/to/patch
# cd /usr/src/lib/libcrypt
# make obj && make depend && make && make install

NOTE: On the amd64 platform, the above procedure will not update the
lib32 (i386 compatibility) libraries.  On amd64 systems where the i386
compatibility libraries are used, the operating system should instead
be recompiled as described in
<URL:http://www.FreeBSD.org/handbook/makeworld.html>

3) To update your vulnerable system via a binary patch:

Systems running 7.4-RELEASE, 8.3-RELEASE, 8.2-RELEASE, 8.1-RELEASE,
or 9.0-RELEASE on the i386 or amd64 platforms can be updated via the
freebsd-update(8) utility:

# freebsd-update fetch
# freebsd-update install

VI.  Correction details

The following list contains the revision numbers of each file that was
corrected in FreeBSD.

CVS:

Branch                                                           Revision
  Path
- - -------------------------------------------------------------------------
RELENG_7
  src/secure/lib/libcrypt/crypt-des.c                           1.16.24.1
RELENG_7_4
  src/UPDATING                                            1.507.2.36.2.10
  src/sys/conf/newvers.sh                                  1.72.2.18.2.13
  src/secure/lib/libcrypt/crypt-des.c                           1.16.40.2
RELENG_8
  src/secure/lib/libcrypt/crypt-des.c                           1.16.36.2
RELENG_8_3
  src/UPDATING                                             1.632.2.26.2.4
  src/sys/conf/newvers.sh                                   1.83.2.15.2.6
  src/secure/lib/libcrypt/crypt-des.c                       1.16.36.1.8.2
RELENG_8_2
  src/UPDATING                                            1.632.2.19.2.10
  src/sys/conf/newvers.sh                                  1.83.2.12.2.13
  src/secure/lib/libcrypt/crypt-des.c                       1.16.36.1.6.2
RELENG_8_1
  src/UPDATING                                            1.632.2.14.2.13
  src/sys/conf/newvers.sh                                  1.83.2.10.2.14
  src/secure/lib/libcrypt/crypt-des.c                       1.16.36.1.4.2
RELENG_9
  src/secure/lib/libcrypt/crypt-des.c                           1.16.42.2
RELENG_9_0
  src/UPDATING                                              1.702.2.4.2.4
  src/sys/conf/newvers.sh                                    1.95.2.4.2.6
  src/secure/lib/libcrypt/crypt-des.c                       1.16.42.1.2.2
- - -------------------------------------------------------------------------

Subversion:

Branch/path                                                      Revision
- - -------------------------------------------------------------------------
stable/7/                                                         r236304
releng/7.4/                                                       r236304
stable/8/                                                         r236304
releng/8.3/                                                       r236304
releng/8.2/                                                       r236304
releng/8.1/                                                       r236304
stable/9/                                                         r236304
releng/9.0/                                                       r236304
- - -------------------------------------------------------------------------

VII. References

http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2012-2143

The latest revision of this advisory is available at
http://security.FreeBSD.org/advisories/FreeBSD-SA-12:02.crypt.asc
- -----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (FreeBSD)

iEYEARECAAYFAk/GEsoACgkQFdaIBMps37JSYQCfZGZceQY4D53qgR9JbI79ZNht
/GIAnjnhxlCnF27cWOhqxkkTWM6f45IM
=7CVu
- -----END PGP SIGNATURE-----

- --------------------------END INCLUDED TEXT--------------------

You have received this e-mail bulletin as a result of your organisation's
registration with AusCERT. The mailing list you are subscribed to is
maintained within your organisation, so if you do not wish to continue
receiving these bulletins you should contact your local IT manager. If
you do not know who that is, please send an email to auscert@auscert.org.au
and we will forward your request to the appropriate person.

NOTE: Third Party Rights
This security bulletin is provided as a service to AusCERT's members.  As
AusCERT did not write the document quoted above, AusCERT has had no control
over its content. The decision to follow or act on information or advice
contained in this security bulletin is the responsibility of each user or
organisation, and should be considered in accordance with your organisation's
site policies and procedures. AusCERT takes no responsibility for consequences
which may arise from following or acting on information or advice contained in
this security bulletin.

NOTE: This is only the original release of the security bulletin.  It may
not be updated when updates to the original are made.  If downloading at
a later date, it is recommended that the bulletin is retrieved directly
from the author's website to ensure that the information is still current.

Contact information for the authors of the original document is included
in the Security Bulletin above.  If you have any questions or need further
information, please contact them directly.

Previous advisories and external security bulletins can be retrieved from:

        http://www.auscert.org.au/render.html?cid=1980

===========================================================================
Australian Computer Emergency Response Team
The University of Queensland
Brisbane
Qld 4072

Internet Email: auscert@auscert.org.au
Facsimile:      (07) 3365 7031
Telephone:      (07) 3365 4417 (International: +61 7 3365 4417)
                AusCERT personnel answer during Queensland business hours
                which are GMT+10:00 (AEST).
                On call after hours for member emergencies only.
===========================================================================
-----BEGIN PGP SIGNATURE-----
Comment: http://www.auscert.org.au/render.html?it=1967

iQIVAwUBT8bmqe4yVqjM2NGpAQK23Q//Uawb2BAdQhwBuDN1f7ce6Tc7GILGKzFE
tWXoBPvg3aq8oLhYvZ8MBMgXw7wdhDExmpiKOk7o4D/XdAlCNaXx1zoOtZMqyf6s
E3CoWsoaWSieVzALPt+JCZLyIt/uyZ7QSaIOPy0igbwCkKzETY2A41FLlc9tOkDM
C8h7LF/w80/4Zcmv29eIKdNzF6fKl+FnTmasxE8MikjUXF+KX1YEJYXQNPiqs79v
X0y3pe3IHFofKbG0EGqBizTH1DXFn/prYmgy5ie6tUNjxEf05xxl0R0mpgoTJJD7
YMpzFuSx8NmHWYfd+kMizCiNkADLozf66B8pV9QYzkxGPSj+w5uNPXsP7AMWpPkF
7xsx1N5qPWIg9LX2M9anNSyH7ux7gHXFr8SfU2L5hUOcEJI5R9wJgyFsHYSKwfcz
qlCsykAOQKNojZPzKedTHSQo24uHk5vUEVKPm7roZQC2OjE2MMmTcKpNmyBemEHs
pbhzKw5btwdz8J3IlbXBIfo/eJoAKXDYNERd19TbmUZX/rImHzdKIKwftNM8jNNK
WsNd85qwKPZk8gbVygkkF782LhfQhea93QZci6Pcw98uO0DoAPpZDfQQcGwzOrsL
o825Iesi8Cbs0UVo2lXkxukDEXwH501SF8qMHWRTeRwOwiz+rYvAeYoHRqGa49QF
srZ4OKV6fAY=
=SoYX
-----END PGP SIGNATURE-----