Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Info

This page describes how to use TLS to secure communications between an Abiquo Server a “remote Remote Services Services” (remote RS) server .
You can use this configuration

...

when a Remote Services Server is in a remote datacenter and the Abiquo Server will communicate with it over the internet

...

.

Warning

This document explains how to configure a test environment and it gives examples for a test environment.

When configuring your production environment, always follow the advice of your Security team.

Note

Change our example values to the values for your environment.

For example, replace “myremoters.bcn.abiquo.com” with the domain name of your remote RS server.

And remplace “remoters.jks” with the name of your server keystore.

Define a new HTTPS connector in remote RS Catalina

Replace your current remote RS catalina connector Log in to the remote RS as an administrator.

Edit the Tomcat server configuration file at:

Code Block
/opt/abiquo/tomcat/conf/server.xml

Use your own keystore and configure the parameters in the following connectorReplace the current remote RS catalina connector with a new connector.

Note

The example below is a guide only, use the correct file for your version of Tomcat

The important values to change are:

  • keystoreFile - e.g. use the host name of your remote RS server

  • keystorePass - use a secure password

  • keyAlias - you must use the domain name of your remote RS server

Also configure the other parameters according to your environment.

Code Block
<Service name="Catalina">

        <Connector
           protocol="org.apache.coyote.http11.Http11NioProtocol"
           port="8009" maxThreads="200"
           scheme="https" secure="true" SSLEnabled="true"
           keystoreFile="/opt/abiquo/tomcat/conf/remoters.jks" keystorePass="changeit" keyAlias="myremoters.bcn.abiquo.com"
           clientAuth="false" secretrequired="false" 
           sslProtocol="TLS"/>

The important values to change are keystoreFile, keystorePass, and keyAlias.
The keyAlias must match your domain name.

Code Block
keystoreFile="/opt/abiquo/tomcat/conf/remoters.jks" keystorePass="changeit" keyAlias="myremoters.bcn.abiquo.com"

...

Import certificates on Remote RS

You will need to convert your remote RS certs cert to PCKS12 format. Remember to use the domain name of your own remote RS server.

Code Block
openssl pkcs12 -export -in myremoters.bcn.abiquo.com.crt -inkey myremoters.bcn.abiquo.com.key -name myremoters.bcn.abiquo.com -out import_cert_key

Import it into the RS keystore that Tomcat is going to use:Create a .jks keystore. For a basic test environment, you can use the command below and use the name of your remote RS server

Note

For a production environment, you must configure the keystore according to advice from your Security team

Code Block
keytool -importkeystoregenkey -deststorepasskeyalg changeitRSA -destkeystorekeystore remoters.jks -srckeystore import_cert_key -srcstoretype PKCS12

...

keysize 2048

Import the certificate into the RS keystore that Tomcat will use. Remember to use your password and keystore name

Code Block
keytool -genkeyimportkeystore -keyalgdeststorepass RSAchangeit -keystoredestkeystore remoters.jks -keysize 2048srckeystore import_cert_key -srcstoretype PKCS12

...

Import

...

remote RS certificates on Abiquo server

On Log in to the API server that will connect to the Remote remote RS via HTTP, import the remote RS certificate. HTTPS as administrator.

For example, for the default cacerts keystore in a test environment.

Code Block
keytool -import -trustcacerts -alias myremoters.bcn.abiquo.com -file /etc/pki/abiquo/myremoters.bcn.abiquo.crt -cacerts

...

For AM connections to work with TLS (for template upload and download), check or enable SSL proxy for Apache.Add the following config to your apache virtualhost config, on the

Log in the API/UI server in as an adminstrator.

Edit the Apache configuration at /etc/httpd/conf.d/abiquo.conf.

In the Apache virtual host configuration, add the following.

Code Block
  ####APACHE SSL PROXY##########
  SSLProxyEngine On
  SSLProxyVerify none
  SSLProxyCheckPeerCN off
  SSLProxyCheckPeerName off
  SSLProxyCheckPeerExpire off
  ##############################

...

Import API server certificate to remote RS server

In the remote RS server’s .jks keystore, there should also be an entry for API server.

Copy the API server certificate to the remote RS server.

Import it in the same way as the RS server certificate in the previous steps.

Convert your certificate to PKCS12 format:

Code Block
openssl pkcs12 -export -in myapiserver.bcn.abiquo.com.crt -inkey myapiserver.bcn.abiquo.com.key -name myapiserver.bcn.abiquo.com -out import_cert_key

Import it to your .jks keystore file:

Code Block
keytool -importkeystore -deststorepass changeit -destkeystore remoters.jks -srckeystore import_cert_key -srcstoretype PKCS12

...

Verify API server location path on remote RS server

On remote RS server, check in the abiquo properties file at:

Code Block
/opt/abiquo/config/abiquo.properties

Check the abiquo.server.api.location property.

The value should contain “https” and no port number.

For example, https://myapiserver.bcn.abiquo.com/api.

...

Apply and verify

At this point all configurations are done. Restart both abiquo-tomcat services where changes have been made (in this scenario, remote RS and Abiquo Server).

You should be able now to Log in to Abiquo as a cloud administrator and add your remote RS using the HTTPS protocol.

For Tomcat TLS troubleshooting, see https://tomcat.apache.org/tomcat-9.0-doc/ssl-howto.html

...