# Assign a certificate to Gateways and HALB

After you add a certificate, you can assign it to a RAS Secure Gateway, HALB, or both depending on the usage type that you specified when you created the certificate. More on the certificate **Usage** option below.

## **Certificate Usage**

Certificate **Usage** is an option that specifies whether the certificate should be available for RAS Secure Gateways, HALB, or both. See [**Generate a self-signed certificate**](https://docs.parallels.com/landing/ras-mp-guide/v20-en-us/infrastructure/certificates/generate-a-self-signed-certificate). When you configure SSL for a RAS Secure Gateway or HALB later, you need to specify an SSL certificate. When you select a certificate, the following options will be available depending on how the **Usage** option is configured for a particular certificate:

* **\<All matching usage>**: This is the default option, which is always available. It means that any certificate on which the **Usage** selection matches the object type (Gateway or HALB) will be used. For example, if you are configuring a Gateway and have a certificate that has **Usage** set to "Gateway", it will be used. If a certificate has both, Gateway and HALB usage options selected, it can also be used with the given gateway. This works the same way for HALB when you configure the LB SSL Payload. Please note that if you select this option for a Gateway or HALB, but not a single matching certificate exists, you will see a warning and will have to create a certificate first.
* Other items in the **Certificates** drop-down list are individual certificates, which will or will not be present depending on the certificate's **Usage** settings. For example, if you configure LB SSL Payload for HALB and have a certificate with the **Usage** option set to "HALB", the certificate will appear in the drop-down list. On the other hand, certificates with **Usage** set to "Gateway" will not be listed.

As another example, if you need just one certificate, which you would like to use for all of your Gateways, you need to create a certificate and set the **Usage** option to "Gateways". You can then configure each Gateway to use this specific certificate or you can keep the default **\<All matching usage>** selection, in which case the certificate will be picked up by a Gateway automatically. Same exact scenario also works for HALB.

## **Gateways**

To assign a certificate to a RAS Secure Gateway:

1. Navigate to **Infrastructure** > **Gateways**.
2. Click a Gateway in the list.
3. Click **Properties** in the middle pane.
4. Select the **SSL/TLS** category.
5. In the **Certificates** drop-down list, select the certificate that you created.

Please note that you can also select the **\<All matching usage>** option, which will use any certificate that has the usage set to Gateway or both Gateway and HALB.

## **HALB**

At the time of this writing, HALB cannot be managed in the RAS Management Portal. Please use the desktop-based RAS Console.
