# Overview

When creating [<mark style="color:blue;">storages</mark>](https://docs.ionos.com/cloud/support/general-information/glossary-of-terms#storage) based on IONOS Linux images, you can inject [<mark style="color:blue;">SSH keys</mark>](https://docs.ionos.com/cloud/support/general-information/glossary-of-terms#secure-shell-ssh-keys) into your [<mark style="color:blue;">VM</mark>](https://docs.ionos.com/cloud/support/general-information/glossary-of-terms#virtual-machine-vm). You can access your VMs safely on the IONOS Cloud, which uses SSH keys for authentication and secure communication. SSH keys that you intend to use more often can be saved in the [<mark style="color:blue;">DCD's</mark>](https://docs.ionos.com/cloud/support/general-information/glossary-of-terms#dcd) [<mark style="color:blue;">SSH Keys</mark>](https://docs.ionos.com/sections-test/guides/security/ssh-key-manager/connect-via-ssh/manage-ssh-keys) view.

{% hint style="info" %}
**Note:** Connecting by SSH is only possible with the Linux operating system, not Windows, because IONOS Windows images do not support SSH key injection.
{% endhint %}

## Establish connection using SSH Keys

With SSH key-based authentication, you can establish secure connections to your Linux VMs. An SSH key is composed of a public-private key pair:

* A **private** key: It stays on your local system. Ensure that you do not share your private key.
* A **public** key: It is saved on your VM and enables you to access your provisioned VMs.

When you connect to your VM (which has the public key) using an SSH client, the remote VM validates the private key of the client. The client can access the VM only if the client has the correct private key.

## Supported SSH Key types

SSH keys are necessary to connect via SSH. The following are the types of SSH keys that can be used for an SSH connection:

| **Keys from the SSH Keys view**                                                                                                                                        | **Ad-hoc SSH Keys**                                                                           |
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------- |
| SSH keys that you intend to use often, either as **default** or **non-default**.                                                                                       | SSH keys that you only use once and do not intend to save in the **SSH Keys** view for reuse. |
| Select the **Default** checkbox in the **SSH Keys** to set them as default SSH keys.                                                                                   | An **Ad-hoc SSH Key** cannot be set as default.                                               |
| **Default** SSH keys are preselected when you configure storage devices.                                                                                               | An **Ad-hoc SSH Key** must be specified manually.                                             |
| Clear the **Default** checkbox if you do not want to set them as default. However, you can still associate a non-default SSH key while adding storage to a VM element. | You can specify only one **Ad-hoc SSH Key** when you associate a storage with the VM element. |
