~ubuntu-branches/ubuntu/precise/mysql-5.5/precise-updates

« back to all changes in this revision

Viewing changes to vio/viossl.c

  • Committer: Package Import Robot
  • Author(s): Marc Deslauriers
  • Date: 2015-07-16 13:59:34 UTC
  • mfrom: (1.1.18)
  • Revision ID: package-import@ubuntu.com-20150716135934-plzpylrt211i3se4
Tags: 5.5.44-0ubuntu0.12.04.1
* SECURITY UPDATE: Update to 5.5.44 to fix security issues (LP: #1475294)
  - http://www.oracle.com/technetwork/topics/security/cpujul2015-2367936.html
  - CVE-2015-2582
  - CVE-2015-2620
  - CVE-2015-2643
  - CVE-2015-2648
  - CVE-2015-4737
  - CVE-2015-4752
  - CVE-2015-4757

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
 
1
/* Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.
2
2
 
3
3
   This program is free software; you can redistribute it and/or modify
4
4
   it under the terms of the GNU General Public License as published by
152
152
  SSL *ssl;
153
153
  my_bool unused;
154
154
  my_bool was_blocking;
 
155
  /* Declared here to make compiler happy */
 
156
#if !defined(HAVE_YASSL) && !defined(DBUG_OFF)
 
157
  int j, n;
 
158
#endif
155
159
 
156
160
  DBUG_ENTER("ssl_do");
157
161
  DBUG_PRINT("enter", ("ptr: 0x%lx, sd: %d  ctx: 0x%lx",
171
175
  SSL_clear(ssl);
172
176
  SSL_SESSION_set_timeout(SSL_get_session(ssl), timeout);
173
177
  SSL_set_fd(ssl, vio->sd);
174
 
#ifndef HAVE_YASSL
175
 
  SSL_set_options(ssl, SSL_OP_NO_COMPRESSION);
 
178
#if !defined(HAVE_YASSL) && defined(SSL_OP_NO_COMPRESSION)
 
179
  SSL_set_options(ssl, SSL_OP_NO_COMPRESSION); /* OpenSSL >= 1.0 only */
 
180
#elif OPENSSL_VERSION_NUMBER >= 0x00908000L /* workaround for OpenSSL 0.9.8 */
 
181
  sk_SSL_COMP_zero(SSL_COMP_get_compression_methods());
 
182
#endif
 
183
 
 
184
#if !defined(HAVE_YASSL) && !defined(DBUG_OFF)
 
185
  {
 
186
    STACK_OF(SSL_COMP) *ssl_comp_methods = NULL;
 
187
    ssl_comp_methods = SSL_COMP_get_compression_methods();
 
188
    n= sk_SSL_COMP_num(ssl_comp_methods);
 
189
    DBUG_PRINT("info", ("Available compression methods:\n"));
 
190
    if (n == 0)
 
191
      DBUG_PRINT("info", ("NONE\n"));
 
192
    else
 
193
      for (j = 0; j < n; j++)
 
194
      {
 
195
        SSL_COMP *c = sk_SSL_COMP_value(ssl_comp_methods, j);
 
196
        DBUG_PRINT("info", ("  %d: %s\n", c->id, c->name));
 
197
      }
 
198
  }
176
199
#endif
177
200
 
178
201
  if ((r= connect_accept_func(ssl)) < 1)