Oracle 5.0 Reference Manual page 1912

Table of Contents

Advertisement

3. Click Finish to close the wizard and import the certificate into the personal store.
Examine certificates in the Personal Store
1. Start the Microsoft Management Console by entering
2. Select File, Add/Remove snap-in. Click Add. Select Certificates from the list of available snap-ins
in the dialog.
3. Click Add button in the dialog, and select the My user account radio button. This is used for
personal certificates.
4. Click the Finish button.
5. Click OK to close the Add/Remove Snap-in dialog.
6. You will now have Certificates – Current User displayed in the left panel of the Microsoft
Management Console. Expand the Certificates - Current User tree item and select Personal,
Certificates. The right-hand panel will display a certificate issued to MySQL. This is the certificate
that was previously imported. Double-click the certificate to display its details.
7. After you have imported the certificate to the Personal Store, you can use a more succint
connection string to connect to the database, as illustrated by the following code:
using (MySqlConnection connection = new MySqlConnection(
"database=test;user=sslclient;" +
"Certificate Store Location=CurrentUser;" +
"SSL Mode=Required"))
{
connection.Open();
}
Certificate Thumbprint Parameter
If you have a large number of certificates in your store, and many have the same Issuer, this can be a
source of confusion and result in the wrong certificate being used. To alleviate this situation, there is an
optional Certificate Thumbprint parameter that can additionally be specified as part of the connection
string. As mentioned before, you can double-click a certificate in the Microsoft Management Console to
display the certificate's details. When the Certificate dialog is displayed click the Details tab and scroll
down to see the thumbprint. The thumbprint will typically be a number such as
f3 01 7a 14 5c f8 47 9e 76 94 d7 aa de
string, as the following code illustrates:
using (MySqlConnection connection = new MySqlConnection(
"database=test;user=sslclient;" +
"Certificate Store Location=CurrentUser;" +
"Certificate Thumbprint=479436009a40f3017a145cf8479e7694d7aadef0;"+
"SSL Mode=Required"))
{
connection.Open();
}
Spaces in the thumbprint parameter are optional and the value is case-insensitive.
20.2.4.8. Tutorial: Using MySqlScript
This tutorial teaches you how to use the
series of statements. Depending on the circumstances, this can be more convenient than using the
MySqlCommand
Further details of the
MySQL Connector/Net.
To run the example programs in this tutorial, set up a simple test database and table using the
Command-Line Client or MySQL Workbench. Commands for the
given here:
Connector/Net Tutorials
approach.
class can be found in the reference documentation supplied with
MySqlScript
mmc.exe
f0. This thumbprint can be used in the connection
class. This class enables you to execute a
MySqlScript
1892
at a command prompt.
‎47 94 36 00 9a 40
Command-Line Client are
mysql
mysql

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mysql 5.0

Table of Contents