List:MySQL++« Previous MessageNext Message »
From:fred ouille Date:February 28 2007 4:34pm
Subject:Re: SSL Connection error
View as plain text  
I have just tried to connect using the C API and it seems to work, here is 
the code :

    MYSQL *mysql;
    mysql = mysql_init(NULL);
    if(!mysql_ssl_set(mysql, "client_key.pem", "client-cert.pem", 
"ca-cert.pem", 0, 0))
    {
      printf("Error enabling ssl : %s\n", mysql_error(mysql));
    }
    if(!mysql_real_connect(mysql, "localhost", "Fred", "kylotonn", 
"Speedball2", 3306, 0, CLIENT_SSL))
    {
      printf("Error connecting to database : %s\n", mysql_error(mysql));
    }
    else
    {
      printf("Connected...\n");
      system("pause");
    }

Now, I'd like to be absolutely sure that my connection is secured, do you 
know how could I check that ?

_________________________________________________________________
Windows Live Messenger sur i-modeĀ™ : dialoguez avec vos amis depuis votre 
mobile comme sur PC ! http://mobile.live.fr/messenger/bouygues/

Thread
SSL Connection errorfred ouille28 Feb
  • Re: SSL Connection errorWarren Young28 Feb
    • Re: SSL Connection errorfred ouille28 Feb
      • Re: SSL Connection errorWarren Young28 Feb
        • Re: SSL Connection errorfred ouille28 Feb
          • Re: SSL Connection errorWarren Young28 Feb
            • Re: SSL Connection errorfred ouille2 Mar
              • Re: SSL Connection errorWarren Young2 Mar
                • Re: SSL Connection errorfred ouille2 Mar
                • Re: SSL Connection errorfred ouille6 Mar