11.3. Creating an SSH key

Before you can add or register SSH keys to Business Central, you must generate an SSH key on your system.

Procedure

  1. Open a command terminal on your system.
  2. Run the ssh-keygen command to create the SSH key as shown in the following example, where <user_login> is your user name:

    ssh-keygen -t rsa -b 4096 -C "<user_login>"
    注記

    The SSH key formats supported by Business Central keystore are ssh-rsa, ssh-dss, ecdsa-sha2-nistp256, ecdsa-sha2-nistp384, and ecdsa-sha2-nistp521.

  3. When prompted, press Enter and accept the default key file location as shown in the following example, where <user_login> is your user name:

    Enter a file in which to save the key (/home/<user_login>/.ssh/id_rsa): [Press enter]
  4. At the command prompt, enter and confirm the passphrase:

    Enter passphrase (empty for no passphrase): [Type a passphrase]
    Enter same passphrase again: [Type passphrase again]
  5. Start the ssh-agent:

    eval "$(ssh-agent -s)"
    Agent pid <any-number-here>
  6. Add the new SSH private key to the ssh-agent. If you have used a different key name, replace id_rsa in that code:

    ssh-add ~/.ssh/id_rsa