~ubuntu-branches/ubuntu/precise/gnutls26/precise-updates

« back to all changes in this revision

Viewing changes to lib/gnutls_handshake.c

  • Committer: Package Import Robot
  • Author(s): Marc Deslauriers
  • Date: 2014-06-01 11:04:42 UTC
  • Revision ID: package-import@ubuntu.com-20140601110442-9envl1xa97tpscx0
Tags: 2.12.14-5ubuntu3.8
* SECURITY UPDATE: memory corruption due to server hello parsing
  - debian/patches/CVE-2014-3466.patch: validate session_id_len in
    lib/gnutls_handshake.c.
  - CVE-2014-3466

Show diffs side-by-side

added added

removed removed

Lines of Context:
1797
1797
  DECR_LEN (len, 1);
1798
1798
  session_id_len = data[pos++];
1799
1799
 
1800
 
  if (len < session_id_len)
 
1800
  if (len < session_id_len || session_id_len > TLS_MAX_SESSION_ID_SIZE)
1801
1801
    {
1802
1802
      gnutls_assert ();
1803
1803
      return GNUTLS_E_UNSUPPORTED_VERSION_PACKET;