Backup4all is now used on NASA's International Space Station

Backup4all is now used on NASA's International Space Station

How to create a private-public key pair

This article applies only to Backup4all. If you don't have it yet, you must download it first.

DOWNLOAD BACKUP4ALL
May 21, 2018

We strive to keep our articles as accurate as possible. If you notice any inconsistencies or outdated info please let us know.

How to create a private-public key pair

This article explains how to create a private-public key pair. Private-public key cryptography is a relatively new cryptographic approach whose distinguishing characteristic is the use of asymmetric key algorithms instead of symmetric key algorithms.

Every digital certificate has a pair of associated cryptographic keys.
This pair of keys consists of a private key and a public key.
A public key is part of the owner's digital certificate and is available for anyone to use. A private key, however, is protected by and available only to the owner of the key. This limited access ensures that communications that use the key are kept secure.

Create a private-public key pair using Backup4all

Follow these steps to create a private-public key pair using Backup4all:

  1. Open Backup4all
  2. Go to Properties (Ctrl+P) -> SFTP server -> Edit configuration
  3. Under Private key section, select Key file
  4. Press Create key pair button
  5. Type a name for the private key file and press Save
  6. Enter a password for the private key file and press OK.
  7. You can see the generated key files (both private and public) in the location specified.

Video Tutorial create private-public key file:

Create a private-public key pair using Certificate Creation tool

The Certificate Creation tool generates X.509 certificates. It creates a public and private key pair for digital signatures and stores it in a certificate file. This tool also associates the key pair with a specified publisher's name.

The applications required in this section:

Follow these steps to create a private-public key pair using Certificate Creation tool:

  1. Put Makecert.exe application on C: drive.
  2. Open a command line window.
  3. Type
    C:\makecert -r -n "CN=Top" -sv D:\top.pvk D:\top.cer
    This will create two files on your D: drive: top.pvk and top.cer
  4. Type a password for the private key.
  5. Put the pvk.exe file on D: drive. Use pvk.exe to convert .pvk file to .pem format Type in command line:
    D:\pvk.exe -in top.pvk -out top.pem
  6. Use ssh-keygen to extract the public key and save it in RFC 4716 format Type in command line
    D:\ssh-keygen -e -f D:\top.pem > D:\top.pub (You will be asked to type the password before extraction.)
  7. Convert .pem to .ppk (PUTTY key format). To do that, just load top.pem in FileZilla client (go to Edit menu -> Settings -> Connection -> SFTP)
  8. In freeSSHd server, go to Settings -> Authentication
  9. Select the Public key authentication and disable all other methods.
  10. Indicate the public key folder and make sure you copy the top.pub file in that folder.

Backup to SFTP server using private key file

To make a backup to SFTP server with Backup4all, please follow these steps:

  1. Open Backup4all, press File -> New Backup
  2. Press Advanced mode
  3. Type a name for your backup job
  4. On SFTP server press Edit configuration
  5. Enter the SFTP server details
  6. Under Private key section, select Key file and choose the private key file you generated.
  7. Press OK.
  8. Go to Sources page and add the backup sources.
  9. On Type page, select the backup type to use.
  10. Press Save.
  11. In freeSSHd server, go to Settings -> Authentication
  12. Select the Public key authentication and disable all other methods.
  13. Indicate the public key folder and make sure you copy the public key file in that folder.
  14. You can now press the Backup button from Backup4all.

Video tutorial backup to SFTP server:

Applies to:

Backup4all 4.x, 5.x



POPULAR ARTICLES

USB backup
18 January 2019
Full backup
07 December 2018
FTP backup
15 October 2018
Mirror backup
12 October 2018


LATEST ARTICLES

How to clear the backup
14 March 2019
Backup demo
13 March 2019