Skip to main content
Skip table of contents

How to setup auto-authentication

Generally, users need to enter a username and password when logging into the Delphix CLI. There are situations in which users may find entering a password cumbersome, or manual password entry may not be possible. These situations can be alleviated by setting up auto-authentication for the Delphix CLI.

There are two basic steps:

  1. Generate a public and Private RSA key pair.

  2. Register the public key with the specific Delphix Engine user.

There are two methods available:

  • PuTTY

  • OpenSSH with OpenSSL

If the examples provided do not work for you, you may need to consult your SSH documentation, we can only provide support for the Delphix Engine side of the connection. In both examples we grant password less login to the sysadmin user to host Delphix5010.

Using PuTTY

You will need both putty.exe and puttygen.exe for this.

Launch puttygen.exe

Set the Type of key to generate to SSH-2 RSA and the Number of bites in generated key to a suitable value such as 2048. Click Generate

Once it has generated the key pair, leave the password fields blank and save the public and private keys to file.

Add the full contents of the public key to each Delphix Engine user you want to allow automatic login for.

Delphix5010> user Delphix5010 user> select sysadmin Delphix5010 user 'sysadmin'> update Delphix5010 user 'sysadmin' update> set publicKey="ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAQEAjdQYr1WU6UPr6FZqyt3eKNJEkAe8IdKQ8hcuBWa3HvRVmUuv0Lykm5AYQlIW0B33aWusr0o+2FVTzt3/6G1lLCf7wfhCShlJsYgwgmHeEGjixK5tacFCD8r+8dALaXlv8uOlddK0A2LPXbCCCIRL7IyVEnlSbUFY8s+E/2R3owy5XSbLJLE1el5m1lQPOyUuQddAh25ruWR+1HHSAWG3p+wofOh6l7czkEcq7fPjtAZvivX90e8Ggt6JQ8bv6td7aJWObU2Y9YY0HLLHot7NQ4AT/0tXSRKAG8sIdL7tY9hbHMNHRftCLzfn7mL+Qk8TjUYni3JGB4Vyi0bmkj6nHQ== rsa-key-20160309" Delphix5010 user 'sysadmin' update> commit

  1. In Putty, create a profile that uses the private key. In the PuTTY Connection settings set SSH > Auth >Private key file for authentication to the private key file you just generated

  2. Next, still in the PuTTY Connection settings set Data > Auto-login username to sysadmin@SYSTEM.

  3. Test the connection by setting the connection hostname as you normally would for PuTTY and click Open.

Connection > SSH . Auth

Using OpenSSH with open SSL

Generally, OpenSSH will already have default public and private keys that can be used, if not (or the default keys are password locked) you can create them this way. OpenSSL is required but OpenSSH will take care of the background OpenSSL stuff for you.

  1. Create your RSA key pair to a bit length suitable for your security needs (2048 is commonly required for recent security audits)

$ ssh-keygen -b 2048 -t rsa -P ' ' -f /etc/ssh/ssh_host_rsa_key

Results in a matching public file called /etc/ssh/ssh_host_rsa_key.pub If you want to create different key pairs, just specify a different file path.

  1. Add the full contents of the public key (/etc/ssh/ssh_host_rsa_key.pub in this example) to each Delphix Engine user you want to allow automatic login for.

Delphix5010> user Delphix5010 user> select sysadmin Delphix5010 user 'sysadmin'> update Delphix5010 user 'sysadmin' update> set publicKey="ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAQEAjdQYr1WU6UPr6FZqyt3eKNJEkAe8IdKQ8hcuBWa3HvRVmUuv0Lykm5AYQlIW0B33aWusr0o+2FVTzt3/6G1lLCf7wfhCShlJsYgwgmHeEGjixK5tacFCD8r+8dALaXlv8uOlddK0A2LPXbCCCIRL7IyVEnlSbUFY8s+E/2R3owy5XSbLJLE1el5m1lQPOyUuQddAh25ruWR+1HHSAWG3p+wofOh6l7czkEcq7fPjtAZvivX90e8Ggt6JQ8bv6td7aJWObU2Y9YY0HLLHot7NQ4AT/0tXSRKAG8sIdL7tY9hbHMNHRftCLzfn7mL+Qk8TjUYni3JGB4Vyi0bmkj6nHQ== rsa-key-20160309" Delphix5010 user 'sysadmin' update> commit

  1. Test no password login on the command line from your client.

$ ssh -i /etc/ssh/ssh_host_rsa_key sysadmin@Delphix5010

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.