Protect a connection
Encrypt the connection to a server, or go through an SSH server, so nobody reads your password and your data on the way.
On this page
Which one to choose
| The database is | Choose |
|---|---|
| On this computer | Not encrypted, which is what a new connection has |
| On a server that you reach by SSH | Connect through an SSH server |
| On another computer, reached directly | Encrypted, certificate checked |
TotalSQL warns you when a connection goes to another computer without encryption and without SSH.
Encryption
- Encrypted, certificate checked: the server must have a certificate valid for its name. Public authorities are accepted. If your server has its own authority, choose its file (PEM) in Certificate authority file.
- Encrypted, certificate not checked: the connection is private, but the server does not prove who it is. It is for servers with a certificate that they made themselves.
Connect through an SSH server
- Turn on Connect through an SSH server.
- Write the SSH server, its port and its user.
- In Sign in with, choose Private key, SSH agent or Password. On Windows, the agent is the one of OpenSSH, and its service must be running.
- In Server and Port, above, write where the database is as seen from the SSH server. It is often
localhost.
If the SSH server cannot reach the database, TotalSQL says so before it tries to sign in.
A database in a Docker container
Write the name of the container in Server, and the port that the database has inside the container. You do not have to publish that port.
TotalSQL asks Docker on the SSH server for the address of the container each time, because it changes. The SSH user must be allowed to run docker, or to run it with sudo without a password.
Trust the SSH server
The first time, TotalSQL shows the key of the server in Trust this SSH server? Check it with whoever runs the server, and press Trust and open. It is not asked again.
If it says The key of the SSH server changed, stop. The server may have been installed again, or someone may be in the middle. Press Replace the trusted key only when you know the new key is right.
What is kept
The password of the database, and the SSH password or the passphrase of your key, go to the secure store of your system. Your private key stays in its file: TotalSQL keeps only the path.