Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <af82afa7-24f3-4b8a-b90a-e0446ded252b@oracle.com>
Date: Thu, 6 Feb 2025 10:06:33 -0800
From: Alan Coopersmith <alan.coopersmith@...cle.com>
To: oss-security@...ts.openwall.com
Subject: Fwd: libtasn1-4.20.0 released [fixes CVE-2024-12133]

At the very bottom of the message below, you will find that this release
includes a fix for:

- Fix CVE-2024-12133: Potential DoS in handling of numerous SEQUENCE OF or SET OF elements

The CVE record is not yet published, but a writeup appears to be available at:
https://gitlab.com/gnutls/libtasn1/-/blob/master/doc/security/CVE-2024-12133.md?ref_type=heads

It says:

==================================================================
CVE-2024-12133: Potential DoS in handling of numerous SEQUENCE OF or SET OF elements
==================================================================
When an input DER data contains a large number of SEQUENCE OF or SET
OF elements, decoding the data and searching a specific element in it
take quadratic time to complete. This could be utilized for a remote
DoS attack by presenting a crafted certificate to the network peer.
Severity: Moderate
Vulnerable versions : All released version of libtasn1
Not vulnerable      : libtasn1 4.20.0

Vulnerability information
=========================
The issue is twofold: decoding a DER input with sequences and locating
a specific element in a sequence. Even though a DER sequence is
conceptually an array, in libtasn1 it is represented as a linked list,
whose elements are assigned a string name, such as "?1". Therefore a
simple lookup of an element at a given position is linear O(N) time
complexity. When decoding a DER sequence, in each step libtasn1 looks
up the parent node, recorded on the first element, which requires a
backward linear search, resulting in O(N^2) time complexity.
For details, see the original issue reported at:
https://gitlab.com/gnutls/libtasn1/-/issues/52

Exploitation
============
By presenting a certificate with a large number of Subject Alternative
Name or name constraint entries, the adversary can impose Denial of
Service (DoS) in applications using libtasn1 for certificate parsing
and verification.

Recommendation
=========
To address this vulnerability, please upgrade to libtasn1 4.20.0 or
later. At the same time, we recommend applications using libtasn1 for
certificate processing should set a limit of input sequences, such as
Subject Alternative Name or name constraint entries to reduce attack
surface.

Workaround
==========
For those who cannot modify the application code, resource control
mechanisms provided by the operating system, such as cgroups could
help avoid excessive usage of CPU time.

Credits
=======
This vulnerability was found and reported by Bing Shi.


-------- Forwarded Message --------
Subject: libtasn1-4.20.0 released [stable]
Date: Thu, 06 Feb 2025 16:41:29 +0100
From: Simon Josefsson via Announcements and Requests for Help from the GNU project and the Free Software Foundation <info-gnu@....org>
Reply-To: Simon Josefsson <simon@...efsson.org>
To: info-gnu@....org
CC: help-libtasn1@....org

This is to announce libtasn1-4.20.0, a stable release.

There have been 101 commits by 2 people in the 127 weeks since 4.19.0.

See the NEWS below for a brief summary.

Thanks to everyone who has contributed!
The following people contributed changes to this release:

   Daiki Ueno (6)
   Simon Josefsson (95)

Simon
  [on behalf of the libtasn1 maintainers]
==================================================================

Here is the GNU libtasn1 home page:
     https://gnu.org/s/libtasn1/

Here are the compressed sources and a GPG detached signature:
   https://ftp.gnu.org/gnu/libtasn1/libtasn1-4.20.0.tar.gz
   https://ftp.gnu.org/gnu/libtasn1/libtasn1-4.20.0.tar.gz.sig

Here is minimal source-only "git archive" sources:
   https://ftp.gnu.org/gnu/libtasn1/libtasn1-v4.20.0-src.tar.gz
   https://ftp.gnu.org/gnu/libtasn1/libtasn1-v4.20.0-src.tar.gz.sig

Here are Sigsum Proofs:
   https://ftp.gnu.org/gnu/libtasn1/libtasn1-4.20.0.tar.gz.proof
   https://ftp.gnu.org/gnu/libtasn1/libtasn1-v4.20.0-src.tar.gz.proof

Use a mirror for higher download bandwidth:
   https://www.gnu.org/order/ftp.html

