Database Reference
In-Depth Information
To connect
cqlsh
with encryption enabled, we need to create
.cqlshrc
file under
home
directory. Also we can connect cqlsh with
require_client_auth=false
.
Let's connect and configure
cqlsh
in this recipe.
1.
Let's create
.cqlshrc
file under
home
directory for SSL-specific
configurations.
factory = cqlshlib.ssl.ssl_transport_factory
// path to truststore file
certfile = /home/impadmin/source/keys/
.truststore
Figure 4-28
shows the configuration changes in the
.cqlshrc
file.
Figure 4-28
.
The .cqlshrc configuration changes
2.
That's it! Let's run cqlsh to connect with the Cassandra server:
SSL_CERTFILE=/home/impadmin/source/keys/
publickey.cer
SSL_VALIDATE=$CASSANDRA_HOME/bin/cqlsh -3 -t
cqlshlib.ssl.ssl_transport_factory
Connecting via the Cassandra Thrift Client