List:Commits« Previous MessageNext Message »
From:Chad MILLER Date:August 25 2006 5:55pm
Subject:bk commit into 5.0 tree (cmiller:1.2253)
View as plain text  
Below is the list of changes that have just been committed into a local
5.0 repository of cmiller. When cmiller does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html

ChangeSet@stripped, 2006-08-25 11:55:43-04:00, cmiller@stripped +3 -0
  Merge zippy.cornsilk.net:/home/cmiller/work/mysql/release/mysql-5.0-release_mergable
  into  zippy.cornsilk.net:/home/cmiller/work/mysql/release/mysql-5.0-maint
  MERGE: 1.2191.24.27

  include/mysql.h@stripped, 2006-08-25 11:55:39-04:00, cmiller@stripped +0 -0
    Auto merged
    MERGE: 1.158.2.1

  include/mysql_com.h@stripped, 2006-08-25 11:55:40-04:00, cmiller@stripped +0 -0
    Auto merged
    MERGE: 1.103.1.1

  sql-common/client.c@stripped, 2006-08-25 11:55:40-04:00, cmiller@stripped +0 -0
    Auto merged
    MERGE: 1.92.2.1

# This is a BitKeeper patch.  What follows are the unified diffs for the
# set of deltas contained in the patch.  The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User:	cmiller
# Host:	zippy.cornsilk.net
# Root:	/home/cmiller/work/mysql/release/mysql-5.0-maint/RESYNC

--- 1.160/include/mysql.h	2006-08-25 11:55:47 -04:00
+++ 1.161/include/mysql.h	2006-08-25 11:55:47 -04:00
@@ -165,7 +165,6 @@
   char *ssl_ca;					/* PEM CA file */
   char *ssl_capath;				/* PEM directory of CA-s? */
   char *ssl_cipher;				/* cipher to use */
-  my_bool ssl_verify_server_cert;		/* if to verify server cert */
   char *shared_memory_base_name;
   unsigned long max_allowed_packet;
   my_bool use_ssl;				/* if to use SSL or not */

--- 1.104/include/mysql_com.h	2006-08-25 11:55:47 -04:00
+++ 1.105/include/mysql_com.h	2006-08-25 11:55:47 -04:00
@@ -134,8 +134,10 @@
 #define CLIENT_TRANSACTIONS	8192	/* Client knows about transactions */
 #define CLIENT_RESERVED         16384   /* Old flag for 4.1 protocol  */
 #define CLIENT_SECURE_CONNECTION 32768  /* New 4.1 authentication */
-#define CLIENT_MULTI_STATEMENTS 65536   /* Enable/disable multi-stmt support */
-#define CLIENT_MULTI_RESULTS    131072  /* Enable/disable multi-results */
+#define CLIENT_MULTI_STATEMENTS (((ulong) 1) << 16)   /* Enable/disable multi-stmt
support */
+#define CLIENT_MULTI_RESULTS    (((ulong) 1) << 17)  /* Enable/disable
multi-results */
+
+#define CLIENT_SSL_VERIFY_SERVER_CERT	(((ulong) 1) << 30)
 #define CLIENT_REMEMBER_OPTIONS	(((ulong) 1) << 31)
 
 #define SERVER_STATUS_IN_TRANS     1	/* Transaction has started */

--- 1.96/sql-common/client.c	2006-08-25 11:55:47 -04:00
+++ 1.97/sql-common/client.c	2006-08-25 11:55:47 -04:00
@@ -1514,7 +1514,6 @@
   mysql->options.ssl_ca=     strdup_if_not_null(ca);
   mysql->options.ssl_capath= strdup_if_not_null(capath);
   mysql->options.ssl_cipher= strdup_if_not_null(cipher);
-  mysql->options.ssl_verify_server_cert= FALSE; /* Off by default */
 #endif /* HAVE_OPENSSL */
   DBUG_RETURN(0);
 }
@@ -2203,7 +2202,7 @@
     DBUG_PRINT("info", ("IO layer change done!"));
 
     /* Verify server cert */
-    if (mysql->options.ssl_verify_server_cert &&
+    if ((client_flag & CLIENT_SSL_VERIFY_SERVER_CERT) &&
         ssl_verify_server_cert(mysql->net.vio, mysql->host))
     {
       set_mysql_error(mysql, CR_SSL_CONNECTION_ERROR, unknown_sqlstate);
@@ -2950,7 +2949,10 @@
     mysql->reconnect= *(my_bool *) arg;
     break;
   case MYSQL_OPT_SSL_VERIFY_SERVER_CERT:
-    mysql->options.ssl_verify_server_cert= *(my_bool *) arg;
+    if (!arg || test(*(uint*) arg))
+      mysql->options.client_flag|= CLIENT_SSL_VERIFY_SERVER_CERT;
+    else
+      mysql->options.client_flag&= ~CLIENT_SSL_VERIFY_SERVER_CERT;
     break;
   default:
     DBUG_RETURN(1);
Thread
bk commit into 5.0 tree (cmiller:1.2253)Chad MILLER25 Aug