Here are the SHA1 and SHA256 checksums:

   ef6a358e16e056476b4be121ed2fb2ce11d791ed  libtasn1-4.20.0.tar.gz
   kuDjvUwC1K7udgNrLd2D8McyukzaXLcdWDJysjWHp2w=  libtasn1-4.20.0.tar.gz

   99a90d178b5c9ced099ec0039b41d8d67cdede99  libtasn1-v4.20.0-src.tar.gz
   47y9GZy7b2wyv+WziXEa8xhMTZL5evK0u1CgrnvVLaY=  libtasn1-v4.20.0-src.tar.gz

Verify the base64 SHA256 checksum with cksum -a sha256 --check
from coreutils-9.2 or OpenBSD's cksum since 2007.

Use a .sig file to verify that the corresponding file (without the
.sig suffix) is intact.  First, be sure to download both the .sig file
and the corresponding tarball.  Then, run a command like this:

   gpg --verify libtasn1-4.20.0.tar.gz.sig

The signature should match the fingerprint of the following key:

   pub   ed25519 2019-03-20 [SC]
         B1D2 BD13 75BE CB78 4CF4  F8C4 D73C F638 C53C 06BE
   uid   Simon Josefsson <simon@...efsson.org>

If that command fails because you don't have the required public key,
or that public key has expired, try the following commands to retrieve
or refresh it, and then rerun the 'gpg --verify' command.

   gpg --locate-external-key simon@...efsson.org

   gpg --recv-keys 51722B08FE4745A2

   wget -q -O- 'https://savannah.gnu.org/project/release-gpgkeys.php?group=libtasn1&download=1' | gpg --import -

As a last resort to find the key, you can try the official GNU
keyring:

   wget -q https://ftp.gnu.org/gnu/gnu-keyring.gpg
   gpg --keyring gnu-keyring.gpg --verify libtasn1-4.20.0.tar.gz.sig

Use the .proof files to verify the Sigsum proof.  These files are like
signatures but with extra transparency: you can cryptographically verify
that every signature is logged in a public append-only log, so you can
say with confidence what signatures exists.  This makes hidden releases
no longer deniable for the same public key.

Releases are Sigsum-signed with the following public key:

   cat <<EOF > libtasn1-sigsum-key.pub
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILzCFcHHrKzVSPDDarZPYqn89H5TPaxwcORgRg+4DagE
EOF

Run a command like this to verify downloaded artifacts:

   wget -q -Otrust.txt https://gnu.org/s/libtasn1/sigsum-policy.txt
   sigsum-verify -k libtasn1-sigsum-key.pub -p trust.txt \
         libtasn1-4.20.0.tar.gz.proof < libtasn1-4.20.0.tar.gz

You may learn more about Sigsum concepts and find instructions how to
download the tools here: https://www.sigsum.org/getting-started/

This release is based on the libtasn1 git repository, available as

   git clone https://gitlab.com/gnutls/libtasn1.git

with commit 6b45b25e94ea538192cc0f97e9ad57171d1c6374 tagged as v4.20.0.

For a summary of changes and contributors, see:

   https://gitlab.com/gnutls/libtasn1/-/commits/v4.20.0

or run this command from a git-cloned libtasn1 directory:

   git shortlog v4.19.0..v4.20.0

This release was bootstrapped with the following tools:
   Gnulib 2025-02-01 c89cd2fbd3b9f3d7c5a146247256599714c91ec7
   Autoconf 2.71
   Automake 1.16.5
   Libtoolize 2.4.7
   Make 4.3
   Makeinfo 7.1.1
   Bison 3.8.2
   Help2man 1.49.2
   Gtkdocize 1.33.1
   Tar 1.34
   Gzip 1.13
   Guix d48da2d21610f9cf5f76cd846703b12beedb1fd5

NEWS

* Noteworthy changes in release 4.20.0 (2025-02-01) [stable]
- The release tarball is now reproducible.
- We publish a minimal source-only tarball generated by 'git archive'.
- Update gnulib files and various build/maintenance fixes.
- Fix CVE-2024-12133: Potential DoS in handling of numerous SEQUENCE OF or SET OF elements

Happy hacking,
Simon

Powered by blists - more mailing lists

Please check out the Open Source Software Security Wiki, which is counterpart to this mailing list.

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.