Problems with SSL enabled, password free authentication from ADO.NET driver
Client side exception message: The message received was unexpected or badly formatted Connection string: "Host=192.168.73.131;Port=5433;Database=dbadmin;User=dbadmin;SSL=True" Here's how I configured it: 1. Generating certifications and keys mkdir ssl cd ssl openssl genrsa -des3 -out rootkey.pem openssl req -new -x509 -key rootkey.pem -out root.crt openssl genrsa -out server.key openssl req -new -out reqout.txt -key server.key openssl x509 -req -in reqout.txt -days 3650 -sha1 -CAcreateserial -CA root.crt -CAkey rootkey.pem -out server.crt openssl genrsa -out client.key openssl req -new -out reqout.txt -key client.key openssl x509 -req -in reqout.txt -days 3650 -sha1 -CAcreateserial -CA root.crt -CAkey rootkey.pem -out client.crt cp ./server.key /home/dbadmin/vertica/catalog/ssltestdb/v_ssltestdb_node0001_catalog cp ./server.crt /home/dbadmin/vertica/catalog/ssltestdb/v_ssltestdb_node0001_catalog cp ./root.crt /home/dbadmin/vertica/catalog/ssltestdb/v_ssltestdb_node0001_catalog chmod 0600 server.key chmod 0600 server.crt chmod 0600 root.crt 2. Distributing certifications and keys 3. Enable SSL SELECT SET_CONFIG_PARAMETER('EnableSSL', '1'); 4. restart database 5. vsql test [dbadmin@vm-vertica ~]$ vsql Password: Welcome to vsql, the Vertica Analytic Database interactive terminal. Type: \h or \? for help with vsql commands \g or terminate with semicolon to execute query \q to quit SSL connection (cipher: DHE-RSA-AES256-SHA, bits: 256) dbadmin=> 6.Installing Certificates on Windows copy root.crt,server.crt,client.crt to windows client machine and install them successfully.
0
Comments
Vsql work with no problem
I am seeing the same issue, do anyone know the fix for this?
Thanks
Saumya
Post your odbc configuration parameters, because Topic Starter didn't it well:
- No such parameter SSL=true, but SSLMode = {prefer|require|disable|allow}
- For Windows(ADO.NET) you should enable SSL mode in ODBC Manager (see screenshot for example) and not in connection string
- If you want to enable it in connection string I would recommend to read this post - http://vertica-forums.com/viewtopic.php?f=19&t=78&p=98&hilit=ConnSettings#p98 and http://vertica-forums.com/viewtopic.php?f=50&t=282&p=799&hilit=ConnSettings#p799
Windows ODBC ManagerConnection String And do not invent a new options, please. All parameters are documented, read the docs:
About how to set up ODBC for windows read docs: http://my.vertica.com/docs/7.1.x/HTML/index.htm#Authoring/ConnectingToHPVertica/ClientODBC/SettingUp...
PS
ADO.NET works on top of ODBC drivers(for RDBMS)